Skip to content

Commit

Permalink
Common: switch debug interlinks to foundBC (AliceO2Group#7663)
Browse files Browse the repository at this point in the history
* Common: switch debug interlinks to foundBC

* Add flags

* Please consider the following formatting changes (#343)

---------

Co-authored-by: ALICE Builder <[email protected]>
  • Loading branch information
ddobrigk and alibuild authored Sep 12, 2024
1 parent acd8a32 commit a9882fa
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 deletions.
6 changes: 4 additions & 2 deletions Common/DataModel/Multiplicity.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,8 @@ DECLARE_SOA_TABLE(MultsExtra, "AOD", "MULTEXTRA", //!
mult::MultNTracksHasITS, mult::MultNTracksHasTPC, mult::MultNTracksHasTOF, mult::MultNTracksHasTRD,
mult::MultNTracksITSOnly, mult::MultNTracksTPCOnly, mult::MultNTracksITSTPC,
mult::MultAllTracksTPCOnly, mult::MultAllTracksITSTPC,
evsel::NumTracksInTimeRange);
evsel::NumTracksInTimeRange,
collision::Flags);

DECLARE_SOA_TABLE(MultNeighs, "AOD", "MULTNEIGH", //!
mult::TimeToPrePrevious, mult::TimeToPrevious,
Expand Down Expand Up @@ -221,7 +222,8 @@ DECLARE_SOA_TABLE(MultBCs, "AOD", "MULTBC", //!
multBC::MultBCT0triggerBits,
multBC::MultBCFDDtriggerBits,
multBC::MultBCTriggerMask,
multBC::MultBCColliding);
multBC::MultBCColliding,
bc::Flags);
using MultBC = MultBCs::iterator;

// crosslinks
Expand Down
13 changes: 9 additions & 4 deletions Common/TableProducer/multiplicityExtraTable.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ struct MultiplicityExtraTable {

using BCsWithRun3Matchings = soa::Join<aod::BCs, aod::Timestamps, aod::Run3MatchedToBCSparse>;

void processBCs(BCsWithRun3Matchings const& bcs, aod::FV0As const&, aod::FT0s const&, aod::FDDs const&, aod::Zdcs const&, aod::Collisions const& collisions)
void processBCs(soa::Join<BCsWithRun3Matchings, aod::BCFlags> const& bcs, aod::FV0As const&, aod::FT0s const&, aod::FDDs const&, aod::Zdcs const&, soa::Join<aod::Collisions, aod::EvSels> const& collisions)
{
//+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+
// determine saved BCs and corresponding new BC table index
Expand Down Expand Up @@ -98,8 +98,8 @@ struct MultiplicityExtraTable {
//+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+
// interlink: collision -> valid BC, BC -> collision
for (const auto& collision : collisions) {
mult2bc(newBCindex[collision.bcId()]);
bc2multArray[collision.bcId()] = collision.globalIndex();
mult2bc(newBCindex[collision.foundBCId()]);
bc2multArray[collision.foundBCId()] = collision.globalIndex();
}
//+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+-<*>-+

Expand Down Expand Up @@ -213,7 +213,12 @@ struct MultiplicityExtraTable {
}

bc2mult(bc2multArray[bc.globalIndex()]);
multBC(multFT0A, multFT0C, posZFT0, posZFT0valid, multFV0A, multFDDA, multFDDC, multZNA, multZNC, multZEM1, multZEM2, multZPA, multZPC, Tvx, isFV0OrA, multFV0TriggerBits, multFT0TriggerBits, multFDDTriggerBits, multBCTriggerMask, collidingBC);
multBC(
multFT0A, multFT0C, posZFT0, posZFT0valid, multFV0A,
multFDDA, multFDDC, multZNA, multZNC, multZEM1,
multZEM2, multZPA, multZPC, Tvx, isFV0OrA,
multFV0TriggerBits, multFT0TriggerBits, multFDDTriggerBits, multBCTriggerMask, collidingBC,
bc.flags());
}
}

Expand Down
2 changes: 1 addition & 1 deletion Common/TableProducer/multiplicityTable.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ struct MultiplicityTable {
tableExtra(collision.numContrib(), collision.chi2(), collision.collisionTimeRes(),
mRunNumber, collision.posZ(), collision.sel8(),
nHasITS, nHasTPC, nHasTOF, nHasTRD, nITSonly, nTPConly, nITSTPC,
nAllTracksTPCOnly, nAllTracksITSTPC, collision.trackOccupancyInTimeRange());
nAllTracksTPCOnly, nAllTracksITSTPC, collision.trackOccupancyInTimeRange(), collision.flags());
} break;
case kMultSelections: // Multiplicity selections
{
Expand Down

0 comments on commit a9882fa

Please sign in to comment.