ATLAS Offline Software
Public Member Functions | List of all members
python.AsgAnalysisConfig.EventCutFlowBlock Class Reference
Inheritance diagram for python.AsgAnalysisConfig.EventCutFlowBlock:
Collaboration diagram for python.AsgAnalysisConfig.EventCutFlowBlock:

Public Member Functions

def __init__ (self)
 
def instanceName (self)
 
def makeAlgs (self, config)
 

Detailed Description

the ConfigBlock for an event-level cutflow

Definition at line 550 of file AsgAnalysisConfig.py.

Constructor & Destructor Documentation

◆ __init__()

def python.AsgAnalysisConfig.EventCutFlowBlock.__init__ (   self)

Definition at line 553 of file AsgAnalysisConfig.py.

553  def __init__ (self) :
554  super (EventCutFlowBlock, self).__init__ ()
555  self.addOption ('containerName', '', type=str,
556  noneAction='error',
557  info="the name of the input container, typically EventInfo.")
558  self.addOption ('selectionName', '', type=str,
559  noneAction='error',
560  info="the name of an optional selection decoration to use.")
561  self.addOption ('customSelections', [], type=None,
562  info="the selections for which to generate cutflow histograms. If "
563  "a single string, corresponding to a particular event selection, "
564  "the event cutflow for that selection will be looked up. If a list "
565  "of strings, will use explicitly those selections. If left blank, "
566  "all selections attached to the container will be looked up.")
567  self.addOption ('postfix', '', type=str,
568  info="a postfix to apply in the naming of cutflow histograms. Set "
569  "it when defining multiple cutflows.")
570 

Member Function Documentation

◆ instanceName()

def python.AsgAnalysisConfig.EventCutFlowBlock.instanceName (   self)
Return the instance name for this block

Definition at line 571 of file AsgAnalysisConfig.py.

571  def instanceName (self) :
572  """Return the instance name for this block"""
573  return self.containerName + '_' + self.selectionName + self.postfix
574 

◆ makeAlgs()

def python.AsgAnalysisConfig.EventCutFlowBlock.makeAlgs (   self,
  config 
)

Definition at line 575 of file AsgAnalysisConfig.py.

575  def makeAlgs (self, config) :
576 
577  postfix = self.postfix
578  if postfix != '' and postfix[0] != '_' :
579  postfix = '_' + postfix
580 
581  alg = config.createAlgorithm( 'CP::EventCutFlowHistAlg', 'CutFlowDumperAlg' )
582  alg.histPattern = 'cflow_' + self.containerName + "_" + self.selectionName + postfix + '_%SYS%'
583  # find out which selection decorations to use
584  if isinstance(self.customSelections, str):
585  # user provides a dynamic reference to selections, corresponding to an EventSelection alg
586  alg.selections = config.getEventCutFlow(self.customSelections)
587  elif len(self.customSelections) > 0:
588  # user provides a list of hardcoded selections
589  alg.selections = self.customSelections
590  else:
591  # user provides nothing: get all available selections from EventInfo directly
592  alg.selections = config.getSelectionCutFlow (self.containerName, self.selectionName)
593  alg.selections = [sel+',as_char' for sel in alg.selections]
594  if self.selectionName:
595  alg.preselection = self.selectionName + '_%SYS%'
596  alg.eventInfo = config.readName (self.containerName)
597  alg.histTitle = "Event Cutflow: " + self.containerName + "." + self.selectionName
598 
599 

The documentation for this class was generated from the following file:
python.processes.powheg.ZZj_MiNNLO.ZZj_MiNNLO.__init__
def __init__(self, base_directory, **kwargs)
Constructor: all process options are set here.
Definition: ZZj_MiNNLO.py:18