Public Member Functions | |
def | __init__ (self, fileName, tree="trackingNtuple/tree") |
def | __iter__ (self) |
def | file (self) |
def | getEvent (self, index) |
def | hasHits (self) |
def | hasSeeds (self) |
def | nevents (self) |
def | tree (self) |
Private Attributes | |
_entries | |
_file | |
_tree | |
Class abstracting the whole ntuple/TTree. Main benefit is to provide nice interface for - iterating over events - querying whether hit/seed information exists Note that to iteratate over the evets with zip(), you should use itertools.izip() instead.
Definition at line 381 of file ntupleDataFormat.py.
def ntupleDataFormat.TrackingNtuple.__init__ | ( | self, | |
fileName, | |||
tree = "trackingNtuple/tree" |
|||
) |
Constructor. Arguments: fileName -- String for path to the ROOT file tree -- Name of the TTree object inside the ROOT file (default: 'trackingNtuple/tree')
Definition at line 391 of file ntupleDataFormat.py.
def ntupleDataFormat.TrackingNtuple.__iter__ | ( | self | ) |
Returns generator for iterating over TTree entries (events) Generator returns Event objects.
Definition at line 420 of file ntupleDataFormat.py.
References ntupleDataFormat.TrackingNtuple._entries, datamodel.Event._tree, ntupleDataFormat._Collection._tree, ntupleDataFormat._Object._tree, python.cmstools.EventTree._tree, output.OutputTree._tree, output.FullOutput._tree, ntupleDataFormat.TrackingNtuple._tree, and FastTimerService_cff.range.
def ntupleDataFormat.TrackingNtuple.file | ( | self | ) |
Definition at line 403 of file ntupleDataFormat.py.
References ClassesDefXmlUtils.XmlParser._file, CommonAnalyzer._file, condhdf5tohdf5.H5Tag._file, output.OutputTree._file, condhdf5tohdf5.H5GlobalTag._file, dqm-mbProfile.Profile._file, and ntupleDataFormat.TrackingNtuple._file.
def ntupleDataFormat.TrackingNtuple.getEvent | ( | self, | |
index | |||
) |
Returns Event for a given index
Definition at line 436 of file ntupleDataFormat.py.
References datamodel.Event._tree, ntupleDataFormat._Collection._tree, ntupleDataFormat._Object._tree, python.cmstools.EventTree._tree, output.OutputTree._tree, output.FullOutput._tree, and ntupleDataFormat.TrackingNtuple._tree.
def ntupleDataFormat.TrackingNtuple.hasHits | ( | self | ) |
Returns true if the ntuple has hit information.
Definition at line 412 of file ntupleDataFormat.py.
References datamodel.Event._tree, ntupleDataFormat._Collection._tree, ntupleDataFormat._Object._tree, python.cmstools.EventTree._tree, output.OutputTree._tree, output.FullOutput._tree, and ntupleDataFormat.TrackingNtuple._tree.
def ntupleDataFormat.TrackingNtuple.hasSeeds | ( | self | ) |
Returns true if the ntuple has seed information.
Definition at line 416 of file ntupleDataFormat.py.
References datamodel.Event._tree, ntupleDataFormat._Collection._tree, ntupleDataFormat._Object._tree, python.cmstools.EventTree._tree, output.OutputTree._tree, output.FullOutput._tree, and ntupleDataFormat.TrackingNtuple._tree.
def ntupleDataFormat.TrackingNtuple.nevents | ( | self | ) |
Definition at line 409 of file ntupleDataFormat.py.
References ntupleDataFormat.TrackingNtuple._entries.
def ntupleDataFormat.TrackingNtuple.tree | ( | self | ) |
Definition at line 406 of file ntupleDataFormat.py.
References datamodel.Event._tree, ntupleDataFormat._Collection._tree, ntupleDataFormat._Object._tree, python.cmstools.EventTree._tree, output.OutputTree._tree, output.FullOutput._tree, and ntupleDataFormat.TrackingNtuple._tree.
Referenced by ZJetsTreeAnalyzer.ZJetsTreeAnalyzer.beginLoop(), MetTreeProducer.MetTreeProducer.declareVariables(), core.AutoFillTreeProducer.AutoFillTreeProducer.declareVariables(), core.AutoFillTreeProducer.AutoFillTreeProducer.fillTree(), ZJetsTreeAnalyzer.ZJetsTreeAnalyzer.process(), and MetTreeProducer.MetTreeProducer.process().
|
private |
Definition at line 401 of file ntupleDataFormat.py.
Referenced by ntupleDataFormat.TrackingNtuple.__iter__(), and ntupleDataFormat.TrackingNtuple.nevents().
|
private |
Definition at line 399 of file ntupleDataFormat.py.
Referenced by ntupleDataFormat.TrackingNtuple.file().
|
private |
Definition at line 400 of file ntupleDataFormat.py.
Referenced by ntupleDataFormat.BeamSpot.__getattr__(), ntupleDataFormat.TrackingNtuple.__iter__(), ntupleDataFormat._SimHitMatchAdaptor._nMatchedSimHits(), ntupleDataFormat._TrackingParticleMatchAdaptor._nMatchedTrackingParticles(), ntupleDataFormat.Event.beamspot(), ntupleDataFormat._TrackingParticleMatchAdaptor.bestMatchingTrackingParticle(), ntupleDataFormat._TrackingParticleMatchAdaptor.bestMatchingTrackingParticleFromFirstHit(), ntupleDataFormat._DetIdStrAdaptor.detIdStr(), ntupleDataFormat.Event.event(), ntupleDataFormat.Event.eventId(), ntupleDataFormat.TrackingNtuple.getEvent(), ntupleDataFormat._RecoHitAdaptor.gluedHits(), ntupleDataFormat.Event.gluedHits(), ntupleDataFormat.TrackingNtuple.hasHits(), ntupleDataFormat.TrackingNtuple.hasSeeds(), ntupleDataFormat._RecoHitAdaptor.hits(), ntupleDataFormat._RecoHitAdaptor.invalidHits(), ntupleDataFormat._DetIdStrAdaptor.layerStr(), ntupleDataFormat.Event.lumi(), ntupleDataFormat._SimHitMatchAdaptor.matchedSimHitInfos(), ntupleDataFormat._TrackingParticleMatchAdaptor.matchedTrackingParticleInfos(), ntupleDataFormat._RecoHitAdaptor.phase2OTHits(), ntupleDataFormat.Event.phase2OTHits(), ntupleDataFormat._RecoHitAdaptor.pixelHits(), ntupleDataFormat.Event.pixelHits(), ntupleDataFormat.Event.run(), ntupleDataFormat.Event.seeds(), ntupleDataFormat._RecoHitAdaptor.stripHits(), ntupleDataFormat.Event.stripHits(), ntupleDataFormat.Event.trackingParticles(), ntupleDataFormat.Event.trackingVertices(), ntupleDataFormat.Event.tracks(), ntupleDataFormat.TrackingNtuple.tree(), and ntupleDataFormat.Event.vertices().