ATLAS Offline Software
Loading...
Searching...
No Matches
BPhysPyHelpers Namespace Reference

Classes

class  BPyWrapper

Functions

 BPhysEnsureAttributes (algtool)
 BPhysFilterBranches (name, brPrefixList, brIncludeList, doVertexTypeList, categoryList, trackTypeList, coneOrChi2SetList, forCloseTrack=False)

Function Documentation

◆ BPhysEnsureAttributes()

BPhysPyHelpers.BPhysEnsureAttributes ( algtool)

Definition at line 52 of file BPhysPyHelpers.py.

52def BPhysEnsureAttributes(algtool):
53
54 for n,v in algtool.__slots__.items():
55 if not hasattr(algtool, n):
56 setattr(algtool, n, v)
57 return algtool
58#--------------------------------------------------------------------
59#
60# create list of isolation or closest track branches to be thinned
61# (used by BPHY8)
62#

◆ BPhysFilterBranches()

BPhysPyHelpers.BPhysFilterBranches ( name,
brPrefixList,
brIncludeList,
doVertexTypeList,
categoryList,
trackTypeList,
coneOrChi2SetList,
forCloseTrack = False )

Definition at line 63 of file BPhysPyHelpers.py.

65 forCloseTrack=False):
66 res = ""
67 brIncludes = [tuple(x.split('|',3)) for x in brIncludeList]
68 for bntup in brPrefixList:
69 bn, sep, bnsuf = bntup.partition('+')
70 for i, cstr in enumerate(coneOrChi2SetList):
71 for itt in trackTypeList:
72 ittstr = "T%010d" % itt
73 for itcstr in categoryList:
74 if brIncludes and not (cstr,str(itt),itcstr) in brIncludes:
75 for dvs in doVertexTypeList:
76 if forCloseTrack:
77 fbn = '_'.join(filter(None, [name,bn,ittstr,itcstr,
78 dvs,cstr,bnsuf]))
79 else:
80 fbn = '_'.join(filter(None, [name,bn,cstr,ittstr,
81 itcstr,dvs,bnsuf]))
82 res += ".-"+fbn
83 return res
84#--------------------------------------------------------------------