Definition at line 13 of file AodEventInfo.py.
◆ __init__()
def AodEventInfo.PyxAODEventInfo.__init__ |
( |
|
self, |
|
|
|
name = 'PyxAODEventInfo' , |
|
|
** |
kwds |
|
) |
| |
Definition at line 16 of file AodEventInfo.py.
16 def __init__(self, name = 'PyxAODEventInfo', **kwds):
19 self.isMC = kwds.get(
'isMC',
False)
20 self.prefix = kwds.get(
'prefix')
◆ execute()
def AodEventInfo.PyxAODEventInfo.execute |
( |
|
self | ) |
|
Definition at line 40 of file AodEventInfo.py.
43 if self.sg.
contains(
'xAOD::EventInfo',
'EventInfo'):
44 ei = self.sg.
retrieve(
'xAOD::EventInfo',
'EventInfo')
45 runNumber = ei.runNumber()
46 eventNumber = ei.eventNumber()
47 mcChannelNumber = ei.mcChannelNumber()
49 self.info[
'run_number'].
append(runNumber)
50 self.info[
'mc_channel_number'].
append(mcChannelNumber)
51 self.info[
'event_number'].
append(eventNumber)
54 return StatusCode.Success
57 return StatusCode.Failure
◆ finalize()
def AodEventInfo.PyxAODEventInfo.finalize |
( |
|
self | ) |
|
Definition at line 30 of file AodEventInfo.py.
32 key_name =
'run_number'
34 key_name =
'mc_channel_number'
35 for run, event
in zip(self.info[key_name], self.info[
'event_number']):
36 print(f
"{'' if self.prefix is None else self.prefix}{run:d} {event:d}")
37 return StatusCode.Success
◆ initialize()
def AodEventInfo.PyxAODEventInfo.initialize |
( |
|
self | ) |
|
Definition at line 23 of file AodEventInfo.py.
24 self.sg =
py_svc(
'StoreGateSvc')
25 from collections
import defaultdict
26 self.info = defaultdict(list)
27 return StatusCode.Success
◆ info
AodEventInfo.PyxAODEventInfo.info |
◆ isMC
AodEventInfo.PyxAODEventInfo.isMC |
◆ prefix
AodEventInfo.PyxAODEventInfo.prefix |
◆ sg
AodEventInfo.PyxAODEventInfo.sg |
The documentation for this class was generated from the following file: