Public Member Functions | Private Attributes | List of all members
cmf::EventList Class Reference

#include "/cvmfs/nova-development.opensciencegrid.org/novasoft/releases/N21-04-21/CovarianceMatrixFit/core/Event.h"

Public Member Functions

 EventList (cmf::MetaData const &md)
 
 EventList (cmf::MetaData const &md, cmf::SpillSummary const &ss)
 
cmf::EventContainer::iterator begin ()
 
cmf::EventContainer::const_iterator begin () const
 
cmf::EventContainer::iterator end ()
 
cmf::EventContainer::const_iterator end () const
 
std::size_t size () const
 
void clear ()
 
bool empty () const
 
void AddEvent (EventPtr const &ev)
 
void AddEvent (cmf::EventId const &eid, cmf::DataVarVals const &dataVars, cmf::MCVarVals const &mcVars)
 
void AddEvent (cmf::DataVarVals const &dataVars, cmf::MCVarVals const &mcVars)
 
void AddEvent (cmf::EventId const &eid, cmf::DataVarVals const &dataVars)
 
void AddEvent (cmf::DataVarVals const &dataVars)
 
double TotalEvents () const
 
cmf::SpillSummary const & ListSpillSummary () const
 
void AddSpillSummary (cmf::SpillSummary const &ss)
 
void ScaleExposure (double const &scale)
 
cmf::MetaData const & ListMetaData () const
 
bool operator== (EventList const &other) const
 
bool operator< (EventList const &other) const
 

Private Attributes

cmf::EventContainer fEvents
 
cmf::MetaData fMetaData
 what kind of files was this EventList constructed from? More...
 
