99// granted to it by virtue of its status as an Intergovernmental Organization
1010// or submit itself to any jurisdiction.
1111
12- // / \file eventSelectionTester .cxx
12+ // / \file eventSelectionService .cxx
1313// / \brief unified, self-configuring event selection task
1414// / \author ALICE
1515
16- // ===============================================================
17- //
18- // Unified, self-configuring event selection task
19- //
20- // ===============================================================
21-
2216#include " Common/Core/MetadataHelper.h"
2317#include " Common/DataModel/EventSelection.h"
2418#include " Common/Tools/EventSelectionModule.h"
@@ -50,14 +44,14 @@ using BCsWithRun3Matchings = soa::Join<aod::BCs, aod::Run3MatchedToBCSparse>;
5044using FullTracks = soa::Join<aod::Tracks, aod::TracksExtra>;
5145using FullTracksIU = soa::Join<aod::TracksIU, aod::TracksExtra>;
5246
53- struct eventselectionRun2 {
54- o2::common::timestamp::timestampConfigurables timestampConfigurables;
47+ struct EventselectionRun2 { // o2-linter: disable=name/workflow-file (exception due to metadata-driven topology)
48+ o2::common::timestamp::TimestampConfigurables timestampConfigurables;
5549 o2::common::timestamp::TimestampModule timestampMod;
5650
57- o2::common::eventselection::bcselConfigurables bcselOpts;
51+ o2::common::eventselection::BcselConfigurables bcselOpts;
5852 o2::common::eventselection::BcSelectionModule bcselmodule;
5953
60- o2::common::eventselection::evselConfigurables evselOpts;
54+ o2::common::eventselection::EvselConfigurables evselOpts;
6155 o2::common::eventselection::EventSelectionModule evselmodule;
6256
6357 Produces<aod::Timestamps> timestampTable; // / Table with SOR timestamps produced by the task
@@ -75,7 +69,7 @@ struct eventselectionRun2 {
7569
7670 // buffering intermediate results for passing
7771 std::vector<uint64_t > timestamps;
78- std::vector<o2::common::eventselection::bcselEntry > bcselsbuffer;
72+ std::vector<o2::common::eventselection::BcselEntry > bcselsbuffer;
7973
8074 // auxiliary
8175 Partition<FullTracks> tracklets = (aod::track::trackType == static_cast <uint8_t >(o2::aod::track::TrackTypeEnum::Run2Tracklet));
@@ -109,17 +103,17 @@ struct eventselectionRun2 {
109103 }
110104};
111105
112- struct eventselectionRun3 {
113- o2::common::timestamp::timestampConfigurables timestampConfigurables;
106+ struct EventselectionRun3 { // o2-linter: disable=name/workflow-file (exception due to metadata-driven topology)
107+ o2::common::timestamp::TimestampConfigurables timestampConfigurables;
114108 o2::common::timestamp::TimestampModule timestampMod;
115109
116- o2::common::eventselection::bcselConfigurables bcselOpts;
110+ o2::common::eventselection::BcselConfigurables bcselOpts;
117111 o2::common::eventselection::BcSelectionModule bcselmodule;
118112
119- o2::common::eventselection::evselConfigurables evselOpts;
113+ o2::common::eventselection::EvselConfigurables evselOpts;
120114 o2::common::eventselection::EventSelectionModule evselmodule;
121115
122- o2::common::eventselection::lumiConfigurables lumiOpts;
116+ o2::common::eventselection::LumiConfigurables lumiOpts;
123117 o2::common::eventselection::LumiModule lumimodule;
124118
125119 Produces<aod::Timestamps> timestampTable; // / Table with SOR timestamps produced by the task
@@ -138,7 +132,7 @@ struct eventselectionRun3 {
138132 // the best: have readable cursors
139133 // this: a stopgap solution to avoid spawning yet another device
140134 std::vector<uint64_t > timestamps;
141- std::vector<o2::common::eventselection::bcselEntry > bcselsbuffer;
135+ std::vector<o2::common::eventselection::BcselEntry > bcselsbuffer;
142136
143137 // auxiliary
144138 Partition<FullTracksIU> pvTracks = ((aod::track::flags & static_cast <uint32_t >(o2::aod::track::PVContributor)) == static_cast <uint32_t >(o2::aod::track::PVContributor));
@@ -173,7 +167,7 @@ struct eventselectionRun3 {
173167 }
174168};
175169
176- WorkflowSpec defineDataProcessing (ConfigContext const & cfgc)
170+ WorkflowSpec defineDataProcessing (ConfigContext const & cfgc) // o2-linter: disable=o2-workflow-options (metadata-driven topology selection)
177171{
178172 // Parse the metadata for later too
179173 metadataInfo.initMetadata (cfgc);
@@ -191,18 +185,18 @@ WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
191185 LOGF (warn, " Metadata info missing or incomplete. Make sure --aod-file is provided at the end of the last workflow and that the AO2D has metadata stored." );
192186 LOGF (warn, " Initializing with Run 3 data as default. Please note you will not be able to change settings manually." );
193187 LOGF (warn, " You should instead make sure the metadata is read in correctly." );
194- return WorkflowSpec{adaptAnalysisTask<eventselectionRun3 >(cfgc)};
188+ return WorkflowSpec{adaptAnalysisTask<EventselectionRun3 >(cfgc)};
195189 } else {
196190 LOGF (info, " Metadata successfully read in. Is this Run 3? %i - will self-configure." , isRun3);
197191 if (isRun3) {
198- return WorkflowSpec{adaptAnalysisTask<eventselectionRun3 >(cfgc)};
192+ return WorkflowSpec{adaptAnalysisTask<EventselectionRun3 >(cfgc)};
199193 } else {
200194 LOGF (warn, " ******************************************************************" );
201195 LOGF (warn, " Event selection service self-configuring for Run 2." );
202196 LOGF (warn, " WARNING: THIS HAS NOT BEEN VALIDATED YET, USE WITH CAUTION" );
203197 LOGF (warn, " If this fails, please use event-selection-service-run2 instead." );
204198 LOGF (warn, " ******************************************************************" );
205- return WorkflowSpec{adaptAnalysisTask<eventselectionRun2 >(cfgc)};
199+ return WorkflowSpec{adaptAnalysisTask<EventselectionRun2 >(cfgc)};
206200 }
207201 }
208202 throw std::runtime_error (" Unsupported run type / problem when configuring event selection!" );
0 commit comments