Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Common: extra ZDC variables for debug #4578

Merged
merged 2 commits into from
Feb 3, 2024
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
20 changes: 19 additions & 1 deletion Common/DataModel/Multiplicity.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ DECLARE_SOA_COLUMN(MultFDDA, multFDDA, float); //!
DECLARE_SOA_COLUMN(MultFDDC, multFDDC, float); //!
DECLARE_SOA_COLUMN(MultZNA, multZNA, float); //!
DECLARE_SOA_COLUMN(MultZNC, multZNC, float); //!
DECLARE_SOA_COLUMN(MultZEM1, multZEM1, float); //!
DECLARE_SOA_COLUMN(MultZEM2, multZEM2, float); //!
DECLARE_SOA_COLUMN(MultZPA, multZPA, float); //!
DECLARE_SOA_COLUMN(MultZPC, multZPC, float); //!
DECLARE_SOA_DYNAMIC_COLUMN(MultFV0M, multFV0M, //!
[](float multFV0A, float multFV0C) -> float { return multFV0A + multFV0C; });
DECLARE_SOA_DYNAMIC_COLUMN(MultFT0M, multFT0M, //!
Expand Down Expand Up @@ -76,7 +80,7 @@ DECLARE_SOA_TABLE(FDDMults, "AOD", "FDDMULT", //! Multiplicity with the FDD dete
mult::MultFDDA, mult::MultFDDC,
mult::MultFDDM<mult::MultFDDA, mult::MultFDDC>);
DECLARE_SOA_TABLE(ZDCMults, "AOD", "ZDCMULT", //! Multiplicity with the ZDC detector
mult::MultZNA, mult::MultZNC);
mult::MultZNA, mult::MultZNC, mult::MultZEM1, mult::MultZEM2, mult::MultZPA, mult::MultZPC);
DECLARE_SOA_TABLE(TrackletMults, "AOD", "TRKLTMULT", //! Multiplicity with tracklets (only Run2)
mult::MultTracklets);
DECLARE_SOA_TABLE(TPCMults, "AOD", "TPCMULT", //! Multiplicity with TPC
Expand Down Expand Up @@ -124,6 +128,14 @@ DECLARE_SOA_COLUMN(MultBCFT0C, multBCFT0C, float); //!
DECLARE_SOA_COLUMN(MultBCFV0A, multBCFV0A, float); //!
DECLARE_SOA_COLUMN(MultBCFDDA, multBCFDDA, float); //!
DECLARE_SOA_COLUMN(MultBCFDDC, multBCFDDC, float); //!

DECLARE_SOA_COLUMN(MultBCFZNA, multBCFZNA, float); //!
DECLARE_SOA_COLUMN(MultBCFZNC, multBCFZNC, float); //!
DECLARE_SOA_COLUMN(MultBCFZEM1, multBCFZEM1, float); //!
DECLARE_SOA_COLUMN(MultBCFZEM2, multBCFZEM2, float); //!
DECLARE_SOA_COLUMN(MultBCFZPA, multBCFZPA, float); //!
DECLARE_SOA_COLUMN(MultBCFZPC, multBCFZPC, float); //!

DECLARE_SOA_COLUMN(MultBCTVX, multBCTVX, bool); //!
DECLARE_SOA_COLUMN(MultBCFV0OrA, multBCFV0OrA, bool); //!
DECLARE_SOA_COLUMN(MultBCV0triggerBits, multBCV0triggerBits, uint8_t); //!
Expand All @@ -138,6 +150,12 @@ DECLARE_SOA_TABLE(MultsBC, "AOD", "MULTBC", //!
multBC::MultBCFV0A,
multBC::MultBCFDDA,
multBC::MultBCFDDC,
multBC::MultBCFZNA,
multBC::MultBCFZNC,
multBC::MultBCFZEM1,
multBC::MultBCFZEM2,
multBC::MultBCFZPA,
multBC::MultBCFZPC,
multBC::MultBCTVX,
multBC::MultBCFV0OrA,
multBC::MultBCV0triggerBits,
Expand Down
27 changes: 26 additions & 1 deletion Common/TableProducer/multiplicityExtraTable.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,15 @@ struct MultiplicityExtraTable {
float multFV0A = 0.f;
float multFDDA = 0.f;
float multFDDC = 0.f;

// ZDC amplitudes
float multZEM1 = -1.f;
float multZEM2 = -1.f;
float multZNA = -1.f;
float multZNC = -1.f;
float multZPA = -1.f;
float multZPC = -1.f;

uint8_t multFT0TriggerBits = 0;
uint8_t multFV0TriggerBits = 0;
uint8_t multFDDTriggerBits = 0;
Expand Down Expand Up @@ -130,7 +139,23 @@ struct MultiplicityExtraTable {
multFDDC = -999.0f;
}

multBC(multFT0A, multFT0C, multFV0A, multFDDA, multFDDC, Tvx, isFV0OrA, multFV0TriggerBits, multFT0TriggerBits, multFDDTriggerBits, multBCTriggerMask, collidingBC);
if (bc.has_zdc()) {
multZNA = bc.zdc().amplitudeZNA();
multZNC = bc.zdc().amplitudeZNC();
multZEM1 = bc.zdc().amplitudeZEM1();
multZEM2 = bc.zdc().amplitudeZEM2();
multZPA = bc.zdc().amplitudeZPA();
multZPC = bc.zdc().amplitudeZPC();
} else {
multZNA = -999.f;
multZNC = -999.f;
multZEM1 = -999.f;
multZEM2 = -999.f;
multZPA = -999.f;
multZPC = -999.f;
}

multBC(multFT0A, multFT0C, multFV0A, multFDDA, multFDDC, multZNA, multZNC, multZEM1, multZEM2, multZPA, multZPC, Tvx, isFV0OrA, multFV0TriggerBits, multFT0TriggerBits, multFDDTriggerBits, multBCTriggerMask, collidingBC);
}
};

Expand Down
20 changes: 18 additions & 2 deletions Common/TableProducer/multiplicityTable.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ struct MultiplicityTableTaskIndexed {
tableFV0(multFV0A, multFV0C);
tableFT0(multFT0A, multFT0C);
tableFDD(multFDDA, multFDDC);
tableZDC(multZNA, multZNC);
tableZDC(multZNA, multZNC, 0.0f, 0.0f, 0.0f, 0.0f);
tableTracklet(multTracklets);
tableTpc(multTPC);
tablePv(multNContribs, multNContribsEta1, multNContribsEtaHalf);
Expand Down Expand Up @@ -270,6 +270,10 @@ struct MultiplicityTableTaskIndexed {
float multFDDC = 0.f;
float multZNA = -1.f;
float multZNC = -1.f;
float multZEM1 = -1.f;
float multZEM2 = -1.f;
float multZPA = -1.f;
float multZPC = -1.f;
int multNContribs = 0;

float multZeqFV0A = 0.f;
Expand Down Expand Up @@ -372,14 +376,26 @@ struct MultiplicityTableTaskIndexed {
{
multZNA = -1.f;
multZNC = -1.f;
multZEM1 = -1.f;
multZEM2 = -1.f;
multZPA = -1.f;
multZPC = -1.f;
if (bc.has_zdc()) {
multZNA = bc.zdc().amplitudeZNA();
multZNC = bc.zdc().amplitudeZNC();
multZEM1 = bc.zdc().amplitudeZEM1();
multZEM2 = bc.zdc().amplitudeZEM2();
multZPA = bc.zdc().amplitudeZPA();
multZPC = bc.zdc().amplitudeZPC();
} else {
multZNA = -999.f;
multZNC = -999.f;
multZEM1 = -999.f;
multZEM2 = -999.f;
multZPA = -999.f;
multZPC = -999.f;
}
tableZDC(multZNA, multZNC);
tableZDC(multZNA, multZNC, multZEM1, multZEM2, multZPA, multZPC);
LOGF(debug, "multZNA=%6.0f multZNC=%6.0f", multZNA, multZNC);
} break;
case kTrackletMults: // Tracklets (only Run2) nothing to do (to be removed!)
Expand Down
Loading