32namespace strangeness_tracking
69 ic.
options().
get<std::string>(
"strange-tracks-infile"));
75 auto ent =
mTree->GetReadEntry() + 1;
81 const bool noEntry = ent >=
mTree->GetEntries();
83 LOG(info) <<
"no entry to read, publishing empty output";
87 LOG(info) <<
"Pushing " <<
mStrangeTrack.size() <<
" strange tracks at entry " << ent;
91 LOG(info) <<
"Pushing " <<
mStrangeTrackMC.size() <<
" strange tracks MC labels at entry " << ent;
97 if (noEntry ||
mTree->GetReadEntry() + 1 >=
mTree->GetEntries()) {
105 mTree.reset(
nullptr);
123 std::vector<OutputSpec> outputs;
124 outputs.emplace_back(
"GLO",
"STRANGETRACKS", 0, Lifetime::Timeframe);
126 outputs.emplace_back(
"GLO",
"STRANGETRACKS_MC", 0, Lifetime::Timeframe);
130 "strangeness-tracking-reader",
133 AlgorithmSpec{adaptFromTask<StrangenessTrackingReader>(useMC)},
135 {
"strange-tracks-infile", VariantType::String,
"o2_strange_tracks.root", {
"Name of the input strange tracks file"}},
136 {
"input-dir", VariantType::String,
"none", {
"Input directory"}}}};
Definition of the Names Generator class.
Class to refer to the 1st entry and N elements of some group in the continuous container.
T get(const char *key) const
void snapshot(const Output &spec, T const &object)
ConfigParamRegistry const & options()
DataAllocator & outputs()
The data allocator is used to allocate memory for the output data.
ServiceRegistryRef services()
The services registry associated with this processing context.
virtual void endOfStream(EndOfStreamContext &context)
This is invoked whenever we have an EndOfStream event.
std::string mFileNameMatches
std::string mStrackMCBranchName
std::string mStrackBranchName
std::unique_ptr< TTree > mTree
void run(o2::framework::ProcessingContext &pc) final
void init(o2::framework::InitContext &ic) final
~StrangenessTrackingReader() override=default
std::string mSTrackingTreeName
std::vector< StrangeTrack > mStrangeTrack
std::vector< o2::MCCompLabel > * mStrangeTrackMCPtr
std::unique_ptr< TFile > mFile
std::vector< StrangeTrack > * mStrangeTrackPtr
std::vector< o2::MCCompLabel > mStrangeTrackMC
StrangenessTrackingReader(bool useMC)
Defining ITS Vertex explicitly as messageable.
std::vector< ConfigParamSpec > Options
std::vector< InputSpec > Inputs
o2::framework::DataProcessorSpec getStrangenessTrackingReaderSpec(bool useMC)
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
static std::string rectifyDirectory(const std::string_view p)
static std::string concat_string(Ts const &... ts)
LOG(info)<< "Compressed in "<< sw.CpuTime()<< " s"