CMS 3D CMS Logo

DIPLumiSummary.h
Go to the documentation of this file.
1 #ifndef RecoLuminosity_LumiProducer_DIPLumiSummary_h
2 #define RecoLuminosity_LumiProducer_DIPLumiSummary_h
3 #include <iosfwd>
4 #include <string>
8 public:
11  : m_runnum(0), m_ls(0), m_instlumi(0.0), m_dellumi(0.0), m_reclumi(0.0), m_deadfrac(1.0), m_cmsalive(false) {}
12 
14  DIPLumiSummary(float instlumi, float dellumi, float reclumi, unsigned short cmsalive)
15  : m_instlumi(instlumi), m_dellumi(dellumi), m_reclumi(reclumi), m_deadfrac(1.0), m_cmsalive(cmsalive) {
16  if (m_reclumi > 0.0) {
17  m_deadfrac = 1.0 - (m_reclumi / m_dellumi);
18  }
19  }
20 
23  bool isNull() const;
28  float instDelLumi() const;
33  float intgDelLumiByLS() const;
38  float intgRecLumiByLS() const;
43  float deadtimefraction() const;
47  int cmsalive() const;
48  //
49  //setters
50  //
54  unsigned int fromRun() const;
58  unsigned int fromLS() const;
59  void setOrigin(unsigned int runnumber, unsigned int ls);
60 
61 private:
62  unsigned int m_runnum;
63  unsigned int m_ls;
64  const float m_instlumi; //avg inst lumi in LS
65  const float m_dellumi; //integrated luminosity of this ls
66  const float m_reclumi;
67  float m_deadfrac;
68  const unsigned short m_cmsalive;
69 };
70 
71 std::ostream& operator<<(std::ostream& s, const DIPLumiSummary& diplumiSummary);
72 
74 
75 #endif // RecoLuminosity_LuminosityProducer_DIPLumiSummary_h
DIPLumiSummary()
default constructor
float intgRecLumiByLS() const
const float m_reclumi
const float m_instlumi
~DIPLumiSummary()
destructor
bool isNull() const
DIPLumiSummary(float instlumi, float dellumi, float reclumi, unsigned short cmsalive)
set default constructor
#define EVENTSETUP_DATA_DEFAULT_RECORD(_data_, _record_)
int cmsalive() const
const unsigned short m_cmsalive
const float m_dellumi
unsigned int m_ls
float deadtimefraction() const
unsigned int m_runnum
unsigned int fromLS() const
void setOrigin(unsigned int runnumber, unsigned int ls)
std::ostream & operator<<(std::ostream &s, const DIPLumiSummary &diplumiSummary)
def ls(path, rec=False)
Definition: eostools.py:349
float intgDelLumiByLS() const
unsigned int fromRun() const
float instDelLumi() const