ATLAS Offline Software
Loading...
Searching...
No Matches
python.AsgAnalysisConfig.PerEventSFBlock Class Reference
Inheritance diagram for python.AsgAnalysisConfig.PerEventSFBlock:
Collaboration diagram for python.AsgAnalysisConfig.PerEventSFBlock:

Public Member Functions

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

Detailed Description

the ConfigBlock for the AsgEventScaleFactorAlg

Definition at line 851 of file AsgAnalysisConfig.py.

Constructor & Destructor Documentation

◆ __init__()

python.AsgAnalysisConfig.PerEventSFBlock.__init__ ( self)

Definition at line 854 of file AsgAnalysisConfig.py.

854 def __init__ (self):
855 super(PerEventSFBlock, self).__init__()
856 self.addOption('algoName', None, type=str,
857 info="unique name given to the underlying algorithm computing the "
858 "per-event scale factors.")
859 self.addOption('particles', '', type=str,
860 info="the input object container, with a possible selection, in the "
861 "format `container` or `container.selection`.")
862 self.addOption('objectSF', '', type=str,
863 info="the name of the per-object SF decoration to be used.")
864 self.addOption('eventSF', '', type=str,
865 info="the name of the per-event SF decoration.")
866

Member Function Documentation

◆ instanceName()

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

Definition at line 867 of file AsgAnalysisConfig.py.

867 def instanceName (self) :
868 """Return the instance name for this block"""
869 return self.particles + '_' + self.objectSF + '_' + self.eventSF
870

◆ makeAlgs()

python.AsgAnalysisConfig.PerEventSFBlock.makeAlgs ( self,
config )

Definition at line 871 of file AsgAnalysisConfig.py.

871 def makeAlgs(self, config):
872 if config.dataType() is DataType.Data:
873 return
874 particles, selection = config.readNameAndSelection(self.particles)
875 alg = config.createAlgorithm('CP::AsgEventScaleFactorAlg', self.algoName if self.algoName else 'AsgEventScaleFactorAlg')
876 alg.particles = particles
877 alg.preselection = selection
878 alg.scaleFactorInputDecoration = self.objectSF
879 alg.scaleFactorOutputDecoration = self.eventSF
880
881 config.addOutputVar('EventInfo', alg.scaleFactorOutputDecoration,
882 alg.scaleFactorOutputDecoration.split("_%SYS%")[0])
883
884

The documentation for this class was generated from the following file: