CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Public Attributes | Static Public Attributes
generateEDF.LumiInfo Class Reference

LumiInfo Class

More...

Inheritance diagram for generateEDF.LumiInfo:

Public Member Functions

def __init__
 
def __str__
 
def deadtime
 
def fixXingInfo
 

Public Attributes

 aveInstLum
 
 badXingInfo
 
 delivered
 
 events
 
 instLums
 
 key
 
 keyString
 
 lumi
 
 numXings
 
 recorded
 
 run
 
 totInstLum
 
 xingInfo
 

Static Public Attributes

int lastSingleXingRun = 136175
 
float lumiSectionLength = 23.310779
 

Detailed Description

LumiInfo Class

Definition at line 26 of file generateEDF.py.

Constructor & Destructor Documentation

def generateEDF.LumiInfo.__init__ (   self,
  line 
)

Definition at line 31 of file generateEDF.py.

31 
32  def __init__ (self, line):
33  self.totInstLum = 0.
34  self.aveInstLum = 0.
35  self.numXings = 0
36  self.instLums = []
37  self.events = []
38  self.xingInfo = False
39  self.badXingInfo = False
40  pieces = sepRE.split (line.strip())
41  size = len (pieces)
42  if size % 2:
43  raise RuntimeError("Odd number of pieces")
44  if size < 4:
45  raise RuntimeError("Not enough pieces")
46  try:
47  self.run = int (pieces[0])
48  self.lumi = int (pieces[1])
49  self.delivered = float (pieces[2])
50  self.recorded = float (pieces[3])
51  except:
52  raise RuntimeError("Pieces not right format")
53  if size > 4:
54  try:
55  for xing, lum in zip (pieces[4::2],pieces[5::2]):
56  xing = int (xing)
57  lum = float (lum)
58  self.instLums.append( (xing, lum) )
59  self.totInstLum += lum
60  self.numXings += 1
61  except:
62  raise RuntimeError("Inst Lumi Info malformed")
63  self.aveInstLum = old_div(self.totInstLum, (self.numXings))
64  self.xingInfo = True
65  self.key = (self.run, self.lumi)
66  self.keyString = self.key.__str__()
67 

Member Function Documentation

def generateEDF.LumiInfo.__str__ (   self)

Definition at line 94 of file generateEDF.py.

References Level1TriggerScalers.deadtime(), generateEDF.LumiInfo.deadtime(), TriggerScalersRaw_v3.deadtime, HCAL_HLX::TRIGGER_LUMI_SEGMENT.deadtime, generateEDF.LumiInfo.delivered, generateEDF.LumiInfo.lumi, DQMNet::CoreObject.lumi, ScalersEventRecordRaw_v1.lumi, ScalersEventRecordRaw_v2.lumi, ScalersEventRecordRaw_v3.lumi, ScalersEventRecordRaw_v4.lumi, ScalersEventRecordRaw_v5.lumi, ScalersEventRecordRaw_v6.lumi, CMTRawAnalyzer.lumi, generateEDF.LumiInfo.numXings, RPCRunIOV::RunIOV_Item.run, TB06RecoH2.run, TB06Reco.run, RPCDQMObject.run, EfficiencyPlotter.run, generateEDF.LumiInfo.run, WZInterestingEventSelector::event.run, MuonRecoTest.run, MatacqProducer::MatacqEventId.run, DTResolutionAnalysisTest.run, Point.run, BeamSpotRcdReader::theBSfromDB.run, DTDataIntegrityTest.run, BeamSpotOnlineRecordsReader::theBSOfromDB.run, DTBlockedROChannelsTest.run, DTResolutionTest.run, DTChamberEfficiencyTest.run, ME::Header.run, DTEfficiencyTest.run, DQMNet::CoreObject.run, personalPlayback.Playback.run, DTLocalTriggerBaseTest.run, MatrixUtil.InputInfo.run, HitEff.run, cond::RunInfo_t.run, SiPixelErrorEstimation.run, personalPlayback.FrameworkJob.run, and generateEDF.LumiInfo.totInstLum.

94 
95  def __str__ (self):
96  return "%6d, %4d: %6.1f (%4.1f%%) %4.2f (%3d)" % \
97  (self.run,
98  self.lumi,
99  self.delivered,
100  self.deadtime(),
101  self.totInstLum,
102  self.numXings)
103 
def generateEDF.LumiInfo.deadtime (   self)

Definition at line 88 of file generateEDF.py.

References generateEDF.LumiInfo.delivered, and generateEDF.LumiInfo.recorded.

Referenced by generateEDF.LumiInfo.__str__().

