Skip to content

Commit 56e9bc7

Browse files
author
Laura Gansbartl
committed
Fix CodeChecker
1 parent ba52b88 commit 56e9bc7

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

PWGEM/PhotonMeson/TableProducer/skimmerPrimaryElectronFromDalitzEE.cxx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
#include <Framework/OutputObjHeader.h>
4242
#include <Framework/runDataProcessing.h>
4343
#include <ReconstructionDataFormats/DCA.h>
44+
#include <ReconstructionDataFormats/PID.h>
4445

4546
#include <Math/Vector4D.h> // IWYU pragma: keep (do not replace with Math/Vector4Dfwd.h)
4647
#include <Math/Vector4Dfwd.h>
@@ -96,7 +97,7 @@ struct skimmerPrimaryElectronFromDalitzEE {
9697
Preslice<aod::TrackAssoc> trackIndicesPerCollision = aod::track_association::collisionId;
9798
Produces<aod::EMPrimaryElectronsFromDalitz> emprimaryelectrons;
9899
Produces<aod::EMPrimaryElectronsDeDxMC> emprimaryelectronsDeDxMC;
99-
Service<o2::pid::tof::TOFResponse> mTOFResponse;
100+
Service<o2::pid::tof::TOFResponse> mTOFResponse{};
100101

101102
Produces<aod::EMTOFNSigmas> emtofs;
102103

@@ -290,7 +291,7 @@ struct skimmerPrimaryElectronFromDalitzEE {
290291
if (track.hasTOF() && track.has_collision()) { // TTCA may use orphan tracks.
291292
auto bcTrack = track.template collision_as<TCollisions>().template bc_as<TBCs>();
292293
float tofNSigmaEl = mTOFResponse->nSigma<o2::track::PID::Electron>(track.tofSignalInAnotherBC(bcTrack.globalBC(), bcCollision.globalBC()), track.tofExpMom(), track.length(), track.p(), track.eta(), mapCollisionTime[collision.globalIndex()], mapCollisionTimeError[collision.globalIndex()]);
293-
float beta = track.length() / (track.tofSignalInAnotherBC(bcTrack.globalBC(), bcCollision.globalBC()) - mapCollisionTime[collision.globalIndex()]) / (TMath::C() * 1e+2 * 1e-12);
294+
float beta = track.length() / (track.tofSignalInAnotherBC(bcTrack.globalBC(), bcCollision.globalBC()) - mapCollisionTime[collision.globalIndex()]) / (o2::constants::physics::LightSpeedCm2S * 1e-12);
294295
mapTOFNsigmaReassociated[std::make_pair(collision.globalIndex(), track.globalIndex())] = tofNSigmaEl;
295296
mapTOFBetaReassociated[std::make_pair(collision.globalIndex(), track.globalIndex())] = beta;
296297
emtofs(collision.globalIndex(), track.globalIndex(), mapTOFBetaReassociated[std::make_pair(collision.globalIndex(), track.globalIndex())], mapTOFNsigmaReassociated[std::make_pair(collision.globalIndex(), track.globalIndex())]);

0 commit comments

Comments
 (0)