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

Public Member Functions

 __init__ (self, name, objtype, algoBuilder=None, specs=None, containername=None, filterfn=_condAlwaysPass, prereqs=None)
 name (self)
 algoBuilder (self)
 basetype (self)
 specs (self)
 filterfn (self)
 prereqs (self)
 __str__ (self)
 __hash__ (self)
 __eq__ (self, other)
 __ne__ (self, rhs)

Public Attributes

 name = name
 basetype = objtype
 algoBuilder = algoBuilder if algoBuilder is not None else buildNothing
 containername = containername
 specs = specs
 filterfn = filterfn
 prereqs = prereqs if prereqs is not None else []

Static Public Attributes

 outputname = make_alias("name")

Static Private Attributes

 __repr__ = __str__

Detailed Description

This class allows to declare primary data sources to jet finding which are typically outside of jet domain.
Such sources can be container of particles (ex: clusters, selection of tracks,...) but also
other object needed by some JetModifier (ex: EventDensity or track-vertex association map).

The class is mainly here to hold a helper function (algoBuilder) in charge of configuring the proper algorithm to build the source. 
If this function is None, then we expect the container pre-exists in the evt store. 

Arguments to the constructor :
  - name : container name in event store 
  - objtype  : the xAODType (ex: xAODType.TruthParticle, xAODType.CaloCluster, ...)
  - algoBuilder [optional] : a function returning a configured algorithm which build the container
                             the function is called as algoBuilder(parentjetdef, specs) where 
                                 parentjetdef is the JetDefinition for which this input building is called.
                                 specs is self.specs
                             If omitted, it is assumed the container pre-exists in the event store.
 - specs [optional] : a string (or anything) which specifies some options, and passed to the algoBuilder function
 - filterfn : a function taking a CondFlags as argument and deciding if this JetModifier is compatible
              with the conditions (same as JetModifier.filterfn )
              The function must return a tuple : (bool, "reason of failure")
 - prereqs : a list of prerequisites (str) for this input definition. If any, these str must match the name of other existing JetInputExternal instances. 

Definition at line 356 of file JetDefinition.py.

Constructor & Destructor Documentation

◆ __init__()

python.JetDefinition.JetInputExternal.__init__ ( self,
name,
objtype,
algoBuilder = None,
specs = None,
containername = None,
filterfn = _condAlwaysPass,
prereqs = None )

Definition at line 378 of file JetDefinition.py.

378 def __init__(self, name, objtype, algoBuilder=None, specs=None, containername=None, filterfn= _condAlwaysPass, prereqs=None):
379 self.name = name
380 self.basetype = objtype
381
382 self.algoBuilder = algoBuilder if algoBuilder is not None else buildNothing # buildNothing returns None (see below)
383
384 # In certain cases (EventShape) we need to configure the concrete
385 # output container name based on the jetdef and specs, so can
386 # pass in a (lambda) function to define this.
387 if containername:
388 self.containername = containername
389 else:
390 # Ordinarily we just return the name
391 self.containername = lambda dummyjetdef,dummyspecs : self.name
392
393 self.specs = specs
394 self.filterfn = filterfn
395 self.prereqs = prereqs if prereqs is not None else []
396

Member Function Documentation

◆ __eq__()

python.JetDefinition.JetInputExternal.__eq__ ( self,
other )

Definition at line 426 of file JetDefinition.py.

426 def __eq__(self,other):
427 return hash(self) == hash(other)
428

◆ __hash__()

python.JetDefinition.JetInputExternal.__hash__ ( self)

Definition at line 417 of file JetDefinition.py.

417 def __hash__(self):
418 return hash((
419 self.name,str(self.basetype),str(self.algoBuilder),
420 self.containername(None,None),str(self.prereqs),
421 str(self.filterfn),str(self.specs)))
422

◆ __ne__()

python.JetDefinition.JetInputExternal.__ne__ ( self,
rhs )

Definition at line 429 of file JetDefinition.py.

429 def __ne__(self,rhs):
430 return (not self.__eq__(rhs))
431
432

◆ __str__()

python.JetDefinition.JetInputExternal.__str__ ( self)

Definition at line 414 of file JetDefinition.py.

414 def __str__(self):
415 return f"JetInputExternal({self.name},type={str(self.basetype)})"
416

◆ algoBuilder()

python.JetDefinition.JetInputExternal.algoBuilder ( self)

Definition at line 400 of file JetDefinition.py.

400 def algoBuilder(self): pass

◆ basetype()

python.JetDefinition.JetInputExternal.basetype ( self)

Definition at line 402 of file JetDefinition.py.

402 def basetype(self): pass

◆ filterfn()

python.JetDefinition.JetInputExternal.filterfn ( self)

Definition at line 406 of file JetDefinition.py.

406 def filterfn(self):pass

◆ name()

python.JetDefinition.JetInputExternal.name ( self)

Definition at line 398 of file JetDefinition.py.

398 def name(self): pass

◆ prereqs()

python.JetDefinition.JetInputExternal.prereqs ( self)

Definition at line 408 of file JetDefinition.py.

408 def prereqs(self):pass
409

◆ specs()

python.JetDefinition.JetInputExternal.specs ( self)

Definition at line 404 of file JetDefinition.py.

404 def specs(self): pass

Member Data Documentation

◆ __repr__

python.JetDefinition.JetInputExternal.__repr__ = __str__
staticprivate

Definition at line 424 of file JetDefinition.py.

◆ algoBuilder

python.JetDefinition.JetInputExternal.algoBuilder = algoBuilder if algoBuilder is not None else buildNothing

Definition at line 382 of file JetDefinition.py.

◆ basetype

python.JetDefinition.JetInputExternal.basetype = objtype

Definition at line 380 of file JetDefinition.py.

◆ containername

python.JetDefinition.JetInputExternal.containername = containername

Definition at line 388 of file JetDefinition.py.

◆ filterfn

python.JetDefinition.JetInputExternal.filterfn = filterfn

Definition at line 394 of file JetDefinition.py.

◆ name

python.JetDefinition.JetInputExternal.name = name

Definition at line 379 of file JetDefinition.py.

◆ outputname

python.JetDefinition.JetInputExternal.outputname = make_alias("name")
static

Definition at line 411 of file JetDefinition.py.

◆ prereqs

python.JetDefinition.JetInputExternal.prereqs = prereqs if prereqs is not None else []

Definition at line 395 of file JetDefinition.py.

◆ specs

python.JetDefinition.JetInputExternal.specs = specs

Definition at line 393 of file JetDefinition.py.


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