88 
89  def deadtime (self):
90  if not self.delivered:
91  return 1
92  return 1 - (old_div(self.recorded, self.delivered))
93 
def generateEDF.LumiInfo.fixXingInfo (   self)

Definition at line 68 of file generateEDF.py.

References generateEDF.LumiInfo.aveInstLum, generateEDF.LumiInfo.badXingInfo, generateEDF.LumiInfo.delivered, generateEDF.LumiInfo.keyString, generateEDF.LumiInfo.numXings, RPCRunIOV::RunIOV_Item.run, RPCDQMObject.run, TB06Reco.run, TB06RecoH2.run, EfficiencyPlotter.run, generateEDF.LumiInfo.run, WZInterestingEventSelector::event.run, MuonRecoTest.run, MatacqProducer::MatacqEventId.run, DTResolutionAnalysisTest.run, Point.run, BeamSpotRcdReader::theBSfromDB.run, DTDataIntegrityTest.run, BeamSpotOnlineRecordsReader::theBSOfromDB.run, DTBlockedROChannelsTest.run, DTChamberEfficiencyTest.run, DTResolutionTest.run, ME::Header.run, DTEfficiencyTest.run, DQMNet::CoreObject.run, personalPlayback.Playback.run, DTLocalTriggerBaseTest.run, MatrixUtil.InputInfo.run, HitEff.run, cond::RunInfo_t.run, SiPixelErrorEstimation.run, personalPlayback.FrameworkJob.run, generateEDF.LumiInfo.totInstLum, and generateEDF.LumiInfo.xingInfo.

68 
69  def fixXingInfo (self):
70  if self.numXings:
71  # You shouldn't try and fix an event if it already has
72  # xing information.
73  raise RuntimeError("This event %s already has Xing information" \
74  % self.keyString)
75  if self.run > LumiInfo.lastSingleXingRun:
76  # this run may have more than one crossing. I don't know
77  # how to fix this.
78  self.badXingInfo = True
79  return False
80  self.numXings = 1
81  xing = 1
82  self.aveInstLum = self.totInstLum = lum = \
83  old_div(self.delivered, LumiInfo.lumiSectionLength)
84  self.instLums.append( (xing, lum) )
85  self.xingInfo = True
86  return True
87 

Member Data Documentation

generateEDF.LumiInfo.aveInstLum

Definition at line 33 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.fixXingInfo().

generateEDF.LumiInfo.badXingInfo

Definition at line 38 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.fixXingInfo().

generateEDF.LumiInfo.delivered

Definition at line 48 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.__str__(), generateEDF.LumiInfo.deadtime(), and generateEDF.LumiInfo.fixXingInfo().

generateEDF.LumiInfo.events

Definition at line 36 of file generateEDF.py.

Referenced by eventsfwlite.Events.__getattr__(), looper.Looper.loop(), and looper.Looper.process().

generateEDF.LumiInfo.instLums

Definition at line 35 of file generateEDF.py.

generateEDF.LumiInfo.key

Definition at line 64 of file generateEDF.py.

Referenced by ws_sso_content_reader.HTTPSClientAuthHandler.getConnection().

generateEDF.LumiInfo.keyString

Definition at line 65 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.fixXingInfo().

int generateEDF.LumiInfo.lastSingleXingRun = 136175
static

Definition at line 28 of file generateEDF.py.

generateEDF.LumiInfo.lumi

Definition at line 47 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.__str__(), and upgradeWorkflowComponents.UpgradeWorkflowAging.setup_().

float generateEDF.LumiInfo.lumiSectionLength = 23.310779
static

Definition at line 29 of file generateEDF.py.

generateEDF.LumiInfo.numXings

Definition at line 34 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.__str__(), and generateEDF.LumiInfo.fixXingInfo().

generateEDF.LumiInfo.recorded

Definition at line 49 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.deadtime().

generateEDF.LumiInfo.run

Definition at line 46 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.__str__(), DTWorkflow.DTWorkflow.all(), Types.EventID.cppID(), Types.LuminosityBlockID.cppID(), o2olib.O2OTool.execute(), generateEDF.LumiInfo.fixXingInfo(), and dqm_interfaces.DirWalkerFile.walk().

generateEDF.LumiInfo.totInstLum

Definition at line 32 of file generateEDF.py.

Referenced by generateEDF.LumiInfo.__str__(), and generateEDF.LumiInfo.fixXingInfo().

generateEDF.LumiInfo.xingInfo

Definition at line 37 of file generateEDF.py.

Referenced by generateEDF.LumiInfoCont._integrateContainer(), and generateEDF.LumiInfo.fixXingInfo().