Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -140,14 +140,19 @@ struct TrackData {
float chi2TPC{}; ///< chi2 of TPC track
float chi2ITS{}; ///< chi2 of ITS track
float chi2TRD{}; ///< chi2 of TRD track
float deltaTOF{}; ///< TOFsignal - T0 - texp(PID), if T0 is available

unsigned short nClsTPC{}; ///< number of attached TPC clusters
unsigned short nClsITS{}; ///< number of attached ITS clusters
unsigned short nTrkltsTRD{}; ///< number of attached TRD tracklets
unsigned short clAvailTOF{}; ///< whether or not track seed has a matched TOF cluster
unsigned short clAvailTOF{}; ///< whether or not track seed has a matched TOF cluster, if so, gives the resolution of the T0 in ps
uint8_t nExtDetResid = 0; ///< number of external detectors (to TPC) residuals stored, on top of clIdx.getEntries
o2::dataformats::RangeReference<> clIdx{}; ///< index of first cluster residual and total number of TPC cluster residuals of this track
ClassDefNV(TrackData, 7);

float getT0Error() const { return float(clAvailTOF); }
bool isTOFAvail() const { return clAvailTOF != 0; }

ClassDefNV(TrackData, 8);
};

/// \class TrackInterpolation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -620,7 +620,13 @@ void TrackInterpolation::interpolateTrack(int iSeed)
trackData.nClsTPC = trkTPC.getNClusterReferences();
trackData.nClsITS = trkITS.getNumberOfClusters();
trackData.nTrkltsTRD = gidTable[GTrackID::TRD].isIndexSet() ? mRecoCont->getITSTPCTRDTrack<o2::trd::TrackTRD>(gidTable[GTrackID::ITSTPCTRD]).getNtracklets() : 0;
trackData.clAvailTOF = gidTable[GTrackID::TOF].isIndexSet() ? 1 : 0;
if (gidTable[GTrackID::TOF].isIndexSet()) {
const auto& tofMatch = mRecoCont->getTOFMatch(mGIDs[iSeed]);
trackData.deltaTOF = tofMatch.getSignal() - tofMatch.getFT0Best() - tofMatch.getLTIntegralOut().getTOF(trkTPC.getPID().getID());
trackData.clAvailTOF = uint16_t(tofMatch.getFT0BestRes());
} else {
trackData.clAvailTOF = 0;
}
trackData.dEdxTPC = trkTPC.getdEdx().dEdxTotTPC;

TrackParams params; // for refitted track parameters and flagging rejected clusters
Expand Down Expand Up @@ -933,7 +939,11 @@ void TrackInterpolation::extrapolateTrack(int iSeed)
}

