CMS 3D CMS Logo

List of all members | Public Member Functions
ntupleDataFormat.Seeds Class Reference
Inheritance diagram for ntupleDataFormat.Seeds:
ntupleDataFormat._Collection

Public Member Functions

def __init__ (self, tree)
 
def nSeedsForAlgo (self, algo)
 
def seedForAlgo (self, algo, iseed)
 
def seedsForAlgo (self, algo)
 
- Public Member Functions inherited from ntupleDataFormat._Collection
def __getitem__ (self, index)
 
def __init__ (self, tree, sizeBranch, objclass)
 
def __iter__ (self)
 
def __len__ (self)
 
def size (self)
 

Detailed Description

Class presenting a collection of seeds.

Definition at line 919 of file ntupleDataFormat.py.

Constructor & Destructor Documentation

◆ __init__()

def ntupleDataFormat.Seeds.__init__ (   self,
  tree 
)
Constructor.

Arguments:
tree -- TTree object

Definition at line 921 of file ntupleDataFormat.py.

921  def __init__(self, tree):
922  """Constructor.
923 
924  Arguments:
925  tree -- TTree object
926  """
927  super(Seeds, self).__init__(tree, "see_pt", Seed)
928 
def __init__(self, dataset, job_number, job_id, job_name, isDA, isMC, applyBOWS, applyEXTRACOND, extraconditions, runboundary, lumilist, intlumi, maxevents, gt, allFromGT, alignmentDB, alignmentTAG, apeDB, apeTAG, bowDB, bowTAG, vertextype, tracktype, refittertype, ttrhtype, applyruncontrol, ptcut, CMSSW_dir, the_dir)

Member Function Documentation

◆ nSeedsForAlgo()

def ntupleDataFormat.Seeds.nSeedsForAlgo (   self,
  algo 
)
Returns the number of seeds for a given 'algo'.

Definition at line 929 of file ntupleDataFormat.py.

References ntupleDataFormat._seedOffsetForAlgo(), datamodel.Event._tree, ntupleDataFormat._Collection._tree, python.cmstools.EventTree._tree, output.OutputTree._tree, and output.FullOutput._tree.

929  def nSeedsForAlgo(self, algo):
930  """Returns the number of seeds for a given 'algo'."""
931  (offset, next_offset) = _seedOffsetForAlgo(self._tree, algo)
932  return next_offset - offset
933 
def _seedOffsetForAlgo(tree, algo)

◆ seedForAlgo()

def ntupleDataFormat.Seeds.seedForAlgo (   self,
  algo,
  iseed 
)
Returns Seed of index 'iseed' for 'algo'.

Definition at line 943 of file ntupleDataFormat.py.

References ntupleDataFormat._seedOffsetForAlgo(), datamodel.Event._tree, ntupleDataFormat._Collection._tree, python.cmstools.EventTree._tree, output.OutputTree._tree, and output.FullOutput._tree.

943  def seedForAlgo(self, algo, iseed):
944  """Returns Seed of index 'iseed' for 'algo'."""
945  (offset, next_offset) = _seedOffsetForAlgo(self._tree, algo)
946  if iseed >= (next_offset-offset):
947  raise Exception("Seed index %d is larger than the number of seeds %d for algo %d (%s)" % (iseed, next_offset-offset, algo, Algo.toString(algo)))
948  return Seed(self._tree, offset+iseed)
949 
def _seedOffsetForAlgo(tree, algo)

◆ seedsForAlgo()

def ntupleDataFormat.Seeds.seedsForAlgo (   self,
  algo 
)
Returns generator iterating over the seeds of a given 'algo'.

Generator returns Seed object.

Definition at line 934 of file ntupleDataFormat.py.

References ntupleDataFormat._seedOffsetForAlgo(), datamodel.Event._tree, ntupleDataFormat._Collection._tree, python.cmstools.EventTree._tree, output.OutputTree._tree, output.FullOutput._tree, and FastTimerService_cff.range.

934  def seedsForAlgo(self, algo):
935  """Returns generator iterating over the seeds of a given 'algo'.
936 
937  Generator returns Seed object.
938  """
939  (offset, next_offset) = _seedOffsetForAlgo(self._tree, algo)
940  for isee in range(offset, next_offset):
941  yield Seed(self._tree, isee)
942 
def _seedOffsetForAlgo(tree, algo)