CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
eventstfile.Events Class Reference
Inheritance diagram for eventstfile.Events:

Public Member Functions

def __init__ (self, filename, treename, options=None)
 
def __iter__ (self)
 
def size (self)
 
def to (self, iEv)
 

Public Attributes

 file
 
 tree
 

Detailed Description

Event list from a tree in a root file.

Definition at line 6 of file eventstfile.py.

Constructor & Destructor Documentation

◆ __init__()

def eventstfile.Events.__init__ (   self,
  filename,
  treename,
  options = None 
)

Definition at line 9 of file eventstfile.py.

9  def __init__(self, filename, treename, options=None):
10  self.file = TFile(filename)
11  if self.file.IsZombie():
12  raise ValueError('file {fnam} does not exist'.format(fnam=filename))
13  self.tree = self.file.Get(treename)
14  if self.tree == None: # is None would not work
15  raise ValueError('tree {tree} does not exist in file {fnam}'.format(
16  tree = treename,
17  fnam = filename
18  ))
19 

Member Function Documentation

◆ __iter__()

def eventstfile.Events.__iter__ (   self)

◆ size()

def eventstfile.Events.size (   self)

◆ to()

def eventstfile.Events.to (   self,
  iEv 
)

Member Data Documentation

◆ file

eventstfile.Events.file

◆ tree

eventstfile.Events.tree
to
format
findQualityFiles.size
size
Write out results.
Definition: findQualityFiles.py:443