From 717fe5362418d4dc6ff592b8dbc2028772315554 Mon Sep 17 00:00:00 2001 From: ddobrigk Date: Sun, 8 Sep 2024 12:36:01 +0200 Subject: [PATCH] Common: change bc study table (#7609) * Common: change bc study table * Please consider the following formatting changes (#341) --------- Co-authored-by: ALICE Builder --- Common/DataModel/Multiplicity.h | 29 ++++++++++++------- .../TableProducer/multiplicityExtraTable.cxx | 2 +- Common/Tasks/centralityStudy.cxx | 2 +- Common/Tasks/multiplicityQa.cxx | 2 +- 4 files changed, 21 insertions(+), 14 deletions(-) diff --git a/Common/DataModel/Multiplicity.h b/Common/DataModel/Multiplicity.h index 7116ce66062..03c4888440d 100644 --- a/Common/DataModel/Multiplicity.h +++ b/Common/DataModel/Multiplicity.h @@ -77,9 +77,6 @@ DECLARE_SOA_COLUMN(MultNGlobalTracksPV, multNGlobalTracksPV, int); DECLARE_SOA_COLUMN(MultNGlobalTracksPVeta1, multNGlobalTracksPVeta1, int); DECLARE_SOA_COLUMN(MultNGlobalTracksPVetaHalf, multNGlobalTracksPVetaHalf, int); -DECLARE_SOA_INDEX_COLUMN(BC, bc); -DECLARE_SOA_INDEX_COLUMN(Collision, collision); - // even further QA: timing information for neighboring events DECLARE_SOA_COLUMN(TimeToPrePrevious, timeToPrePrevious, float); //! DECLARE_SOA_COLUMN(TimeToPrevious, timeToPrevious, float); //! @@ -112,12 +109,6 @@ using BarrelMults = soa::Join; using Mults = soa::Join; using Mult = Mults::iterator; -// for QA purposes -DECLARE_SOA_TABLE(Mults2BC, "AOD", "MULTS2BC", //! Relate mult -> BC - o2::soa::Index<>, mult::BCId); -DECLARE_SOA_TABLE(BC2Mults, "AOD", "BC2MULTS", //! Relate BC -> mult - o2::soa::Index<>, mult::CollisionId); - DECLARE_SOA_TABLE(MultsExtra, "AOD", "MULTEXTRA", //! mult::MultPVTotalContributors, mult::MultPVChi2, mult::MultCollisionTimeRes, mult::MultRunNumber, mult::MultPVz, mult::MultSel8, mult::MultNTracksHasITS, mult::MultNTracksHasTPC, mult::MultNTracksHasTOF, mult::MultNTracksHasTRD, @@ -197,7 +188,7 @@ DECLARE_SOA_COLUMN(MultBCFT0PosZ, multBCFT0PosZ, float); //! Position a DECLARE_SOA_COLUMN(MultBCFT0PosZValid, multBCFT0PosZValid, bool); //! Validity of the position along Z computed with the FT0 information within the BC } // namespace multBC -DECLARE_SOA_TABLE(MultsBC, "AOD", "MULTBC", //! +DECLARE_SOA_TABLE(MultBCs, "AOD", "MULTBC", //! multBC::MultBCFT0A, multBC::MultBCFT0C, multBC::MultBCFT0PosZ, @@ -218,7 +209,23 @@ DECLARE_SOA_TABLE(MultsBC, "AOD", "MULTBC", //! multBC::MultBCFDDtriggerBits, multBC::MultBCTriggerMask, multBC::MultBCColliding); -using MultBC = MultsBC::iterator; +using MultBC = MultBCs::iterator; + +// crosslinks +namespace mult +{ +DECLARE_SOA_INDEX_COLUMN(MultBC, multBC); +} +namespace multBC +{ +DECLARE_SOA_INDEX_COLUMN(Mult, mult); +} + +// for QA purposes +DECLARE_SOA_TABLE(Mults2BC, "AOD", "MULTS2BC", //! Relate mult -> BC + o2::soa::Index<>, mult::MultBCId); +DECLARE_SOA_TABLE(BC2Mults, "AOD", "BC2MULTS", //! Relate BC -> mult + o2::soa::Index<>, multBC::MultId); } // namespace o2::aod diff --git a/Common/TableProducer/multiplicityExtraTable.cxx b/Common/TableProducer/multiplicityExtraTable.cxx index c3f1aa9cee3..075b0d108ee 100644 --- a/Common/TableProducer/multiplicityExtraTable.cxx +++ b/Common/TableProducer/multiplicityExtraTable.cxx @@ -30,7 +30,7 @@ using BCPattern = std::bitset; const int nBCsPerOrbit = o2::constants::lhc::LHCMaxBunches; struct MultiplicityExtraTable { - Produces multBC; + Produces multBC; Produces multNeigh; Produces mult2bc; diff --git a/Common/Tasks/centralityStudy.cxx b/Common/Tasks/centralityStudy.cxx index f24fa99f9e2..1ba72958a37 100644 --- a/Common/Tasks/centralityStudy.cxx +++ b/Common/Tasks/centralityStudy.cxx @@ -203,7 +203,7 @@ struct centralityStudy { genericProcessCollision(collision); } - void processBCs(aod::MultsBC::iterator const& multbc) + void processBCs(aod::MultBCs::iterator const& multbc) { // process BCs, calculate FT0C distribution // conditionals suggested by FIT team (Jacek O. et al) diff --git a/Common/Tasks/multiplicityQa.cxx b/Common/Tasks/multiplicityQa.cxx index 72fc827606a..3bf0f769b79 100644 --- a/Common/Tasks/multiplicityQa.cxx +++ b/Common/Tasks/multiplicityQa.cxx @@ -402,7 +402,7 @@ struct MultiplicityQa { histos.fill(HIST("multiplicityQa/h2dFT0MVsNchT0M"), nchFT0, biggestFT0); } - void processFIT(aod::MultsBC const& multsdebug) + void processFIT(aod::MultBCs const& multsdebug) { for (auto& mult : multsdebug) { histos.fill(HIST("multiplicityQa/hIsolatedFT0A"), mult.multBCFT0A());