cmf::SpillSummary fSpillSummary
 aggregate information about the spills that went into this EventList (POT, # good spills, etc.) More...
 

Detailed Description

Definition at line 94 of file Event.h.

Constructor & Destructor Documentation

cmf::EventList::EventList ( cmf::MetaData const &  md)
inlineexplicit

Definition at line 99 of file Event.h.

100  : fMetaData(md)
101  {}
cmf::MetaData fMetaData
what kind of files was this EventList constructed from?
Definition: Event.h:146
cmf::EventList::EventList ( cmf::MetaData const &  md,
cmf::SpillSummary const &  ss 
)
inline

Definition at line 104 of file Event.h.

106  : fMetaData(md)
107  , fSpillSummary(ss)
108  {
109  }
Float_t ss
Definition: plot.C:24
cmf::MetaData fMetaData
what kind of files was this EventList constructed from?
Definition: Event.h:146
cmf::SpillSummary fSpillSummary
aggregate information about the spills that went into this EventList (POT, # good spills...
Definition: Event.h:147

Member Function Documentation

void cmf::EventList::AddEvent ( EventPtr const &  ev)
inline

Definition at line 165 of file Event.h.

References MF_LOG_DEBUG.

Referenced by cmf::EventListManipulator::FillEventList().

166  {
167  MF_LOG_DEBUG("EventListManipulator")
168  << *ev;
169 
170  if(ev->EventIDFilled() ){
171  if(ev->DataValsFilled() &&
172  ev->MCValsFilled() )
173  this->fEvents.push_back(std::make_unique<cmf::Event>(ev->EventID(),
174  ev->DataVals(),
175  ev->MCVals()));
176  else
177  this->fEvents.push_back(std::make_unique<cmf::Event>(ev->EventID(),
178  ev->DataVals()));
179  }
180  else{
181  if(ev->DataValsFilled() &&
182  ev->MCValsFilled() )
183  this->fEvents.push_back(std::make_unique<cmf::Event>(ev->DataVals(),
184  ev->MCVals()));
185  else
186  this->fEvents.push_back(std::make_unique<cmf::Event>(ev->DataVals()));
187  }
188  }
#define MF_LOG_DEBUG(id)
cmf::EventContainer fEvents
Definition: Event.h:145
void cmf::EventList::AddEvent ( cmf::EventId const &  eid,
cmf::DataVarVals const &  dataVars,
cmf::MCVarVals const &  mcVars 
)
inline

Definition at line 191 of file Event.h.

194  {
195  this->fEvents.push_back(std::make_unique<cmf::Event>(eid, dataVars, mcVars));
196  }
cmf::EventContainer fEvents
Definition: Event.h:145
void cmf::EventList::AddEvent ( cmf::DataVarVals const &  dataVars,
cmf::MCVarVals const &  mcVars 
)
inline

Definition at line 199 of file Event.h.

201  {
202  this->fEvents.push_back(std::make_unique<cmf::Event>(dataVars, mcVars));
203  }
cmf::EventContainer fEvents
Definition: Event.h:145
void cmf::EventList::AddEvent ( cmf::EventId const &  eid,
cmf::DataVarVals const &  dataVars 
)
inline

Definition at line 212 of file Event.h.

214  {
215  this->fEvents.push_back(std::make_unique<cmf::Event>(eid, dataVars));
216  }
cmf::EventContainer fEvents
Definition: Event.h:145
void cmf::EventList::AddEvent ( cmf::DataVarVals const &  dataVars)
inline

Definition at line 206 of file Event.h.

207  {
208  this->fEvents.push_back(std::make_unique<cmf::Event>(dataVars));
209  }
cmf::EventContainer fEvents
Definition: Event.h:145
void cmf::EventList::AddSpillSummary ( cmf::SpillSummary const &  ss)
inline

Definition at line 159 of file Event.h.

References ss.

160  {
161  this->fSpillSummary += ss;
162  }
Float_t ss
Definition: plot.C:24
cmf::SpillSummary fSpillSummary
aggregate information about the spills that went into this EventList (POT, # good spills...
Definition: Event.h:147
cmf::EventContainer::iterator cmf::EventList::begin ( )
inline

Definition at line 112 of file Event.h.

112 { return fEvents.begin(); }
cmf::EventContainer fEvents
Definition: Event.h:145
cmf::EventContainer::const_iterator cmf::EventList::begin ( ) const
inline

Definition at line 113 of file Event.h.

113 { return fEvents.begin(); }
cmf::EventContainer fEvents
Definition: Event.h:145
void cmf::EventList::clear ( )
inline

Definition at line 153 of file Event.h.

154  {
155  fEvents.clear();
156  }
cmf::EventContainer fEvents
Definition: Event.h:145
bool cmf::EventList::empty ( ) const
inline

Definition at line 118 of file Event.h.

118 { return fEvents.empty(); }
cmf::EventContainer fEvents
Definition: Event.h:145
cmf::EventContainer::iterator cmf::EventList::end ( )
inline

Definition at line 114 of file Event.h.

114 { return fEvents.end(); }
cmf::EventContainer fEvents
Definition: Event.h:145
cmf::EventContainer::const_iterator cmf::EventList::end ( ) const
inline

Definition at line 115 of file Event.h.

115 { return fEvents.end(); }
cmf::EventContainer fEvents
Definition: Event.h:145
cmf::MetaData const& cmf::EventList::ListMetaData ( ) const
inline

Definition at line 138 of file Event.h.

Referenced by cmf::EventListManipulator::FillEventList(), operator<(), and operator==().

138 { return this->fMetaData; }
cmf::MetaData fMetaData
what kind of files was this EventList constructed from?
Definition: Event.h:146
cmf::SpillSummary const& cmf::EventList::ListSpillSummary ( ) const
inline

Definition at line 133 of file Event.h.

References ss.

Referenced by cmf::EventListManipulator::FillEventList(), and cmf::FillSpectrumFromSingleList().

133 { return this->fSpillSummary; }
cmf::SpillSummary fSpillSummary
aggregate information about the spills that went into this EventList (POT, # good spills...
Definition: Event.h:147
bool cmf::EventList::operator< ( EventList const &  other) const
inline

Definition at line 141 of file Event.h.

References ListMetaData().

141 { return fMetaData < other.ListMetaData(); }
cmf::MetaData fMetaData
what kind of files was this EventList constructed from?
Definition: Event.h:146
bool cmf::EventList::operator== ( EventList const &  other) const
inline

Definition at line 140 of file Event.h.

References ListMetaData().

140 { return fMetaData == other.ListMetaData(); }
cmf::MetaData fMetaData
what kind of files was this EventList constructed from?
Definition: Event.h:146
void cmf::EventList::ScaleExposure ( double const &  scale)
inline

Definition at line 136 of file Event.h.

References scale.

136 { this->fSpillSummary *= scale; }
Double_t scale
Definition: plot.C:25
cmf::SpillSummary fSpillSummary
aggregate information about the spills that went into this EventList (POT, # good spills...
Definition: Event.h:147
std::size_t cmf::EventList::size ( ) const
inline

Definition at line 116 of file Event.h.

References clear.

Referenced by cmf::EventListManipulator::FillEventList().

116 { return fEvents.size(); }
cmf::EventContainer fEvents
Definition: Event.h:145
double cmf::EventList::TotalEvents ( ) const
inline

Definition at line 219 of file Event.h.

References dirName, events(), cmf::FindEventList(), fetch_tb_beamline_files::md, cmf::SerializeEventListColl(), cmf::SerializeEvents(), string, and produceInfoGainMatrix::total.

220  {
221  double total = 0.;
222 
223  for(auto const& itr : fEvents) total += itr->DataVals().FakeWeight();
224 
225  return total;
226  }
cmf::EventContainer fEvents
Definition: Event.h:145

Member Data Documentation

cmf::EventContainer cmf::EventList::fEvents
private

Definition at line 145 of file Event.h.

cmf::MetaData cmf::EventList::fMetaData
private

what kind of files was this EventList constructed from?

Definition at line 146 of file Event.h.

cmf::SpillSummary cmf::EventList::fSpillSummary
private

aggregate information about the spills that went into this EventList (POT, # good spills, etc.)

Definition at line 147 of file Event.h.


The documentation for this class was generated from the following file: