ATLAS Offline Software
Public Member Functions | Public Attributes | List of all members
MenuComponents.InputMakerNode Class Reference
Inheritance diagram for MenuComponents.InputMakerNode:
Collaboration diagram for MenuComponents.InputMakerNode:

Public Member Functions

def __init__ (self, Alg)
 
def setPar (self, propname, value)
 
def addOutput (self, name)
 
def readOutputList (self)
 
def addInput (self, name)
 
def readInputList (self)
 
def __repr__ (self)
 
def getOutputList (self)
 
def getInputList (self)
 

Public Attributes

 outputProp
 
 inputProp
 
 name
 
 Alg
 
 inputs
 
 outputs
 

Detailed Description

AlgNode for InputMaker Algs

Definition at line 171 of file MenuComponents.py.

Constructor & Destructor Documentation

◆ __init__()

def MenuComponents.InputMakerNode.__init__ (   self,
  Alg 
)

Reimplemented from MenuComponents.Node.

Definition at line 173 of file MenuComponents.py.

173  def __init__(self, Alg):
174  assert isInputMakerBase(Alg), "Error in creating InputMakerNode from Alg " + Alg.name
175  AlgNode.__init__(self, Alg, 'InputMakerInputDecisions', 'InputMakerOutputDecisions')
176  input_maker_output = CFNaming.inputMakerOutName(self.Alg.name)
177  self.addOutput(input_maker_output)
178 
179 

Member Function Documentation

◆ __repr__()

def MenuComponents.AlgNode.__repr__ (   self)
inherited

Reimplemented from MenuComponents.Node.

Reimplemented in MenuComponents.HypoAlgNode.

Definition at line 100 of file MenuComponents.py.

100  def __repr__(self):
101  return "Alg::%s [%s] -> [%s]"%(self.Alg.getName(), ' '.join(map(str, self.getInputList())), ' '.join(map(str, self.getOutputList())))
102 
103 

◆ addInput()

def MenuComponents.AlgNode.addInput (   self,
  name 
)
inherited

Reimplemented from MenuComponents.Node.

Definition at line 83 of file MenuComponents.py.

83  def addInput(self, name):
84  inputs = self.readInputList()
85  if name in inputs:
86  log.debug("Input DH not added in %s: %s already set!", self.Alg.getName(), name)
87  else:
88  if self.inputProp != '':
89  self.setPar(self.inputProp, name)
90  else:
91  log.debug("no InputProp set for input of %s", self.Alg.getName())
92  Node.addInput(self, name)
93  return len(self.readInputList())
94 

◆ addOutput()

def MenuComponents.AlgNode.addOutput (   self,
  name 
)
inherited

Reimplemented from MenuComponents.Node.

Reimplemented in MenuComponents.HypoAlgNode.

Definition at line 67 of file MenuComponents.py.

67  def addOutput(self, name):
68  outputs = self.readOutputList()
69  if name in outputs:
70  log.debug("Output DH not added in %s: %s already set!", self.Alg.getName(), name)
71  else:
72  if self.outputProp != '':
73  self.setPar(self.outputProp, name)
74  else:
75  log.debug("no outputProp set for output of %s", self.Alg.getName())
76  Node.addOutput(self, name)
77 

◆ getInputList()

def MenuComponents.Node.getInputList (   self)
inherited

Definition at line 44 of file MenuComponents.py.

44  def getInputList(self):
45  return self.inputs
46 

◆ getOutputList()

def MenuComponents.Node.getOutputList (   self)
inherited

Definition at line 41 of file MenuComponents.py.

41  def getOutputList(self):
42  return self.outputs
43 

◆ readInputList()

def MenuComponents.AlgNode.readInputList (   self)
inherited

Definition at line 95 of file MenuComponents.py.

95  def readInputList(self):
96  cval = getattr(self.Alg, self.inputProp)
97  return (cval if isinstance(cval, MutableSequence) else
98  ([str(cval)] if cval else []))
99 

◆ readOutputList()

def MenuComponents.AlgNode.readOutputList (   self)
inherited

Definition at line 78 of file MenuComponents.py.

78  def readOutputList(self):
79  cval = getattr(self.Alg, self.outputProp)
80  return (cval if isinstance(cval, MutableSequence) else
81  ([str(cval)] if cval else []))
82 

◆ setPar()

def MenuComponents.AlgNode.setPar (   self,
  propname,
  value 
)
inherited

Definition at line 59 of file MenuComponents.py.

59  def setPar(self, propname, value):
60  cval = getattr( self.Alg, propname)
61  if isinstance(cval, MutableSequence):
62  cval.append(value)
63  return setattr(self.Alg, propname, cval)
64  else:
65  return setattr(self.Alg, propname, value)
66 

Member Data Documentation

◆ Alg

MenuComponents.Node.Alg
inherited

Definition at line 31 of file MenuComponents.py.

◆ inputProp

MenuComponents.AlgNode.inputProp
inherited

Definition at line 57 of file MenuComponents.py.

◆ inputs

MenuComponents.Node.inputs
inherited

Definition at line 32 of file MenuComponents.py.

◆ name

MenuComponents.Node.name
inherited

Definition at line 30 of file MenuComponents.py.

◆ outputProp

MenuComponents.AlgNode.outputProp
inherited

Definition at line 56 of file MenuComponents.py.

◆ outputs

MenuComponents.Node.outputs
inherited

Definition at line 33 of file MenuComponents.py.


The documentation for this class was generated from the following file:
detail::addInput
void addInput(T &c, const Primitive &input, A a=defaultAccessor< T >)
Definition: PrimitiveHelpers.h:50
dumpTruth.getName
getName
Definition: dumpTruth.py:34
HLTCFTools.isInputMakerBase
def isInputMakerBase(alg)
Definition: HLTCFTools.py:40
TCS::join
std::string join(const std::vector< std::string > &v, const char c=',')
Definition: Trigger/TrigT1/L1Topo/L1TopoCommon/Root/StringUtils.cxx:10
python.processes.powheg.ZZ.ZZ.__init__
def __init__(self, base_directory, **kwargs)
Constructor: all process options are set here.
Definition: ZZ.py:18
str
Definition: BTagTrackIpAccessor.cxx:11