Skip to content
Merged
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
3 changes: 2 additions & 1 deletion PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
#include <vector>

#ifndef HomogeneousField
#define HomogeneousField

Check failure on line 54 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/macro]

Use SCREAMING_SNAKE_CASE for names of macros. Leading and double underscores are not allowed.
#endif

// includes KFParticle
Expand All @@ -75,7 +75,7 @@
using TrackExtIUwithEvTimes = soa::Join<FullTracksExtIU, aod::EvTimeTOFFT0ForTrack>;
using TrackExtPIDIUwithEvTimes = soa::Join<FullTracksExtPIDIU, aod::EvTimeTOFFT0ForTrack>;

struct reduced3bodyCreator {

Check failure on line 78 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/struct]

Use UpperCamelCase for names of structs.

Produces<aod::RedCollisions> reducedCollisions;
Produces<aod::RedPVMults> reducedPVMults;
Expand Down Expand Up @@ -181,8 +181,9 @@
mRunNumber = bc.runNumber();

// In case override, don't proceed, please - no CCDB access required
auto run3grp_timestamp = bc.timestamp();

Check failure on line 184 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
o2::parameters::GRPMagField* grpmag = ccdb->getForTimeStamp<o2::parameters::GRPMagField>(grpmagPath, run3grp_timestamp);
ccdb->clearCache(grpmagPath);
o2::parameters::GRPMagField* grpmag = ccdb->getSpecific<o2::parameters::GRPMagField>(grpmagPath, run3grp_timestamp);
if (!grpmag) {
LOG(fatal) << "Got nullptr from CCDB for path " << grpmagPath << " of object GRPMagField and " << grpPath << " of object GRPObject for timestamp " << run3grp_timestamp;
}
Expand Down Expand Up @@ -232,7 +233,7 @@
{
// Construct 3body vertex
int nDaughters3body = 3;
const KFParticle* Daughters3body[3] = {&kfpProton, &kfpPion, &kfpDeuteron};

Check failure on line 236 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
KFHt.SetConstructMethod(2);
try {
KFHt.Construct(Daughters3body, nDaughters3body);
Expand Down Expand Up @@ -274,7 +275,7 @@
continue;
}
registry.fill(HIST("hEventCounter"), 1.5);
if (doPosZselection && (collision.posZ() >= 10.0f || collision.posZ() <= -10.0f)) { // 10cm

Check failure on line 278 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
continue;
}
registry.fill(HIST("hEventCounter"), 2.5);
Expand Down Expand Up @@ -302,7 +303,7 @@
if (doSel8selection && !collision.sel8()) {
continue;
}
if (doPosZselection && (collision.posZ() >= 10.0f || collision.posZ() <= -10.0f)) { // 10cm

Check failure on line 306 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
continue;
}

Expand Down Expand Up @@ -369,7 +370,7 @@
kfpDeuteron = createKFParticleFromTrackParCov(trackParCovBach, daughter2.sign(), constants::physics::MassDeuteron);
// fit 3body vertex and caclulate radius, phi, z position
float radius, phi, posZ;
KFParticle KFHt;

Check failure on line 373 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
if (fit3bodyVertex(kfpProton, kfpPion, kfpDeuteron, KFHt)) {
radius = std::hypot(KFHt.GetX(), KFHt.GetY());
phi = std::atan2(KFHt.GetPx(), KFHt.GetPy());
Expand All @@ -381,9 +382,9 @@
}

// -------- get decay3body info with DCA fitter --------
auto Track0 = getTrackParCov(daughter0);

Check failure on line 385 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
auto Track1 = getTrackParCov(daughter1);

Check failure on line 386 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
auto Track2 = getTrackParCov(daughter2);

Check failure on line 387 in PWGLF/TableProducer/Nuspex/reduced3bodyCreator.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/function-variable]

Use lowerCamelCase for names of functions and variables.
int n3bodyVtx = fitter3body.process(Track0, Track1, Track2);
float phiVtx, rVtx, zVtx;
if (n3bodyVtx == 0) { // discard this pair
Expand Down
Loading