// do we have TOF residual to add?
trackData.clAvailTOF = 0;
while (gidTableFull[GTrackID::TOF].isIndexSet() && !stopPropagation) {
const auto& tofMatch = mRecoCont->getTOFMatch(gidFull);
trackData.deltaTOF = tofMatch.getSignal() - tofMatch.getFT0Best() - tofMatch.getLTIntegralOut().getTOF(trkTPC.getPID().getID());
trackData.clAvailTOF = uint16_t(tofMatch.getFT0BestRes());
const auto& clTOF = mRecoCont->getTOFClusters()[gidTableFull[GTrackID::TOF]];
const float clTOFAlpha = o2::math_utils::sector2Angle(clTOF.getCount());
float clTOFxyz[3] = {clTOF.getX(), clTOF.getY(), clTOF.getZ()};
Expand All @@ -955,7 +965,6 @@ void TrackInterpolation::extrapolateTrack(int iSeed)
auto dz = clTOFxyz[2] - trkWork.getZ();
if ((std::abs(dy) < param::MaxResid) && (std::abs(dz) < param::MaxResid) && (std::abs(trkWork.getY()) < param::MaxY) && (std::abs(trkWork.getZ()) < param::MaxZ) && (std::abs(tgPhi) < param::MaxTgSlp)) {
mClRes.emplace_back(dy, dz, tgPhi, trkWork.getY(), trkWork.getZ(), 170, clTOF.getCount(), clTOF.getPadInSector());
trackData.clAvailTOF = 1;
trackData.nExtDetResid++;
}
break;
Expand Down
2 changes: 1 addition & 1 deletion prodtests/full-system-test/dpl-workflow.sh
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ has_detector_reco FT0 && ! has_detector_from_global_reader FT0 && add_W o2-ft0-r
has_detector_reco TRD && ! has_detector_from_global_reader TRD && add_W o2-trd-tracklet-transformer "--disable-irframe-reader $DISABLE_DIGIT_ROOT_INPUT $DISABLE_ROOT_OUTPUT $DISABLE_MC $TRD_FILTER_CONFIG --pipeline $(get_N TRDTRACKLETTRANSFORMER TRD REST 1 TRDTRKTRANS)"
has_detectors_reco ITS TPC && ! has_detector_from_global_reader_tracks ITS-TPC && has_detector_matching ITSTPC && add_W o2-tpcits-match-workflow "$DISABLE_ROOT_INPUT $DISABLE_ROOT_OUTPUT $DISABLE_MC $SEND_ITSTPC_DTGL $TPC_CORR_OPT --nthreads $ITSTPC_THREADS --pipeline $(get_N itstpc-track-matcher MATCH REST $ITSTPC_THREADS TPCITS)" "$ITSTPC_CONFIG_KEY;$INTERACTION_TAG_CONFIG_KEY;$ITSMFT_STROBES;$ITSEXTRAERR;$TPC_CORR_KEY"
has_detector_reco TRD && [[ -n "$TRD_SOURCES" ]] && ! has_detector_from_global_reader_tracks "$(echo "$TRD_SOURCES" | cut -d',' -f1)-TRD" && add_W o2-trd-global-tracking "$DISABLE_ROOT_INPUT $DISABLE_ROOT_OUTPUT $DISABLE_MC $TRD_CONFIG $TRD_FILTER_CONFIG $TPC_CORR_OPT --track-sources $TRD_SOURCES --pipeline $(get_N trd-globaltracking_TPC_ITS-TPC_ TRD REST 1 TRDTRK),$(get_N trd-globaltracking_TPC_FT0_ITS-TPC_ TRD REST 1 TRDTRK),$(get_N trd-globaltracking_TPC_FT0_ITS-TPC_CTP_ TRD REST 1 TRDTRK)" "$TRD_CONFIG_KEY;$INTERACTION_TAG_CONFIG_KEY;$ITSMFT_STROBES;$ITSEXTRAERR;$TPC_CORR_KEY"
has_detector_reco TOF && [[ -n "$TOF_SOURCES" ]] && ! has_detector_from_global_reader_tracks "$(echo "$TOF_SOURCES" | cut -d',' -f1)-TOF" && add_W o2-tof-matcher-workflow "$TOF_MATCH_OPT $DISABLE_ROOT_INPUT $DISABLE_ROOT_OUTPUT $DISABLE_MC $TPC_CORR_OPT ${TOFMATCH_THREADS:+--tof-lanes ${TOFMATCH_THREADS}} --track-sources $TOF_SOURCES --pipeline $(get_N tof-matcher TOF REST 1 TOFMATCH)" "$ITSMFT_STROBES;$ITSEXTRAERR;$TPC_CORR_KEY"
has_detector_reco TOF && [[ -n "$TOF_SOURCES" ]] && ! has_detector_from_global_reader_tracks "$(echo "$TOF_SOURCES" | cut -d',' -f1)-TOF" && add_W o2-tof-matcher-workflow "$TOF_MATCH_OPT $DISABLE_ROOT_INPUT $DISABLE_ROOT_OUTPUT $DISABLE_MC $TPC_CORR_OPT ${TOFMATCH_THREADS:+--tof-lanes ${TOFMATCH_THREADS}} --track-sources $TOF_SOURCES --pipeline $(get_N tof-matcher TOF REST 1 TOFMATCH)" "$ITSMFT_STROBES;$ITSEXTRAERR;$TPC_CORR_KEY;$INTERACTION_TAG_CONFIG_KEY"
has_detectors TPC && [[ -z "$DISABLE_ROOT_OUTPUT" && "${SKIP_TPC_CLUSTERSTRACKS_OUTPUT:-}" != 1 ]] && ! has_detector_from_global_reader TPC && add_W o2-tpc-reco-workflow "--input-type pass-through --output-type clusters,tpc-triggers,tracks,send-clusters-per-sector $DISABLE_MC"

# ---------------------------------------------------------------------------------------------------------------------
Expand Down