ATLAS Offline Software
Public Member Functions | Private Member Functions | Private Attributes | List of all members
python.trfGraph.executorNode Class Reference

Initialise a graph node from an executor. More...

Inheritance diagram for python.trfGraph.executorNode:
Collaboration diagram for python.trfGraph.executorNode:

Public Member Functions

def __init__ (self, executor=None, weight=None)
 executorNode constructor More...
 
def name (self)
 
def inData (self)
 
def outData (self)
 
def inputDataTypes (self)
 
def outputDataTypes (self)
 
def connections (self)
 
def weights (self)
 
def addConnection (self, toExe, data, direction='out')
 Add a new edge connection for this node. More...
 
def delConnection (self, toExe, direction='out')
 Delete a connection from this node. More...
 
def resetConnections (self)
 Delete all connections. More...
 
def __str__ (self)
 
def __repr__ (self)
 

Private Member Functions

def _flattenSet (self, startSet)
 Take a list and return all simple members plus the members of any list/tuples in the set (i.e., flatten out multiple input tuples) More...
 

Private Attributes

 _name
 
 _inData
 
 _outData
 
 _inWeights
 
 _inputDataTypes
 
 _outputDataTypes
 
 _connections
 

Detailed Description

Initialise a graph node from an executor.

Definition at line 530 of file trfGraph.py.

Constructor & Destructor Documentation

◆ __init__()

def python.trfGraph.executorNode.__init__ (   self,
  executor = None,
  weight = None 
)

executorNode constructor

Note
This is just a wrapper to call the parent class's constructor with the extracted input and output data types
Parameters
executorExecutor used to make this node
weightWeight specifier

Definition at line 536 of file trfGraph.py.

536  def __init__(self, executor = None, weight = None):
537  super(executorNode, self).__init__(executor.name, executor.inData, executor.outData, weight)

Member Function Documentation

◆ __repr__()

def python.trfGraph.graphNode.__repr__ (   self)
inherited

Definition at line 525 of file trfGraph.py.

525  def __repr__(self):
526  return '{0} (dataIn {1}, weights {2}; dataOut {3}; connect {4})'.format(self._name, self._inData, self._inWeights, self._outData, self._connections)
527 
528 

◆ __str__()

def python.trfGraph.graphNode.__str__ (   self)
inherited

Definition at line 522 of file trfGraph.py.

522  def __str__(self):
523  return '{0} (dataIn {1} -> dataOut {2})'.format(self._name, self._inData, self._outData)
524 

◆ _flattenSet()

def python.trfGraph.graphNode._flattenSet (   self,
  startSet 
)
privateinherited

Take a list and return all simple members plus the members of any list/tuples in the set (i.e., flatten out multiple input tuples)

Definition at line 513 of file trfGraph.py.

513  def _flattenSet(self, startSet):
514  flatData = set()
515  for data in startSet:
516  if isinstance(data, (list, tuple)):
517  flatData.update(data)
518  else:
519  flatData.update([data])
520  return flatData
521 

◆ addConnection()

def python.trfGraph.graphNode.addConnection (   self,
  toExe,
  data,
  direction = 'out' 
)
inherited

Add a new edge connection for this node.

Parameters

Definition at line 498 of file trfGraph.py.

498  def addConnection(self, toExe, data, direction = 'out'):
499  self._connections[direction][toExe] = set(data)
500 

◆ connections()

def python.trfGraph.graphNode.connections (   self)
inherited

Definition at line 487 of file trfGraph.py.

487  def connections(self):
488  return self._connections
489 

◆ delConnection()

def python.trfGraph.graphNode.delConnection (   self,
  toExe,
  direction = 'out' 
)
inherited

Delete a connection from this node.

Parameters

Definition at line 504 of file trfGraph.py.

504  def delConnection(self, toExe, direction = 'out'):
505  del self._connections[direction][toExe]
506 

◆ inData()

def python.trfGraph.graphNode.inData (   self)
inherited

Definition at line 471 of file trfGraph.py.

471  def inData(self):
472  return self._inData
473 

◆ inputDataTypes()

def python.trfGraph.graphNode.inputDataTypes (   self)
inherited

Definition at line 479 of file trfGraph.py.

479  def inputDataTypes(self):
480  return self._flattenSet(self.inData)
481 

◆ name()

def python.trfGraph.graphNode.name (   self)
inherited

Definition at line 467 of file trfGraph.py.

467  def name(self):
468  return self._name
469 

◆ outData()

def python.trfGraph.graphNode.outData (   self)
inherited

Definition at line 475 of file trfGraph.py.

475  def outData(self):
476  return self._outData
477 

◆ outputDataTypes()

def python.trfGraph.graphNode.outputDataTypes (   self)
inherited

Definition at line 483 of file trfGraph.py.

483  def outputDataTypes(self):
484  return self._flattenSet(self._outData)
485 

◆ resetConnections()

def python.trfGraph.graphNode.resetConnections (   self)
inherited

Delete all connections.

Definition at line 508 of file trfGraph.py.

508  def resetConnections(self):
509  self._connections = {'in': {}, 'out': {}}
510 

◆ weights()

def python.trfGraph.graphNode.weights (   self)
inherited

Definition at line 491 of file trfGraph.py.

491  def weights(self):
492  return self._inWeights
493 

Member Data Documentation

◆ _connections

python.trfGraph.graphNode._connections
privateinherited

Definition at line 464 of file trfGraph.py.

◆ _inData

python.trfGraph.graphNode._inData
privateinherited

Definition at line 441 of file trfGraph.py.

◆ _inputDataTypes

python.trfGraph.graphNode._inputDataTypes
privateinherited

Definition at line 457 of file trfGraph.py.

◆ _inWeights

python.trfGraph.graphNode._inWeights
privateinherited
Note
_inWeights takes the form of a dictionary, keyed by input data type and giving the relative cost of executing this node with those input data types.

Definition at line 446 of file trfGraph.py.

◆ _name

python.trfGraph.graphNode._name
privateinherited

Definition at line 440 of file trfGraph.py.

◆ _outData

python.trfGraph.graphNode._outData
privateinherited

Definition at line 442 of file trfGraph.py.

◆ _outputDataTypes

python.trfGraph.graphNode._outputDataTypes
privateinherited

Definition at line 458 of file trfGraph.py.


The documentation for this class was generated from the following file:
vtune_athena.format
format
Definition: vtune_athena.py:14
HLTCFDot.addConnection
def addConnection(nodeA, nodeB, label='')
Definition: HLTCFDot.py:259
CxxUtils::set
constexpr std::enable_if_t< is_bitmask_v< E >, E & > set(E &lhs, E rhs)
Convenience function to set bits in a class enum bitmask.
Definition: bitmask.h:232
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
weights
Definition: herwig7_interface.h:44
python.processes.powheg.ZZ.ZZ.__init__
def __init__(self, base_directory, **kwargs)
Constructor: all process options are set here.
Definition: ZZ.py:18