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 @@ -150,8 +150,8 @@ void o2::globaltracking::RecoContainer::createTracksVariadic(T creator, GTrackID
const auto& match = matchesITSTPCTRDTOF[i];
auto gidx = match.getTrackRef(); // this should be corresponding ITS-TPC-TRD track
// no need to check isUsed: by construction this ITS-TPC-TRD was not used elsewhere
const auto& tofCl = tofClusters[match.getTOFClIndex()];
float timeTOFMUS = (tofCl.getTime() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
// const auto& tofCl = tofClusters[match.getTOFClIndex()];
float timeTOFMUS = (match.getSignal() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
const float timeErr = 0.010f; // assume 10 ns error FIXME
if (creator(tracksITSTPCTRD[gidx.getIndex()], {i, currentSource}, timeTOFMUS, timeErr)) {
flagUsed(gidx); // flag used ITS-TPC-TRD tracks
Expand All @@ -170,9 +170,9 @@ void o2::globaltracking::RecoContainer::createTracksVariadic(T creator, GTrackID
}
for (unsigned i = 0; i < matchesTPCTRDTOF.size(); i++) {
const auto& match = matchesTPCTRDTOF[i];
auto gidx = match.getTrackRef(); // this should be corresponding TPC-TRD track
const auto& tofCl = tofClusters[match.getTOFClIndex()];
float timeTOFMUS = (tofCl.getTime() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
auto gidx = match.getTrackRef(); // this should be corresponding TPC-TRD track
// const auto& tofCl = tofClusters[match.getTOFClIndex()];
float timeTOFMUS = (match.getSignal() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
const float timeErr = 0.010f; // assume 10 ns error FIXME
if (creator(tracksTPCTRD[gidx.getIndex()], {i, currentSource}, timeTOFMUS, timeErr)) {
flagUsed(gidx); // flag used TPC-TRD tracks
Expand Down Expand Up @@ -223,8 +223,8 @@ void o2::globaltracking::RecoContainer::createTracksVariadic(T creator, GTrackID
continue;
}
// no need to check isUsed: by construction this ITS-TPC was not used elsewhere
const auto& tofCl = tofClusters[match.getTOFClIndex()];
float timeTOFMUS = (tofCl.getTime() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
// const auto& tofCl = tofClusters[match.getTOFClIndex()];
float timeTOFMUS = (match.getSignal() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
const float timeErr = 0.010f; // assume 10 ns error FIXME
if (creator(tracksTPCITS[gidx.getIndex()], {i, currentSource}, timeTOFMUS, timeErr)) {
flagUsed(gidx); // flag used ITS-TPC tracks
Expand Down
12 changes: 6 additions & 6 deletions DataFormats/Detectors/GlobalTracking/src/RecoContainer.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -1491,8 +1491,8 @@ void RecoContainer::getTrackTimeITSTPCTRDTOF(GTrackID gid, float& t, float& tErr
{
const auto& match = getITSTPCTRDTOFMatches()[gid];
auto gidx = match.getTrackRef(); // this should be corresponding ITS-TPC-TRD track
const auto& tofCl = getTOFClusters()[match.getTOFClIndex()];
t = (tofCl.getTime() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
// const auto& tofCl = getTOFClusters()[match.getTOFClIndex()];
t = (match.getSignal() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
tErr = 0.010f;
}

Expand All @@ -1501,8 +1501,8 @@ void RecoContainer::getTrackTimeTPCTRDTOF(GTrackID gid, float& t, float& tErr) c
{
const auto& match = getTPCTRDTOFMatches()[gid];
auto gidx = match.getTrackRef(); // this should be corresponding ITS-TPC-TRD track
const auto& tofCl = getTOFClusters()[match.getTOFClIndex()];
t = (tofCl.getTime() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
// const auto& tofCl = getTOFClusters()[match.getTOFClIndex()];
t = (match.getSignal() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
tErr = 0.010f;
}

Expand All @@ -1511,8 +1511,8 @@ void RecoContainer::getTrackTimeITSTPCTOF(GTrackID gid, float& t, float& tErr) c
{
const auto& match = getITSTPCTOFMatches()[gid];
auto gidx = match.getTrackRef(); // this should be corresponding ITS-TPC track
const auto& tofCl = getTOFClusters()[match.getTOFClIndex()];
t = (tofCl.getTime() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
// const auto& tofCl = getTOFClusters()[match.getTOFClIndex()];
t = (match.getSignal() - match.getLTIntegralOut().getTOF(o2::track::PID::Pion)) * PS2MUS; // tof time in \mus, FIXME: account for time of flight to R TOF
tErr = 0.010f;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,11 @@ class MatchInfoTOF

int getIdLocal() const { return mIdLocal; }

float getVz() const { return mVz; }
void setVz(float val) { mVz = val; }
int getChannel() const { return mChannel; }
void setChannel(int val) { mChannel = val; }

private:
int mIdLocal; // track id in sector of the pair track-TOFcluster
float mChi2; // chi2 of the pair track-TOFcluster
Expand All @@ -69,8 +74,10 @@ class MatchInfoTOF
float mDZatTOF = 0.0; ///< DZ position at TOF
float mDeltaT = 0.0; ///< tTOF - TPC (microsec)
double mSignal = 0.0; ///< TOF time in ps
float mVz = 0.0; ///< Vz from TOF match
int mChannel = -1; ///< channel

ClassDefNV(MatchInfoTOF, 5);
ClassDefNV(MatchInfoTOF, 6);
};
} // namespace dataformats
} // namespace o2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,24 @@ class MatchInfoTOFReco : public MatchInfoTOF
float pt() const { return mPt; }
void setPt(float pt) { mPt = pt; }

void setResX(float val) { mResX = val; }
void setResZ(float val) { mResZ = val; }
void setResT(float val) { mResT = val; }
float getResX() const { return mResX; }
float getResZ() const { return mResZ; }
float getResT() const { return mResT; }

void setTrackType(TrackType value) { mTrackType = value; }
TrackType getTrackType() const { return mTrackType; }

private:
TrackType mTrackType; ///< track type (TPC, ITSTPC, TPCTRD, ITSTPCTRD)
bool mFakeMC = false;
float mPt = 0;
ClassDefNV(MatchInfoTOFReco, 4);
float mResX = 1;
float mResZ = 1;
float mResT = 1;
ClassDefNV(MatchInfoTOFReco, 5);
};
} // namespace dataformats
} // namespace o2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,7 @@ class MatchTOF
///< per sector indices of track entry in mTracksWork
std::array<std::vector<int>, o2::constants::math::NSectors> mTracksSectIndexCache[trkType::SIZE];
std::array<std::vector<int>, o2::constants::math::NSectors> mTracksSeed[trkType::SIZE];
std::vector<float> mVZtpcOnly[o2::constants::math::NSectors];

std::vector<float> mExtraTPCFwdTime[o2::constants::math::NSectors]; ///< track extra params for TPC tracks: Fws Max time
std::vector<Cluster> mTOFClusWork; ///< track params prepared for matching
Expand Down Expand Up @@ -347,7 +348,7 @@ class MatchTOF
TStopwatch mTimerMatchITSTPC;
TStopwatch mTimerMatchTPC;
TStopwatch mTimerDBG;
ClassDefNV(MatchTOF, 5);
ClassDefNV(MatchTOF, 6);
};
} // namespace globaltracking
} // namespace o2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,12 @@ namespace globaltracking
{

struct MatchTOFParams : public o2::conf::ConfigurableParamHelper<MatchTOFParams> {
float calibMaxChi2 = 3.0;
float nsigmaTimeCut = 4.; // number of sigmas for non-TPC track time resolution to consider
float calibMaxChi2 = 3.0; // max value of Chi2 allowed for using matched tracks in calibration
float nsigmaTimeCut = 4.; // number of sigmas for non-TPC track time resolution to consider
float maxResX = 1.; // max value of track resolution (X dir) used in TOF matching (truncation to that in case it is larger)
float maxResZ = 1.; // max value of track resolution (Z dir) used in TOF matching (truncation to that in case it is larger)
float maxChi2 = 10.; // max value of Chi2 accepted for matching to TOF
bool applyPIDcutTPConly = true; // apply PID cut on TPC only tracks

O2ParamDef(MatchTOFParams, "MatchTOF");
};
Expand Down
Loading