Skip to content

Commit 2ac234a

Browse files
Key improvements in sigmaanalysis logic and histogram filling
1 parent 2d97e3c commit 2ac234a

File tree

3 files changed

+778
-835
lines changed

3 files changed

+778
-835
lines changed

PWGLF/DataModel/LFSigmaTables.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ DECLARE_SOA_COLUMN(SigmaOPAngle, sigmaOPAngle, float);
3636
DECLARE_SOA_COLUMN(SigmaCentrality, sigmaCentrality, float);
3737
DECLARE_SOA_COLUMN(SigmaRunNumber, sigmaRunNumber, int);
3838
DECLARE_SOA_COLUMN(SigmaTimestamp, sigmaTimestamp, uint64_t);
39+
DECLARE_SOA_COLUMN(SigmaIR, sigmaIR, float);
3940

4041
} // namespace sigma0Core
4142

@@ -46,7 +47,8 @@ DECLARE_SOA_TABLE(Sigma0Cores, "AOD", "SIGMA0CORES",
4647
sigma0Core::SigmaOPAngle,
4748
sigma0Core::SigmaCentrality,
4849
sigma0Core::SigmaRunNumber,
49-
sigma0Core::SigmaTimestamp);
50+
sigma0Core::SigmaTimestamp,
51+
sigma0Core::SigmaIR);
5052

5153
// For Photon extra info
5254
namespace sigmaPhotonExtra

PWGLF/TableProducer/Strangeness/sigma0builder.cxx

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -877,11 +877,15 @@ struct sigma0builder {
877877
float fSigmaRap = RecoDecay::y(std::array{gamma.px() + lambda.px(), gamma.py() + lambda.py(), gamma.pz() + lambda.pz()}, o2::constants::physics::MassSigma0);
878878
float fSigmaOPAngle = v1.Angle(v2);
879879
float fSigmaCentrality = coll.centFT0C();
880-
float fSigmaTimeStamp = coll.timestamp();
881-
float fSigmaRunNumber = coll.runNumber();
880+
uint64_t fSigmaTimeStamp = coll.timestamp();
881+
int fSigmaRunNumber = coll.runNumber();
882+
float fSigmaIR = -1;
883+
884+
if (fGetIR)
885+
fSigmaIR = rateFetcher.fetch(ccdb.service, coll.timestamp(), coll.runNumber(), irSource, fIRCrashOnNull) * 1.e-3;
882886

883887
// Filling TTree for ML analysis
884-
sigma0cores(fSigmapT, fSigmaMass, fSigmaRap, fSigmaOPAngle, fSigmaCentrality, fSigmaRunNumber, fSigmaTimeStamp);
888+
sigma0cores(fSigmapT, fSigmaMass, fSigmaRap, fSigmaOPAngle, fSigmaCentrality, fSigmaRunNumber, fSigmaTimeStamp, fSigmaIR);
885889

886890
sigmaPhotonExtras(fPhotonPt, fPhotonMass, fPhotonQt, fPhotonAlpha, fPhotonRadius,
887891
fPhotonCosPA, fPhotonDCADau, fPhotonDCANegPV, fPhotonDCAPosPV, fPhotonZconv,
@@ -916,7 +920,7 @@ struct sigma0builder {
916920

917921
//_______________________________________________
918922
// Retrieving IR info
919-
double interactionRate = -1;
923+
float interactionRate = -1;
920924
if (fGetIR){
921925
interactionRate = rateFetcher.fetch(ccdb.service, coll.timestamp(), coll.runNumber(), irSource, fIRCrashOnNull) * 1.e-3;
922926

@@ -1107,7 +1111,8 @@ struct sigma0builder {
11071111
histos.fill(HIST("hEventCentrality"), centrality);
11081112

11091113
//_______________________________________________
1110-
// Retrieving IR info
1114+
// Retrieving IR info
1115+
float interactionRate = -1;
11111116
if (fGetIR){
11121117
interactionRate = rateFetcher.fetch(ccdb.service, coll.timestamp(), coll.runNumber(), irSource, fIRCrashOnNull) * 1.e-3;
11131118

0 commit comments

Comments
 (0)