NAIA  1.1.1
FileInfo.h
Go to the documentation of this file.
1 
7 #ifndef NAIA_FILEINFO_H
8 #define NAIA_FILEINFO_H
9 
10 #include "Containers/Utils.h"
11 
12 #include "Rtypes.h"
13 #include "TObject.h"
14 
15 namespace NAIA {
23 class FileInfo : public TObject {
24 public:
29  void Clear();
30 
35  void Dump() const;
36 
37  unsigned int Run = 0;
38  unsigned int NEvents = 0;
39  std::pair<unsigned int, unsigned int> UTCTime{0, 0};
40  std::pair<unsigned int, unsigned int> EventNo{0, 0};
41  std::string FileName{""};
42 
43  int BadRunTag = 0;
44  std::string BadRunReason{""};
45 
47 };
48 
54 class MCFileInfo : public TObject {
55 public:
62  enum class SimFocus {
63  NONE = 0,
64  L1,
65  L19,
66  TB,
67 
68  };
69 
75  [[nodiscard]] unsigned int GetNGen() const;
76 
82  [[nodiscard]] double GetRMin() const;
83 
89  [[nodiscard]] double GetRMax() const;
90 
95  void Clear();
96 
101  void Dump() const;
102 
103  unsigned int Charge = 0;
104  float Mass = 0;
105  int DatacardPID = 0;
106  unsigned int DatacardNGen = 0;
107 
108  std::pair<unsigned int, unsigned int> EventNo{0, 0};
109  std::pair<float, float> MomentumRange{0, 0};
110  std::pair<float, float> DatacardMomentumRange{0, 0};
111 
113 
115 };
116 } // namespace NAIA
117 
118 #endif
NAIA::MCFileInfo::GetRMax
double GetRMax() const
Get the upper edge of the rigidity generation range.
Definition: FileInfo.cpp:54
NAIA::MCFileInfo
Container class for additional MC File information.
Definition: FileInfo.h:54
NAIA::MCFileInfo::DatacardPID
int DatacardPID
Geant4 PID of the primary particle (from datacard)
Definition: FileInfo.h:105
NAIA::MCFileInfo::ClassDef
ClassDef(MCFileInfo, 1)
NAIA::MCFileInfo::Charge
unsigned int Charge
Atomic number of the primary particle.
Definition: FileInfo.h:103
NAIA::MCFileInfo::Mass
float Mass
Mass of the primary particle in GeV/c^2.
Definition: FileInfo.h:104
NAIA::FileInfo::BadRunTag
int BadRunTag
If this is a bad run, the tag as returned by AMSSetupR::IsBadRun.
Definition: FileInfo.h:43
NAIA::MCFileInfo::SimFocus::NONE
@ NONE
NAIA::MCFileInfo::GetNGen
unsigned int GetNGen() const
Estimates of the total number of requested events at generation level.
Definition: FileInfo.cpp:28
NAIA::MCFileInfo::Focus
SimFocus Focus
Simulation focus.
Definition: FileInfo.h:112
NAIA::FileInfo
Container class for processed File information.
Definition: FileInfo.h:23
NAIA::FileInfo::Run
unsigned int Run
Run number.
Definition: FileInfo.h:37
NAIA::MCFileInfo::SimFocus::L1
@ L1
particles shot towards Layer 1
NAIA
Definition: Event.h:13
NAIA::MCFileInfo::DatacardNGen
unsigned int DatacardNGen
Number of generated events from datacard.
Definition: FileInfo.h:106
Utils.h
NAIA::MCFileInfo::SimFocus
SimFocus
Enum specifying the type of simulation.
Definition: FileInfo.h:62
NAIA::MCFileInfo::SimFocus::L19
@ L19
particles shot towards layer 1 and passing through layer 9
NAIA::MCFileInfo::GetRMin
double GetRMin() const
Get the lower edge of the rigidity generation range.
Definition: FileInfo.cpp:46
NAIA::FileInfo::Dump
void Dump() const
Dump on screen container content.
Definition: FileInfo.cpp:15
NAIA::MCFileInfo::MomentumRange
std::pair< float, float > MomentumRange
Momentum range as estimated from the events.
Definition: FileInfo.h:109
NAIA::MCFileInfo::DatacardMomentumRange
std::pair< float, float > DatacardMomentumRange
Momentum range as estimated from the datacard.
Definition: FileInfo.h:110
NAIA::FileInfo::ClassDef
ClassDef(FileInfo, 1)
NAIA::MCFileInfo::EventNo
std::pair< unsigned int, unsigned int > EventNo
First / last event in the file.
Definition: FileInfo.h:108
NAIA::FileInfo::UTCTime
std::pair< unsigned int, unsigned int > UTCTime
First and last second of this run.
Definition: FileInfo.h:39
NAIA::FileInfo::EventNo
std::pair< unsigned int, unsigned int > EventNo
First and last event of this run.
Definition: FileInfo.h:40
NAIA::FileInfo::Clear
void Clear()
Clear container content.
Definition: FileInfo.cpp:6
NAIA::MCFileInfo::SimFocus::TB
@ TB
test beam simulation
NAIA::MCFileInfo::Dump
void Dump() const
Dump on screen container content.
Definition: FileInfo.cpp:73
NAIA::MCFileInfo::Clear
void Clear()
Clear container content.
Definition: FileInfo.cpp:62
NAIA::FileInfo::BadRunReason
std::string BadRunReason
If this is a bad run, the reason as returned by AMSSetupR::IsBadRun.
Definition: FileInfo.h:44
NAIA::FileInfo::FileName
std::string FileName
Name of the processed file.
Definition: FileInfo.h:41
NAIA::FileInfo::NEvents
unsigned int NEvents
Total number of processed events.
Definition: FileInfo.h:38