Project
Loading...
Searching...
No Matches
AODMcProducerWorkflowSpec.h
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
13
14#ifndef O2_AODMCPRODUCER_WORKFLOW_SPEC
15#define O2_AODMCPRODUCER_WORKFLOW_SPEC
16
17#include "AODProducerHelpers.h"
22#include "Framework/Task.h"
25#include <TStopwatch.h>
26
27#include <string>
28#include <vector>
29
30using namespace o2::framework;
31
33{
34
36{
37 public:
39 ~AODMcProducerWorkflowDPL() override = default;
40 void init(InitContext& ic) final;
41 void run(ProcessingContext& pc) final;
42 void endOfStream(EndOfStreamContext& ec) final;
43
48 using Origins = aod::Origins;
49 using XSections = aod::HepMCXSections;
50 using PdfInfos = aod::HepMCPdfInfos;
51 using HeavyIons = aod::HepMCHeavyIons;
54 private:
56 using CollisionCursor = aodmchelpers::CollisionCursor;
57 using XSectionCursor = aodmchelpers::XSectionCursor;
58 using PdfInfoCursor = aodmchelpers::PdfInfoCursor;
59 using HeavyIonCursor = aodmchelpers::HeavyIonCursor;
98 void updateHeader(CollisionCursor& collisionCursor,
99 XSectionCursor& xSectionCursor,
100 PdfInfoCursor& pdfInfoCursor,
101 HeavyIonCursor& heavyIonCursor,
102 const MCEventHeader& header,
103 int collisionID, // Index
104 int bcID,
105 float time,
106 short generatorID,
107 int sourceID);
109 int64_t mTFNumber{1};
112 int mFilterMC{0};
114 bool mEnableEmbed{false};
116 TString mLPMProdTag{""};
118 TString mAnchorPass{""};
120 TString mAnchorProd{""};
122 TString mRecoPass{""};
124 TStopwatch mTimer;
126 HepMCUpdate mXSectionUpdate = HepMCUpdate::anyKey;
127 HepMCUpdate mPdfInfoUpdate = HepMCUpdate::anyKey;
128 HepMCUpdate mHeavyIonUpdate = HepMCUpdate::anyKey;
129
130 std::string mSimPrefix;
131
132 // MC production metadata holder
133 bool mIsMDSent{false};
134
135 // truncation is enabled by default
136 uint32_t mCollisionPosition = 0xFFFFFFF0; // 19 bits mantissa
137 uint32_t mMcParticleW = 0xFFFFFFF0; // 19 bits
138 uint32_t mMcParticlePos = 0xFFFFFFF0; // 19 bits
139 uint32_t mMcParticleMom = 0xFFFFFFF0; // 19 bits
140};
141
144
145} // namespace o2::aodmcproducer
146
147#endif /* O2_AODMCPRODUCER_WORKFLOW_SPEC */
int16_t time
Definition RawEventData.h:4
void endOfStream(EndOfStreamContext &ec) final
This is invoked whenever we have an EndOfStream event.
StoredMcParticles_001 StoredMcParticles
McCollisions_001 McCollisions
TableCursor< aod::HepMCPdfInfos >::type PdfInfoCursor
TableCursor< aod::HepMCHeavyIons >::type HeavyIonCursor
TableCursor< aod::HepMCXSections >::type XSectionCursor
TableCursor< aod::McCollisions >::type CollisionCursor
framework::DataProcessorSpec getAODMcProducerWorkflowSpec()
create a processor spec
Defining PrimaryVertex explicitly as messageable.
Definition TFIDInfo.h:20