In [2]:
# Import ROOT
import ROOT as r
In [3]:
# Open our reconstructed file and get the tree
f = r.TFile('ship.10.0.Pythia8-TGeant4_rec.root', 'read')
f.ls()
t = f.Get('cbmsim')
t.Print()
tb = r.TBrowser()
In [41]:
# Look at MCTracks. These are the basic objects representing the simulated particles, transported through the media with Geant4.
t.GetEntry(1)
mcTracks = t.MCTrack
mcTracks[0]
help(mcTracks[0])
dir(mcTracks[0])
Help on ShipMCTrack in module __main__ object:

class ShipMCTrack(ROOT.TObject)
 |  Method resolution order:
 |      ShipMCTrack
 |      ROOT.TObject
 |      ROOT.ObjectProxy
 |      __builtin__.object
 |  
 |  Methods defined here:
 |  
 |  Class(self)
 |      static TClass* ShipMCTrack::Class()
 |  
 |  Class_Name(self)
 |      static const char* ShipMCTrack::Class_Name()
 |  
 |  Class_Version(self)
 |      static Version_t ShipMCTrack::Class_Version()
 |  
 |  DeclFileLine(self)
 |      static int ShipMCTrack::DeclFileLine()
 |  
 |  DeclFileName(self)
 |      static const char* ShipMCTrack::DeclFileName()
 |  
 |  Dictionary(self)
 |      static void ShipMCTrack::Dictionary()
 |  
 |  Get4Momentum(self, TLorentzVector& momentum)
 |      void ShipMCTrack::Get4Momentum(TLorentzVector& momentum)
 |  
 |  GetEnergy(self)
 |      Double_t ShipMCTrack::GetEnergy()
 |  
 |  GetMass(self)
 |      Double_t ShipMCTrack::GetMass()
 |  
 |  GetMomentum(self, TVector3& momentum)
 |      void ShipMCTrack::GetMomentum(TVector3& momentum)
 |  
 |  GetMotherId(self)
 |      Int_t ShipMCTrack::GetMotherId()
 |  
 |  GetNPoints(self, DetectorId detId)
 |      Int_t ShipMCTrack::GetNPoints(DetectorId detId)
 |  
 |  GetP(self)
 |      Double_t ShipMCTrack::GetP()
 |  
 |  GetPdgCode(self)
 |      Int_t ShipMCTrack::GetPdgCode()
 |  
 |  GetPt(self)
 |      Double_t ShipMCTrack::GetPt()
 |  
 |  GetPx(self)
 |      Double_t ShipMCTrack::GetPx()
 |  
 |  GetPy(self)
 |      Double_t ShipMCTrack::GetPy()
 |  
 |  GetPz(self)
 |      Double_t ShipMCTrack::GetPz()
 |  
 |  GetRapidity(self)
 |      Double_t ShipMCTrack::GetRapidity()
 |  
 |  GetStartT(self)
 |      Double_t ShipMCTrack::GetStartT()
 |  
 |  GetStartVertex(self, TVector3& vertex)
 |      void ShipMCTrack::GetStartVertex(TVector3& vertex)
 |  
 |  GetStartX(self)
 |      Double_t ShipMCTrack::GetStartX()
 |  
 |  GetStartY(self)
 |      Double_t ShipMCTrack::GetStartY()
 |  
 |  GetStartZ(self)
 |      Double_t ShipMCTrack::GetStartZ()
 |  
 |  GetWeight(self)
 |      Double_t ShipMCTrack::GetWeight()
 |  
 |  ImplFileLine(self)
 |      static int ShipMCTrack::ImplFileLine()
 |  
 |  ImplFileName(self)
 |      static const char* ShipMCTrack::ImplFileName()
 |  
 |  IsA(self)
 |      TClass* ShipMCTrack::IsA()
 |  
 |  Print(self, Int_t iTrack=0)
 |      void ShipMCTrack::Print(Int_t iTrack = 0)
 |  
 |  SetMotherId(self, Int_t id)
 |      void ShipMCTrack::SetMotherId(Int_t id)
 |  
 |  SetNPoints(self, Int_t iDet, Int_t np)
 |      void ShipMCTrack::SetNPoints(Int_t iDet, Int_t np)
 |  
 |  ShowMembers(self, TMemberInspector&)
 |      void ShipMCTrack::ShowMembers(TMemberInspector&)
 |  
 |  Streamer(self, TBuffer&)
 |      void ShipMCTrack::Streamer(TBuffer&)
 |  
 |  StreamerNVirtual(self, TBuffer& ClassDef_StreamerNVirtual_b)
 |      void ShipMCTrack::StreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
 |  
 |  __assign__(self, const ShipMCTrack&)
 |      ShipMCTrack& ShipMCTrack::operator=(const ShipMCTrack&)
 |  
 |  __init__(self, Int_t pdgCode, Int_t motherID, Double_t px, Double_t py, Double_t pz, Double_t x, Double_t y, Double_t z, Double_t t, Int_t nPoints, Double_t w)
 |      ShipMCTrack::ShipMCTrack()
 |      ShipMCTrack::ShipMCTrack(Int_t pdgCode, Int_t motherID, Double_t px, Double_t py, Double_t pz, Double_t x, Double_t y, Double_t z, Double_t t, Int_t nPoints, Double_t w)
 |      ShipMCTrack::ShipMCTrack(const ShipMCTrack& track)
 |      ShipMCTrack::ShipMCTrack(TParticle* particle)
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.TObject:
 |  
 |  AbstractMethod(self, const char* method) from ROOT.TObject
 |      void TObject::AbstractMethod(const char* method)
 |  
 |  AppendPad(self, Option_t* option='') from ROOT.TObject
 |      void TObject::AppendPad(Option_t* option = "")
 |  
 |  Browse(self, TBrowser* b) from ROOT.TObject
 |      void TObject::Browse(TBrowser* b)
 |  
 |  ClassName(self) from ROOT.TObject
 |      const char* TObject::ClassName()
 |  
 |  Clear(self, Option_t*='') from ROOT.TObject
 |      void TObject::Clear(Option_t* = "")
 |  
 |  Clone(self, const char* newname='') from ROOT.TObject
 |      TObject* TObject::Clone(const char* newname = "")
 |  
 |  Compare(self, const TObject* obj) from ROOT.TObject
 |      Int_t TObject::Compare(const TObject* obj)
 |  
 |  Copy(self, TObject& object) from ROOT.TObject
 |      void TObject::Copy(TObject& object)
 |  
 |  Delete(self, Option_t* option='') from ROOT.TObject
 |      void TObject::Delete(Option_t* option = "")
 |  
 |  DistancetoPrimitive(self, Int_t px, Int_t py) from ROOT.TObject
 |      Int_t TObject::DistancetoPrimitive(Int_t px, Int_t py)
 |  
 |  Draw(self, Option_t* option='') from ROOT.TObject
 |      void TObject::Draw(Option_t* option = "")
 |  
 |  DrawClass(self) from ROOT.TObject
 |      void TObject::DrawClass()
 |  
 |  DrawClone(self, Option_t* option='') from ROOT.TObject
 |      TObject* TObject::DrawClone(Option_t* option = "")
 |  
 |  Dump(self) from ROOT.TObject
 |      void TObject::Dump()
 |  
 |  Error(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Error(const char* method, const char* msgfmt)
 |  
 |  Execute(self, const char* method, const char* params, Int_t* error=0) from ROOT.TObject
 |      void TObject::Execute(const char* method, const char* params, Int_t* error = 0)
 |      void TObject::Execute(TMethod* method, TObjArray* params, Int_t* error = 0)
 |  
 |  ExecuteEvent(self, Int_t event, Int_t px, Int_t py) from ROOT.TObject
 |      void TObject::ExecuteEvent(Int_t event, Int_t px, Int_t py)
 |  
 |  Fatal(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Fatal(const char* method, const char* msgfmt)
 |  
 |  FindObject(self, const char* name) from ROOT.TObject
 |      TObject* TObject::FindObject(const char* name)
 |      TObject* TObject::FindObject(const TObject* obj)
 |  
 |  GetDrawOption(self) from ROOT.TObject
 |      Option_t* TObject::GetDrawOption()
 |  
 |  GetDtorOnly(self) from ROOT.TObject
 |      static Long_t TObject::GetDtorOnly()
 |  
 |  GetIconName(self) from ROOT.TObject
 |      const char* TObject::GetIconName()
 |  
 |  GetName(self) from ROOT.TObject
 |      const char* TObject::GetName()
 |  
 |  GetObjectInfo(self, Int_t px, Int_t py) from ROOT.TObject
 |      char* TObject::GetObjectInfo(Int_t px, Int_t py)
 |  
 |  GetObjectStat(self) from ROOT.TObject
 |      static Bool_t TObject::GetObjectStat()
 |  
 |  GetOption(self) from ROOT.TObject
 |      Option_t* TObject::GetOption()
 |  
 |  GetTitle(self) from ROOT.TObject
 |      const char* TObject::GetTitle()
 |  
 |  GetUniqueID(self) from ROOT.TObject
 |      UInt_t TObject::GetUniqueID()
 |  
 |  HandleTimer(self, TTimer* timer) from ROOT.TObject
 |      Bool_t TObject::HandleTimer(TTimer* timer)
 |  
 |  Hash(self) from ROOT.TObject
 |      ULong_t TObject::Hash()
 |  
 |  Info(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Info(const char* method, const char* msgfmt)
 |  
 |  InheritsFrom(self, const char* classname) from ROOT.TObject
 |      Bool_t TObject::InheritsFrom(const char* classname)
 |      Bool_t TObject::InheritsFrom(const TClass* cl)
 |  
 |  Inspect(self) from ROOT.TObject
 |      void TObject::Inspect()
 |  
 |  InvertBit(self, UInt_t f) from ROOT.TObject
 |      void TObject::InvertBit(UInt_t f)
 |  
 |  IsEqual(self, const TObject* obj) from ROOT.TObject
 |      Bool_t TObject::IsEqual(const TObject* obj)
 |  
 |  IsFolder(self) from ROOT.TObject
 |      Bool_t TObject::IsFolder()
 |  
 |  IsOnHeap(self) from ROOT.TObject
 |      Bool_t TObject::IsOnHeap()
 |  
 |  IsSortable(self) from ROOT.TObject
 |      Bool_t TObject::IsSortable()
 |  
 |  IsZombie(self) from ROOT.TObject
 |      Bool_t TObject::IsZombie()
 |  
 |  MayNotUse(self, const char* method) from ROOT.TObject
 |      void TObject::MayNotUse(const char* method)
 |  
 |  Notify(self) from ROOT.TObject
 |      Bool_t TObject::Notify()
 |  
 |  Obsolete(self, const char* method, const char* asOfVers, const char* removedFromVers) from ROOT.TObject
 |      void TObject::Obsolete(const char* method, const char* asOfVers, const char* removedFromVers)
 |  
 |  Paint(self, Option_t* option='') from ROOT.TObject
 |      void TObject::Paint(Option_t* option = "")
 |  
 |  Pop(self) from ROOT.TObject
 |      void TObject::Pop()
 |  
 |  Read(self, const char* name) from ROOT.TObject
 |      Int_t TObject::Read(const char* name)
 |  
 |  RecursiveRemove(self, TObject* obj) from ROOT.TObject
 |      void TObject::RecursiveRemove(TObject* obj)
 |  
 |  ResetBit(self, UInt_t f) from ROOT.TObject
 |      void TObject::ResetBit(UInt_t f)
 |  
 |  SaveAs(self, const char* filename='', Option_t* option='') from ROOT.TObject
 |      void TObject::SaveAs(const char* filename = "", Option_t* option = "")
 |  
 |  SavePrimitive(self, basic_ostream<char,char_traits<char> >& out, Option_t* option='') from ROOT.TObject
 |      void TObject::SavePrimitive(basic_ostream<char,char_traits<char> >& out, Option_t* option = "")
 |  
 |  SetBit(self, UInt_t f, Bool_t set) from ROOT.TObject
 |      void TObject::SetBit(UInt_t f, Bool_t set)
 |      void TObject::SetBit(UInt_t f)
 |  
 |  SetDrawOption(self, Option_t* option='') from ROOT.TObject
 |      void TObject::SetDrawOption(Option_t* option = "")
 |  
 |  SetDtorOnly(self, void* obj) from ROOT.TObject
 |      static void TObject::SetDtorOnly(void* obj)
 |  
 |  SetObjectStat(self, Bool_t stat) from ROOT.TObject
 |      static void TObject::SetObjectStat(Bool_t stat)
 |  
 |  SetUniqueID(self, UInt_t uid) from ROOT.TObject
 |      void TObject::SetUniqueID(UInt_t uid)
 |  
 |  SysError(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::SysError(const char* method, const char* msgfmt)
 |  
 |  TestBit(self, UInt_t f) from ROOT.TObject
 |      Bool_t TObject::TestBit(UInt_t f)
 |  
 |  TestBits(self, UInt_t f) from ROOT.TObject
 |      Int_t TObject::TestBits(UInt_t f)
 |  
 |  UseCurrentStyle(self) from ROOT.TObject
 |      void TObject::UseCurrentStyle()
 |  
 |  Warning(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Warning(const char* method, const char* msgfmt)
 |  
 |  Write(self, const char* name=0, Int_t option=0, Int_t bufsize=0) from ROOT.TObject
 |      Int_t TObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
 |      Int_t TObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
 |  
 |  __cmp__(...)
 |  
 |  __contains__(...)
 |  
 |  __eq__(...)
 |  
 |  __ne__(...)
 |  
 |  ls(self, Option_t* option='') from ROOT.TObject
 |      void TObject::ls(Option_t* option = "")
 |  
 |  operator delete(self, void* ptr, void* vp) from ROOT.TObject
 |      static void TObject::operator delete(void* ptr)
 |      static void TObject::operator delete(void* ptr, void* vp)
 |  
 |  operator delete[](self, void* ptr, void* vp) from ROOT.TObject
 |      static void TObject::operator delete[](void* ptr)
 |      static void TObject::operator delete[](void* ptr, void* vp)
 |  
 |  operator new(self, size_t sz, void* vp) from ROOT.TObject
 |      void* TObject::operator new(size_t sz)
 |      void* TObject::operator new(size_t sz, void* vp)
 |  
 |  operator new[](self, size_t sz, void* vp) from ROOT.TObject
 |      void* TObject::operator new[](size_t sz)
 |      void* TObject::operator new[](size_t sz, void* vp)
 |  
 |  ----------------------------------------------------------------------
 |  Data descriptors inherited from ROOT.TObject:
 |  
 |  __dict__
 |      dictionary for instance variables (if defined)
 |  
 |  __weakref__
 |      list of weak references to the object (if defined)
 |  
 |  ----------------------------------------------------------------------
 |  Data and other attributes inherited from ROOT.TObject:
 |  
 |  kBitMask = 16777215
 |  
 |  kCanDelete = 1
 |  
 |  kCannotPick = 64
 |  
 |  kHasUUID = 32
 |  
 |  kInvalidObject = 8192
 |  
 |  kIsOnHeap = 16777216
 |  
 |  kIsReferenced = 16
 |  
 |  kMustCleanup = 8
 |  
 |  kNoContextMenu = 256
 |  
 |  kNotDeleted = 33554432
 |  
 |  kObjInCanvas = 8
 |  
 |  kOverwrite = 2
 |  
 |  kSingleKey = 1
 |  
 |  kWriteDelete = 4
 |  
 |  kZombie = 67108864
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.ObjectProxy:
 |  
 |  __add__(...)
 |      x.__add__(y) <==> x+y
 |  
 |  __bool__(...)
 |  
 |  __div__(...)
 |      x.__div__(y) <==> x/y
 |  
 |  __ge__(...)
 |      x.__ge__(y) <==> x>=y
 |  
 |  __gt__(...)
 |      x.__gt__(y) <==> x>y
 |  
 |  __le__(...)
 |      x.__le__(y) <==> x<=y
 |  
 |  __lt__(...)
 |      x.__lt__(y) <==> x<y
 |  
 |  __mul__(...)
 |      x.__mul__(y) <==> x*y
 |  
 |  __nonzero__(...)
 |  
 |  __radd__(...)
 |      x.__radd__(y) <==> y+x
 |  
 |  __rdiv__(...)
 |      x.__rdiv__(y) <==> y/x
 |  
 |  __reduce__(...)
 |  
 |  __repr__(...)
 |      x.__repr__() <==> repr(x)
 |  
 |  __rmul__(...)
 |      x.__rmul__(y) <==> y*x
 |  
 |  __rsub__(...)
 |      x.__rsub__(y) <==> y-x
 |  
 |  __sub__(...)
 |      x.__sub__(y) <==> x-y
 |  
 |  ----------------------------------------------------------------------
 |  Data and other attributes inherited from ROOT.ObjectProxy:
 |  
 |  __new__ = <built-in method __new__ of ROOT.PyRootType object>
 |      T.__new__(S, ...) -> a new object with type S, a subtype of T


Out[41]:
['AbstractMethod',
 'AppendPad',
 'Browse',
 'Class',
 'ClassName',
 'Class_Name',
 'Class_Version',
 'Clear',
 'Clone',
 'Compare',
 'Copy',
 'DeclFileLine',
 'DeclFileName',
 'Delete',
 'Dictionary',
 'DistancetoPrimitive',
 'Draw',
 'DrawClass',
 'DrawClone',
 'Dump',
 'Error',
 'Execute',
 'ExecuteEvent',
 'Fatal',
 'FindObject',
 'Get4Momentum',
 'GetDrawOption',
 'GetDtorOnly',
 'GetEnergy',
 'GetIconName',
 'GetMass',
 'GetMomentum',
 'GetMotherId',
 'GetNPoints',
 'GetName',
 'GetObjectInfo',
 'GetObjectStat',
 'GetOption',
 'GetP',
 'GetPdgCode',
 'GetPt',
 'GetPx',
 'GetPy',
 'GetPz',
 'GetRapidity',
 'GetStartT',
 'GetStartVertex',
 'GetStartX',
 'GetStartY',
 'GetStartZ',
 'GetTitle',
 'GetUniqueID',
 'GetWeight',
 'HandleTimer',
 'Hash',
 'ImplFileLine',
 'ImplFileName',
 'Info',
 'InheritsFrom',
 'Inspect',
 'InvertBit',
 'IsA',
 'IsEqual',
 'IsFolder',
 'IsOnHeap',
 'IsSortable',
 'IsZombie',
 'MayNotUse',
 'Notify',
 'Obsolete',
 'Paint',
 'Pop',
 'Print',
 'Read',
 'RecursiveRemove',
 'ResetBit',
 'SaveAs',
 'SavePrimitive',
 'SetBit',
 'SetDrawOption',
 'SetDtorOnly',
 'SetMotherId',
 'SetNPoints',
 'SetObjectStat',
 'SetUniqueID',
 'ShowMembers',
 'Streamer',
 'StreamerNVirtual',
 'SysError',
 'TestBit',
 'TestBits',
 'UseCurrentStyle',
 'Warning',
 'Write',
 '_TObject__DoError',
 '_TObject__MakeZombie',
 '__add__',
 '__assign__',
 '__bool__',
 '__class__',
 '__cmp__',
 '__contains__',
 '__delattr__',
 '__dict__',
 '__div__',
 '__doc__',
 '__eq__',
 '__format__',
 '__ge__',
 '__getattribute__',
 '__gt__',
 '__hash__',
 '__init__',
 '__le__',
 '__lt__',
 '__module__',
 '__mul__',
 '__ne__',
 '__new__',
 '__nonzero__',
 '__radd__',
 '__rdiv__',
 '__reduce__',
 '__reduce_ex__',
 '__repr__',
 '__rmul__',
 '__rsub__',
 '__setattr__',
 '__sizeof__',
 '__str__',
 '__sub__',
 '__subclasshook__',
 '__weakref__',
 'kBitMask',
 'kCanDelete',
 'kCannotPick',
 'kHasUUID',
 'kInvalidObject',
 'kIsOnHeap',
 'kIsReferenced',
 'kMustCleanup',
 'kNoContextMenu',
 'kNotDeleted',
 'kObjInCanvas',
 'kOverwrite',
 'kSingleKey',
 'kWriteDelete',
 'kZombie',
 'ls',
 'operator delete',
 'operator delete[]',
 'operator new',
 'operator new[]']
In [6]:
# The ROOT PDG database allows quick identification of particles based on their code / name
pdg = r.TDatabasePDG.Instance()
for track in mcTracks:
    print track.GetPdgCode()
-411
9900015
-211
-13
11

In [7]:
# The guy with the funny number above is an HNL.
# The ROOT PDG database does not know about it. But FairShip has a function to add it.
import pythia8_conf
pythia8_conf.addHNLtoROOT()
for track in mcTracks:
    print pdg.GetParticle(track.GetPdgCode()).GetName()
D-
N2
pi-
mu+
e-

In [8]:
# Now let us have a look at what this event looks like.
for i,track in enumerate(mcTracks):
    print i, pdg.GetParticle(track.GetPdgCode()).GetName(), track.GetMotherId()
0 D- -1
1 N2 0
2 pi- 1
3 mu+ 1
4 e- 3

In [9]:
# We want a nicer printout. But careful: the beam does not have a mother!
for i,track in enumerate(mcTracks):
    if i > 0:
        print i, pdg.GetParticle(track.GetPdgCode()).GetName(), 'daughter of', pdg.GetParticle(mcTracks[track.GetMotherId()].GetPdgCode()).GetName()
1 N2 daughter of D-
2 pi- daughter of N2
3 mu+ daughter of N2
4 e- daughter of mu+

In [10]:
# Meet the true (simulated) HNL.
myHNL = mcTracks[1]
myHNL.GetPdgCode()
Out[10]:
9900015
In [11]:
# Meet its daughters.
for track in mcTracks:
    if track.GetMotherId() == 1:
        print mcTracks.index(track)

for i,track in enumerate(mcTracks):
    if track.GetMotherId() == 1:
        print i, pdg.GetParticle(track.GetPdgCode()).GetName()
2
3
2 pi-
3 mu+

In [12]:
# We do not feel like typing all that code anymore.
def name(track):
    return pdg.GetParticle(track.GetPdgCode()).GetName()
for i,track in enumerate(mcTracks):
    if track.GetMotherId() == 1:
        print name(track)
pi-
mu+

In [13]:
# Let's open the geometry file.
# This file is generated by run_simScript.py along with the data file.
# It is "unique" to your production. Please always refer to the same geometry you use to generate your file, when analysing it.
geo = r.TFile('geofile_full.10.0.Pythia8-TGeant4.root','read')
geo.ls()
sGeo = geo.FAIRGeom
fGeo = r.gGeoManager
In [14]:
# FindNode is a useful function. It takes x,y,z coordinates and tells you to what geometry node they correspond.
# For example, see where these particles originate.
for track in mcTracks:
    print fGeo.FindNode(track.GetStartX(), track.GetStartY(), track.GetStartZ()).GetName()
Target_1_1
Target_1_1
cave_1
cave_1
rockD_1

In [15]:
# Meet the basic brick of our geometry.
fGeo.GetTopVolume()
help(fGeo.GetTopVolume())
Help on TGeoVolume in module __main__ object:

class TGeoVolume(ROOT.TNamed, TGeoAtt, ROOT.TAttLine, ROOT.TAttFill, TAtt3D)
 |  Method resolution order:
 |      TGeoVolume
 |      ROOT.TNamed
 |      ROOT.TObject
 |      TGeoAtt
 |      ROOT.TAttLine
 |      ROOT.TAttFill
 |      TAtt3D
 |      ROOT.ObjectProxy
 |      __builtin__.object
 |  
 |  Methods defined here:
 |  
 |  AddNode(self, TGeoVolume* vol, Int_t copy_no, TGeoMatrix* mat=0, Option_t* option='')
 |      void TGeoVolume::AddNode(TGeoVolume* vol, Int_t copy_no, TGeoMatrix* mat = 0, Option_t* option = "")
 |  
 |  AddNodeOffset(self, TGeoVolume* vol, Int_t copy_no, Double_t offset=0, Option_t* option='')
 |      void TGeoVolume::AddNodeOffset(TGeoVolume* vol, Int_t copy_no, Double_t offset = 0, Option_t* option = "")
 |  
 |  AddNodeOverlap(self, TGeoVolume* vol, Int_t copy_no, TGeoMatrix* mat=0, Option_t* option='')
 |      void TGeoVolume::AddNodeOverlap(TGeoVolume* vol, Int_t copy_no, TGeoMatrix* mat = 0, Option_t* option = "")
 |  
 |  Browse(self, TBrowser* b)
 |      void TGeoVolume::Browse(TBrowser* b)
 |  
 |  Capacity(self)
 |      Double_t TGeoVolume::Capacity()
 |  
 |  CheckGeometry(self, Int_t nrays=1, Double_t startx=0, Double_t starty=0, Double_t startz=0)
 |      void TGeoVolume::CheckGeometry(Int_t nrays = 1, Double_t startx = 0, Double_t starty = 0, Double_t startz = 0)
 |  
 |  CheckOverlaps(self, Double_t ovlp=0.10000000000000001, Option_t* option='')
 |      void TGeoVolume::CheckOverlaps(Double_t ovlp = 0.1, Option_t* option = "")
 |  
 |  CheckShape(self, Int_t testNo, Int_t nsamples=10000, Option_t* option='')
 |      void TGeoVolume::CheckShape(Int_t testNo, Int_t nsamples = 10000, Option_t* option = "")
 |  
 |  CheckShapes(self)
 |      void TGeoVolume::CheckShapes()
 |  
 |  Class(self)
 |      static TClass* TGeoVolume::Class()
 |  
 |  Class_Name(self)
 |      static const char* TGeoVolume::Class_Name()
 |  
 |  Class_Version(self)
 |      static Version_t TGeoVolume::Class_Version()
 |  
 |  CleanAll(self)
 |      void TGeoVolume::CleanAll()
 |  
 |  ClearNodes(self)
 |      void TGeoVolume::ClearNodes()
 |  
 |  ClearShape(self)
 |      void TGeoVolume::ClearShape()
 |  
 |  ClearThreadData(self)
 |      void TGeoVolume::ClearThreadData()
 |  
 |  CloneNodesAndConnect(self, TGeoVolume* newmother)
 |      void TGeoVolume::CloneNodesAndConnect(TGeoVolume* newmother)
 |  
 |  CloneVolume(self)
 |      TGeoVolume* TGeoVolume::CloneVolume()
 |  
 |  Contains(self, const Double_t* point)
 |      Bool_t TGeoVolume::Contains(const Double_t* point)
 |  
 |  CountNodes(self, Int_t nlevels=1000, Int_t option=0)
 |      Int_t TGeoVolume::CountNodes(Int_t nlevels = 1000, Int_t option = 0)
 |  
 |  CreateDummyMedium(self)
 |      static void TGeoVolume::CreateDummyMedium()
 |  
 |  CreateThreadData(self, Int_t nthreads)
 |      void TGeoVolume::CreateThreadData(Int_t nthreads)
 |  
 |  DeclFileLine(self)
 |      static int TGeoVolume::DeclFileLine()
 |  
 |  DeclFileName(self)
 |      static const char* TGeoVolume::DeclFileName()
 |  
 |  Dictionary(self)
 |      static void TGeoVolume::Dictionary()
 |  
 |  DistancetoPrimitive(self, Int_t px, Int_t py)
 |      Int_t TGeoVolume::DistancetoPrimitive(Int_t px, Int_t py)
 |  
 |  Divide(self, const char* divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step, Int_t numed=0, Option_t* option='')
 |      TGeoVolume* TGeoVolume::Divide(const char* divname, Int_t iaxis, Int_t ndiv, Double_t start, Double_t step, Int_t numed = 0, Option_t* option = "")
 |  
 |  Draw(self, Option_t* option='')
 |      void TGeoVolume::Draw(Option_t* option = "")
 |  
 |  DrawOnly(self, Option_t* option='')
 |      void TGeoVolume::DrawOnly(Option_t* option = "")
 |  
 |  DummyMedium(self)
 |      static TGeoMedium* TGeoVolume::DummyMedium()
 |  
 |  ExecuteEvent(self, Int_t event, Int_t px, Int_t py)
 |      void TGeoVolume::ExecuteEvent(Int_t event, Int_t px, Int_t py)
 |  
 |  Export(self, const char* filename, const char* name='', Option_t* option='')
 |      Int_t TGeoVolume::Export(const char* filename, const char* name = "", Option_t* option = "")
 |  
 |  FindMatrixOfDaughterVolume(self, TGeoVolume* vol)
 |      Bool_t TGeoVolume::FindMatrixOfDaughterVolume(TGeoVolume* vol)
 |  
 |  FindNode(self, const char* name)
 |      TGeoNode* TGeoVolume::FindNode(const char* name)
 |  
 |  FindOverlaps(self)
 |      void TGeoVolume::FindOverlaps()
 |  
 |  GetByteCount(self)
 |      Int_t TGeoVolume::GetByteCount()
 |  
 |  GetCurrentNodeIndex(self)
 |      Int_t TGeoVolume::GetCurrentNodeIndex()
 |  
 |  GetFWExtension(self)
 |      TGeoExtension* TGeoVolume::GetFWExtension()
 |  
 |  GetField(self)
 |      TObject* TGeoVolume::GetField()
 |  
 |  GetFinder(self)
 |      TGeoPatternFinder* TGeoVolume::GetFinder()
 |  
 |  GetGeoManager(self)
 |      TGeoManager* TGeoVolume::GetGeoManager()
 |  
 |  GetIconName(self)
 |      const char* TGeoVolume::GetIconName()
 |  
 |  GetIndex(self, const TGeoNode* node)
 |      Int_t TGeoVolume::GetIndex(const TGeoNode* node)
 |  
 |  GetMaterial(self)
 |      TGeoMaterial* TGeoVolume::GetMaterial()
 |  
 |  GetMedium(self)
 |      TGeoMedium* TGeoVolume::GetMedium()
 |  
 |  GetNdaughters(self)
 |      Int_t TGeoVolume::GetNdaughters()
 |  
 |  GetNextNodeIndex(self)
 |      Int_t TGeoVolume::GetNextNodeIndex()
 |  
 |  GetNode(self, const char* name)
 |      TGeoNode* TGeoVolume::GetNode(const char* name)
 |      TGeoNode* TGeoVolume::GetNode(Int_t i)
 |  
 |  GetNodeIndex(self, const TGeoNode* node, Int_t* check_list, Int_t ncheck)
 |      Int_t TGeoVolume::GetNodeIndex(const TGeoNode* node, Int_t* check_list, Int_t ncheck)
 |  
 |  GetNodes(self)
 |      TObjArray* TGeoVolume::GetNodes()
 |  
 |  GetNtotal(self)
 |      Int_t TGeoVolume::GetNtotal()
 |  
 |  GetNumber(self)
 |      Int_t TGeoVolume::GetNumber()
 |  
 |  GetObjectInfo(self, Int_t px, Int_t py)
 |      char* TGeoVolume::GetObjectInfo(Int_t px, Int_t py)
 |  
 |  GetOptimalVoxels(self)
 |      Bool_t TGeoVolume::GetOptimalVoxels()
 |  
 |  GetOption(self)
 |      Option_t* TGeoVolume::GetOption()
 |  
 |  GetPointerName(self)
 |      char* TGeoVolume::GetPointerName()
 |  
 |  GetRefCount(self)
 |      Int_t TGeoVolume::GetRefCount()
 |  
 |  GetShape(self)
 |      TGeoShape* TGeoVolume::GetShape()
 |  
 |  GetTransparency(self)
 |      Char_t TGeoVolume::GetTransparency()
 |  
 |  GetUserExtension(self)
 |      TGeoExtension* TGeoVolume::GetUserExtension()
 |  
 |  GetVoxels(self)
 |      TGeoVoxelFinder* TGeoVolume::GetVoxels()
 |  
 |  Grab(self)
 |      void TGeoVolume::Grab()
 |  
 |  GrabFWExtension(self)
 |      TGeoExtension* TGeoVolume::GrabFWExtension()
 |  
 |  GrabFocus(self)
 |      void TGeoVolume::GrabFocus()
 |  
 |  GrabUserExtension(self)
 |      TGeoExtension* TGeoVolume::GrabUserExtension()
 |  
 |  Gsord(self, Int_t)
 |      void TGeoVolume::Gsord(Int_t)
 |  
 |  ImplFileLine(self)
 |      static int TGeoVolume::ImplFileLine()
 |  
 |  ImplFileName(self)
 |      static const char* TGeoVolume::ImplFileName()
 |  
 |  Import(self, const char* filename, const char* name='', Option_t* option='')
 |      static TGeoVolume* TGeoVolume::Import(const char* filename, const char* name = "", Option_t* option = "")
 |  
 |  InspectMaterial(self)
 |      void TGeoVolume::InspectMaterial()
 |  
 |  InspectShape(self)
 |      void TGeoVolume::InspectShape()
 |  
 |  InvisibleAll(self, Bool_t flag='kTRUE')
 |      void TGeoVolume::InvisibleAll(Bool_t flag = kTRUE)
 |  
 |  IsA(self)
 |      TClass* TGeoVolume::IsA()
 |  
 |  IsActive(self)
 |      Bool_t TGeoVolume::IsActive()
 |  
 |  IsActiveDaughters(self)
 |      Bool_t TGeoVolume::IsActiveDaughters()
 |  
 |  IsAdded(self)
 |      Bool_t TGeoVolume::IsAdded()
 |  
 |  IsAllInvisible(self)
 |      Bool_t TGeoVolume::IsAllInvisible()
 |  
 |  IsAssembly(self)
 |      Bool_t TGeoVolume::IsAssembly()
 |  
 |  IsCylVoxels(self)
 |      Bool_t TGeoVolume::IsCylVoxels()
 |  
 |  IsFolder(self)
 |      Bool_t TGeoVolume::IsFolder()
 |  
 |  IsOverlappingCandidate(self)
 |      Bool_t TGeoVolume::IsOverlappingCandidate()
 |  
 |  IsRaytracing(self)
 |      Bool_t TGeoVolume::IsRaytracing()
 |  
 |  IsReplicated(self)
 |      Bool_t TGeoVolume::IsReplicated()
 |  
 |  IsRunTime(self)
 |      Bool_t TGeoVolume::IsRunTime()
 |  
 |  IsSelected(self)
 |      Bool_t TGeoVolume::IsSelected()
 |  
 |  IsStyleDefault(self)
 |      Bool_t TGeoVolume::IsStyleDefault()
 |  
 |  IsTopVolume(self)
 |      Bool_t TGeoVolume::IsTopVolume()
 |  
 |  IsValid(self)
 |      Bool_t TGeoVolume::IsValid()
 |  
 |  IsVisContainers(self)
 |      Bool_t TGeoVolume::IsVisContainers()
 |  
 |  IsVisLeaves(self)
 |      Bool_t TGeoVolume::IsVisLeaves()
 |  
 |  IsVisOnly(self)
 |      Bool_t TGeoVolume::IsVisOnly()
 |  
 |  IsVisible(self)
 |      Bool_t TGeoVolume::IsVisible()
 |  
 |  IsVisibleDaughters(self)
 |      Bool_t TGeoVolume::IsVisibleDaughters()
 |  
 |  IsVolumeMulti(self)
 |      Bool_t TGeoVolume::IsVolumeMulti()
 |  
 |  IsXYZVoxels(self)
 |      Bool_t TGeoVolume::IsXYZVoxels()
 |  
 |  LegoPlot(self, Int_t ntheta=20, Double_t themin=0.0, Double_t themax=180.0, Int_t nphi=60, Double_t phimin=0.0, Double_t phimax=360.0, Double_t rmin=0.0, Double_t rmax=9999999, Option_t* option='')
 |      TH2F* TGeoVolume::LegoPlot(Int_t ntheta = 20, Double_t themin = 0., Double_t themax = 180., Int_t nphi = 60, Double_t phimin = 0., Double_t phimax = 360., Double_t rmin = 0., Double_t rmax = 9999999, Option_t* option = "")
 |  
 |  MakeCopyNodes(self, const TGeoVolume* other)
 |      void TGeoVolume::MakeCopyNodes(const TGeoVolume* other)
 |  
 |  MakeCopyVolume(self, TGeoShape* newshape)
 |      TGeoVolume* TGeoVolume::MakeCopyVolume(TGeoShape* newshape)
 |  
 |  MakeReflectedVolume(self, const char* newname='')
 |      TGeoVolume* TGeoVolume::MakeReflectedVolume(const char* newname = "")
 |  
 |  OptimizeVoxels(self)
 |      Bool_t TGeoVolume::OptimizeVoxels()
 |  
 |  Paint(self, Option_t* option='')
 |      void TGeoVolume::Paint(Option_t* option = "")
 |  
 |  Print(self, Option_t* option='')
 |      void TGeoVolume::Print(Option_t* option = "")
 |  
 |  PrintNodes(self)
 |      void TGeoVolume::PrintNodes()
 |  
 |  PrintVoxels(self)
 |      void TGeoVolume::PrintVoxels()
 |  
 |  RandomPoints(self, Int_t npoints=1000000, Option_t* option='')
 |      void TGeoVolume::RandomPoints(Int_t npoints = 1000000, Option_t* option = "")
 |  
 |  RandomRays(self, Int_t nrays=10000, Double_t startx=0, Double_t starty=0, Double_t startz=0, const char* target_vol=0, Bool_t check_norm='kFALSE')
 |      void TGeoVolume::RandomRays(Int_t nrays = 10000, Double_t startx = 0, Double_t starty = 0, Double_t startz = 0, const char* target_vol = 0, Bool_t check_norm = kFALSE)
 |  
 |  Raytrace(self, Bool_t flag='kTRUE')
 |      void TGeoVolume::Raytrace(Bool_t flag = kTRUE)
 |  
 |  RegisterYourself(self, Option_t* option='')
 |      void TGeoVolume::RegisterYourself(Option_t* option = "")
 |  
 |  Release(self)
 |      void TGeoVolume::Release()
 |  
 |  RemoveNode(self, TGeoNode* node)
 |      void TGeoVolume::RemoveNode(TGeoNode* node)
 |  
 |  ReplaceNode(self, TGeoNode* nodeorig, TGeoShape* newshape=0, TGeoMatrix* newpos=0, TGeoMedium* newmed=0)
 |      TGeoNode* TGeoVolume::ReplaceNode(TGeoNode* nodeorig, TGeoShape* newshape = 0, TGeoMatrix* newpos = 0, TGeoMedium* newmed = 0)
 |  
 |  ReplayCreation(self, const TGeoVolume* other)
 |      void TGeoVolume::ReplayCreation(const TGeoVolume* other)
 |  
 |  SaveAs(self, const char* filename, Option_t* option='')
 |      void TGeoVolume::SaveAs(const char* filename, Option_t* option = "")
 |  
 |  SavePrimitive(self, ostream& out, Option_t* option='')
 |      void TGeoVolume::SavePrimitive(ostream& out, Option_t* option = "")
 |  
 |  SelectVolume(self, Bool_t clear='kFALSE')
 |      void TGeoVolume::SelectVolume(Bool_t clear = kFALSE)
 |  
 |  SetActiveDaughters(self, Bool_t flag='kTRUE')
 |      void TGeoVolume::SetActiveDaughters(Bool_t flag = kTRUE)
 |  
 |  SetActivity(self, Bool_t flag='kTRUE')
 |      void TGeoVolume::SetActivity(Bool_t flag = kTRUE)
 |  
 |  SetAdded(self)
 |      void TGeoVolume::SetAdded()
 |  
 |  SetAsTopVolume(self)
 |      void TGeoVolume::SetAsTopVolume()
 |  
 |  SetAttVisibility(self, Bool_t vis)
 |      void TGeoVolume::SetAttVisibility(Bool_t vis)
 |  
 |  SetCurrentPoint(self, Double_t x, Double_t y, Double_t z)
 |      void TGeoVolume::SetCurrentPoint(Double_t x, Double_t y, Double_t z)
 |  
 |  SetCylVoxels(self, Bool_t flag='kTRUE')
 |      void TGeoVolume::SetCylVoxels(Bool_t flag = kTRUE)
 |  
 |  SetFWExtension(self, TGeoExtension* ext)
 |      void TGeoVolume::SetFWExtension(TGeoExtension* ext)
 |  
 |  SetField(self, TObject* field)
 |      void TGeoVolume::SetField(TObject* field)
 |  
 |  SetFinder(self, TGeoPatternFinder* finder)
 |      void TGeoVolume::SetFinder(TGeoPatternFinder* finder)
 |  
 |  SetInvisible(self)
 |      void TGeoVolume::SetInvisible()
 |  
 |  SetLineColor(self, Color_t lcolor)
 |      void TGeoVolume::SetLineColor(Color_t lcolor)
 |  
 |  SetLineStyle(self, Style_t lstyle)
 |      void TGeoVolume::SetLineStyle(Style_t lstyle)
 |  
 |  SetLineWidth(self, Width_t lwidth)
 |      void TGeoVolume::SetLineWidth(Width_t lwidth)
 |  
 |  SetMedium(self, TGeoMedium* medium)
 |      void TGeoVolume::SetMedium(TGeoMedium* medium)
 |  
 |  SetNodes(self, TObjArray* nodes)
 |      void TGeoVolume::SetNodes(TObjArray* nodes)
 |  
 |  SetNtotal(self, Int_t ntotal)
 |      void TGeoVolume::SetNtotal(Int_t ntotal)
 |  
 |  SetNumber(self, Int_t number)
 |      void TGeoVolume::SetNumber(Int_t number)
 |  
 |  SetOption(self, const char* option)
 |      void TGeoVolume::SetOption(const char* option)
 |  
 |  SetOverlappingCandidate(self, Bool_t flag)
 |      void TGeoVolume::SetOverlappingCandidate(Bool_t flag)
 |  
 |  SetReplicated(self)
 |      void TGeoVolume::SetReplicated()
 |  
 |  SetShape(self, const TGeoShape* shape)
 |      void TGeoVolume::SetShape(const TGeoShape* shape)
 |  
 |  SetTransparency(self, Char_t transparency=0)
 |      void TGeoVolume::SetTransparency(Char_t transparency = 0)
 |  
 |  SetUserExtension(self, TGeoExtension* ext)
 |      void TGeoVolume::SetUserExtension(TGeoExtension* ext)
 |  
 |  SetVisContainers(self, Bool_t flag='kTRUE')
 |      void TGeoVolume::SetVisContainers(Bool_t flag = kTRUE)
 |  
 |  SetVisLeaves(self, Bool_t flag='kTRUE')
 |      void TGeoVolume::SetVisLeaves(Bool_t flag = kTRUE)
 |  
 |  SetVisOnly(self, Bool_t flag='kTRUE')
 |      void TGeoVolume::SetVisOnly(Bool_t flag = kTRUE)
 |  
 |  SetVisibility(self, Bool_t vis='kTRUE')
 |      void TGeoVolume::SetVisibility(Bool_t vis = kTRUE)
 |  
 |  SetVoxelFinder(self, TGeoVoxelFinder* finder)
 |      void TGeoVolume::SetVoxelFinder(TGeoVoxelFinder* finder)
 |  
 |  ShowMembers(self, TMemberInspector&)
 |      void TGeoVolume::ShowMembers(TMemberInspector&)
 |  
 |  SortNodes(self)
 |      void TGeoVolume::SortNodes()
 |  
 |  Streamer(self, TBuffer&)
 |      void TGeoVolume::Streamer(TBuffer&)
 |  
 |  StreamerNVirtual(self, TBuffer& ClassDef_StreamerNVirtual_b)
 |      void TGeoVolume::StreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
 |  
 |  UnmarkSaved(self)
 |      void TGeoVolume::UnmarkSaved()
 |  
 |  Valid(self)
 |      Bool_t TGeoVolume::Valid()
 |  
 |  VisibleDaughters(self, Bool_t vis='kTRUE')
 |      void TGeoVolume::VisibleDaughters(Bool_t vis = kTRUE)
 |  
 |  Voxelize(self, Option_t* option)
 |      void TGeoVolume::Voxelize(Option_t* option)
 |  
 |  Weight(self, Double_t precision=0.01, Option_t* option='va')
 |      Double_t TGeoVolume::Weight(Double_t precision = 0.01, Option_t* option = "va")
 |  
 |  WeightA(self)
 |      Double_t TGeoVolume::WeightA()
 |  
 |  __init__(self, const char* name, const TGeoShape* shape, const TGeoMedium* med=0)
 |      TGeoVolume::TGeoVolume()
 |      TGeoVolume::TGeoVolume(const char* name, const TGeoShape* shape, const TGeoMedium* med = 0)
 |  
 |  cd(self, Int_t inode)
 |      void TGeoVolume::cd(Int_t inode)
 |  
 |  ----------------------------------------------------------------------
 |  Data and other attributes defined here:
 |  
 |  kVolumeAdded = 8388608
 |  
 |  kVolumeClone = 4194304
 |  
 |  kVolumeDiv = 65536
 |  
 |  kVolumeImportNodes = 262144
 |  
 |  kVolumeMulti = 524288
 |  
 |  kVolumeOC = 2097152
 |  
 |  kVolumeOverlap = 131072
 |  
 |  kVolumeReplicated = 16384
 |  
 |  kVolumeSelected = 32768
 |  
 |  kVoxelsCyl = 2097152
 |  
 |  kVoxelsXYZ = 1048576
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.TNamed:
 |  
 |  Clear(self, Option_t* option='') from ROOT.TNamed
 |      void TNamed::Clear(Option_t* option = "")
 |  
 |  Clone(self, const char* newname='') from ROOT.TNamed
 |      TObject* TNamed::Clone(const char* newname = "")
 |  
 |  Compare(self, const TObject* obj) from ROOT.TNamed
 |      Int_t TNamed::Compare(const TObject* obj)
 |  
 |  Copy(self, TObject& named) from ROOT.TNamed
 |      void TNamed::Copy(TObject& named)
 |  
 |  FillBuffer(self, char*& buffer) from ROOT.TNamed
 |      void TNamed::FillBuffer(char*& buffer)
 |  
 |  GetName(self) from ROOT.TNamed
 |      const char* TNamed::GetName()
 |  
 |  GetTitle(self) from ROOT.TNamed
 |      const char* TNamed::GetTitle()
 |  
 |  Hash(self) from ROOT.TNamed
 |      ULong_t TNamed::Hash()
 |  
 |  IsSortable(self) from ROOT.TNamed
 |      Bool_t TNamed::IsSortable()
 |  
 |  SetName(self, const char* name) from ROOT.TNamed
 |      void TNamed::SetName(const char* name)
 |  
 |  SetNameTitle(self, const char* name, const char* title) from ROOT.TNamed
 |      void TNamed::SetNameTitle(const char* name, const char* title)
 |  
 |  SetTitle(self, const char* title='') from ROOT.TNamed
 |      void TNamed::SetTitle(const char* title = "")
 |  
 |  Sizeof(self) from ROOT.TNamed
 |      Int_t TNamed::Sizeof()
 |  
 |  __assign__(self, const TNamed& rhs) from ROOT.TNamed
 |      TNamed& TNamed::operator=(const TNamed& rhs)
 |  
 |  ls(self, Option_t* option='') from ROOT.TNamed
 |      void TNamed::ls(Option_t* option = "")
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.TObject:
 |  
 |  AbstractMethod(self, const char* method) from ROOT.TObject
 |      void TObject::AbstractMethod(const char* method)
 |  
 |  AppendPad(self, Option_t* option='') from ROOT.TObject
 |      void TObject::AppendPad(Option_t* option = "")
 |  
 |  ClassName(self) from ROOT.TObject
 |      const char* TObject::ClassName()
 |  
 |  Delete(self, Option_t* option='') from ROOT.TObject
 |      void TObject::Delete(Option_t* option = "")
 |  
 |  DrawClass(self) from ROOT.TObject
 |      void TObject::DrawClass()
 |  
 |  DrawClone(self, Option_t* option='') from ROOT.TObject
 |      TObject* TObject::DrawClone(Option_t* option = "")
 |  
 |  Dump(self) from ROOT.TObject
 |      void TObject::Dump()
 |  
 |  Error(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Error(const char* method, const char* msgfmt)
 |  
 |  Execute(self, const char* method, const char* params, Int_t* error=0) from ROOT.TObject
 |      void TObject::Execute(const char* method, const char* params, Int_t* error = 0)
 |      void TObject::Execute(TMethod* method, TObjArray* params, Int_t* error = 0)
 |  
 |  Fatal(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Fatal(const char* method, const char* msgfmt)
 |  
 |  FindObject(self, const char* name) from ROOT.TObject
 |      TObject* TObject::FindObject(const char* name)
 |      TObject* TObject::FindObject(const TObject* obj)
 |  
 |  GetDrawOption(self) from ROOT.TObject
 |      Option_t* TObject::GetDrawOption()
 |  
 |  GetDtorOnly(self) from ROOT.TObject
 |      static Long_t TObject::GetDtorOnly()
 |  
 |  GetObjectStat(self) from ROOT.TObject
 |      static Bool_t TObject::GetObjectStat()
 |  
 |  GetUniqueID(self) from ROOT.TObject
 |      UInt_t TObject::GetUniqueID()
 |  
 |  HandleTimer(self, TTimer* timer) from ROOT.TObject
 |      Bool_t TObject::HandleTimer(TTimer* timer)
 |  
 |  Info(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Info(const char* method, const char* msgfmt)
 |  
 |  InheritsFrom(self, const char* classname) from ROOT.TObject
 |      Bool_t TObject::InheritsFrom(const char* classname)
 |      Bool_t TObject::InheritsFrom(const TClass* cl)
 |  
 |  Inspect(self) from ROOT.TObject
 |      void TObject::Inspect()
 |  
 |  InvertBit(self, UInt_t f) from ROOT.TObject
 |      void TObject::InvertBit(UInt_t f)
 |  
 |  IsEqual(self, const TObject* obj) from ROOT.TObject
 |      Bool_t TObject::IsEqual(const TObject* obj)
 |  
 |  IsOnHeap(self) from ROOT.TObject
 |      Bool_t TObject::IsOnHeap()
 |  
 |  IsZombie(self) from ROOT.TObject
 |      Bool_t TObject::IsZombie()
 |  
 |  MayNotUse(self, const char* method) from ROOT.TObject
 |      void TObject::MayNotUse(const char* method)
 |  
 |  Notify(self) from ROOT.TObject
 |      Bool_t TObject::Notify()
 |  
 |  Obsolete(self, const char* method, const char* asOfVers, const char* removedFromVers) from ROOT.TObject
 |      void TObject::Obsolete(const char* method, const char* asOfVers, const char* removedFromVers)
 |  
 |  Pop(self) from ROOT.TObject
 |      void TObject::Pop()
 |  
 |  Read(self, const char* name) from ROOT.TObject
 |      Int_t TObject::Read(const char* name)
 |  
 |  RecursiveRemove(self, TObject* obj) from ROOT.TObject
 |      void TObject::RecursiveRemove(TObject* obj)
 |  
 |  ResetBit(self, UInt_t f) from ROOT.TObject
 |      void TObject::ResetBit(UInt_t f)
 |  
 |  SetBit(self, UInt_t f, Bool_t set) from ROOT.TObject
 |      void TObject::SetBit(UInt_t f, Bool_t set)
 |      void TObject::SetBit(UInt_t f)
 |  
 |  SetDrawOption(self, Option_t* option='') from ROOT.TObject
 |      void TObject::SetDrawOption(Option_t* option = "")
 |  
 |  SetDtorOnly(self, void* obj) from ROOT.TObject
 |      static void TObject::SetDtorOnly(void* obj)
 |  
 |  SetObjectStat(self, Bool_t stat) from ROOT.TObject
 |      static void TObject::SetObjectStat(Bool_t stat)
 |  
 |  SetUniqueID(self, UInt_t uid) from ROOT.TObject
 |      void TObject::SetUniqueID(UInt_t uid)
 |  
 |  SysError(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::SysError(const char* method, const char* msgfmt)
 |  
 |  TestBit(self, UInt_t f) from ROOT.TObject
 |      Bool_t TObject::TestBit(UInt_t f)
 |  
 |  TestBits(self, UInt_t f) from ROOT.TObject
 |      Int_t TObject::TestBits(UInt_t f)
 |  
 |  UseCurrentStyle(self) from ROOT.TObject
 |      void TObject::UseCurrentStyle()
 |  
 |  Warning(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Warning(const char* method, const char* msgfmt)
 |  
 |  Write(self, const char* name=0, Int_t option=0, Int_t bufsize=0) from ROOT.TObject
 |      Int_t TObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
 |      Int_t TObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
 |  
 |  __cmp__(...)
 |  
 |  __contains__(...)
 |  
 |  __eq__(...)
 |  
 |  __ne__(...)
 |  
 |  operator delete(self, void* ptr, void* vp) from ROOT.TObject
 |      static void TObject::operator delete(void* ptr)
 |      static void TObject::operator delete(void* ptr, void* vp)
 |  
 |  operator delete[](self, void* ptr, void* vp) from ROOT.TObject
 |      static void TObject::operator delete[](void* ptr)
 |      static void TObject::operator delete[](void* ptr, void* vp)
 |  
 |  operator new(self, size_t sz, void* vp) from ROOT.TObject
 |      void* TObject::operator new(size_t sz)
 |      void* TObject::operator new(size_t sz, void* vp)
 |  
 |  operator new[](self, size_t sz, void* vp) from ROOT.TObject
 |      void* TObject::operator new[](size_t sz)
 |      void* TObject::operator new[](size_t sz, void* vp)
 |  
 |  ----------------------------------------------------------------------
 |  Data descriptors inherited from ROOT.TObject:
 |  
 |  __dict__
 |      dictionary for instance variables (if defined)
 |  
 |  __weakref__
 |      list of weak references to the object (if defined)
 |  
 |  ----------------------------------------------------------------------
 |  Data and other attributes inherited from ROOT.TObject:
 |  
 |  kBitMask = 16777215
 |  
 |  kCanDelete = 1
 |  
 |  kCannotPick = 64
 |  
 |  kHasUUID = 32
 |  
 |  kInvalidObject = 8192
 |  
 |  kIsOnHeap = 16777216
 |  
 |  kIsReferenced = 16
 |  
 |  kMustCleanup = 8
 |  
 |  kNoContextMenu = 256
 |  
 |  kNotDeleted = 33554432
 |  
 |  kObjInCanvas = 8
 |  
 |  kOverwrite = 2
 |  
 |  kSingleKey = 1
 |  
 |  kWriteDelete = 4
 |  
 |  kZombie = 67108864
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from TGeoAtt:
 |  
 |  IsVisBranch(self) from __main__.TGeoAtt
 |      Bool_t TGeoAtt::IsVisBranch()
 |  
 |  IsVisDaughters(self) from __main__.TGeoAtt
 |      Bool_t TGeoAtt::IsVisDaughters()
 |  
 |  IsVisRaytrace(self) from __main__.TGeoAtt
 |      Bool_t TGeoAtt::IsVisRaytrace()
 |  
 |  IsVisStreamed(self) from __main__.TGeoAtt
 |      Bool_t TGeoAtt::IsVisStreamed()
 |  
 |  IsVisTouched(self) from __main__.TGeoAtt
 |      Bool_t TGeoAtt::IsVisTouched()
 |  
 |  ResetAttBit(self, UInt_t f) from __main__.TGeoAtt
 |      void TGeoAtt::ResetAttBit(UInt_t f)
 |  
 |  SetAttBit(self, UInt_t f, Bool_t set) from __main__.TGeoAtt
 |      void TGeoAtt::SetAttBit(UInt_t f)
 |      void TGeoAtt::SetAttBit(UInt_t f, Bool_t set)
 |  
 |  SetOptimization(self, Option_t* option) from __main__.TGeoAtt
 |      void TGeoAtt::SetOptimization(Option_t* option)
 |  
 |  SetVisBranch(self) from __main__.TGeoAtt
 |      void TGeoAtt::SetVisBranch()
 |  
 |  SetVisDaughters(self, Bool_t vis='kTRUE') from __main__.TGeoAtt
 |      void TGeoAtt::SetVisDaughters(Bool_t vis = kTRUE)
 |  
 |  SetVisRaytrace(self, Bool_t flag='kTRUE') from __main__.TGeoAtt
 |      void TGeoAtt::SetVisRaytrace(Bool_t flag = kTRUE)
 |  
 |  SetVisStreamed(self, Bool_t vis='kTRUE') from __main__.TGeoAtt
 |      void TGeoAtt::SetVisStreamed(Bool_t vis = kTRUE)
 |  
 |  SetVisTouched(self, Bool_t vis='kTRUE') from __main__.TGeoAtt
 |      void TGeoAtt::SetVisTouched(Bool_t vis = kTRUE)
 |  
 |  TestAttBit(self, UInt_t f) from __main__.TGeoAtt
 |      Bool_t TGeoAtt::TestAttBit(UInt_t f)
 |  
 |  ----------------------------------------------------------------------
 |  Data and other attributes inherited from TGeoAtt:
 |  
 |  kActDaughters = 2048
 |  
 |  kActNone = 512
 |  
 |  kActOverride = 256
 |  
 |  kActThis = 1024
 |  
 |  kSaveNodesAtt = 1048576
 |  
 |  kSavePrimitiveAtt = 524288
 |  
 |  kUseBoundingBox = 65536
 |  
 |  kUseGsord = 262144
 |  
 |  kUseVoxels = 131072
 |  
 |  kVisBranch = 16384
 |  
 |  kVisContainers = 4096
 |  
 |  kVisDaughters = 8
 |  
 |  kVisNone = 2
 |  
 |  kVisOnScreen = 128
 |  
 |  kVisOneLevel = 16
 |  
 |  kVisOnly = 8192
 |  
 |  kVisOverride = 1
 |  
 |  kVisRaytrace = 32768
 |  
 |  kVisStreamed = 32
 |  
 |  kVisThis = 4
 |  
 |  kVisTouched = 64
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.TAttLine:
 |  
 |  DistancetoLine(self, Int_t px, Int_t py, Double_t xp1, Double_t yp1, Double_t xp2, Double_t yp2) from ROOT.TAttLine
 |      Int_t TAttLine::DistancetoLine(Int_t px, Int_t py, Double_t xp1, Double_t yp1, Double_t xp2, Double_t yp2)
 |  
 |  GetLineColor(self) from ROOT.TAttLine
 |      Color_t TAttLine::GetLineColor()
 |  
 |  GetLineStyle(self) from ROOT.TAttLine
 |      Style_t TAttLine::GetLineStyle()
 |  
 |  GetLineWidth(self) from ROOT.TAttLine
 |      Width_t TAttLine::GetLineWidth()
 |  
 |  Modify(self) from ROOT.TAttLine
 |      void TAttLine::Modify()
 |  
 |  ResetAttLine(self, Option_t* option='') from ROOT.TAttLine
 |      void TAttLine::ResetAttLine(Option_t* option = "")
 |  
 |  SaveLineAttributes(self, basic_ostream<char,char_traits<char> >& out, const char* name, Int_t coldef=1, Int_t stydef=1, Int_t widdef=1) from ROOT.TAttLine
 |      void TAttLine::SaveLineAttributes(basic_ostream<char,char_traits<char> >& out, const char* name, Int_t coldef = 1, Int_t stydef = 1, Int_t widdef = 1)
 |  
 |  SetLineAttributes(self) from ROOT.TAttLine
 |      void TAttLine::SetLineAttributes()
 |  
 |  SetLineColorAlpha(self, Color_t lcolor, Float_t lalpha) from ROOT.TAttLine
 |      void TAttLine::SetLineColorAlpha(Color_t lcolor, Float_t lalpha)
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.TAttFill:
 |  
 |  GetFillColor(self) from ROOT.TAttFill
 |      Color_t TAttFill::GetFillColor()
 |  
 |  GetFillStyle(self) from ROOT.TAttFill
 |      Style_t TAttFill::GetFillStyle()
 |  
 |  IsTransparent(self) from ROOT.TAttFill
 |      Bool_t TAttFill::IsTransparent()
 |  
 |  ResetAttFill(self, Option_t* option='') from ROOT.TAttFill
 |      void TAttFill::ResetAttFill(Option_t* option = "")
 |  
 |  SaveFillAttributes(self, basic_ostream<char,char_traits<char> >& out, const char* name, Int_t coldef=1, Int_t stydef=1001) from ROOT.TAttFill
 |      void TAttFill::SaveFillAttributes(basic_ostream<char,char_traits<char> >& out, const char* name, Int_t coldef = 1, Int_t stydef = 1001)
 |  
 |  SetFillAttributes(self) from ROOT.TAttFill
 |      void TAttFill::SetFillAttributes()
 |  
 |  SetFillColor(self, Color_t fcolor) from ROOT.TAttFill
 |      void TAttFill::SetFillColor(Color_t fcolor)
 |  
 |  SetFillColorAlpha(self, Color_t fcolor, Float_t falpha) from ROOT.TAttFill
 |      void TAttFill::SetFillColorAlpha(Color_t fcolor, Float_t falpha)
 |  
 |  SetFillStyle(self, Style_t fstyle) from ROOT.TAttFill
 |      void TAttFill::SetFillStyle(Style_t fstyle)
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from TAtt3D:
 |  
 |  Sizeof3D(self) from __main__.TAtt3D
 |      void TAtt3D::Sizeof3D()
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.ObjectProxy:
 |  
 |  __add__(...)
 |      x.__add__(y) <==> x+y
 |  
 |  __bool__(...)
 |  
 |  __div__(...)
 |      x.__div__(y) <==> x/y
 |  
 |  __ge__(...)
 |      x.__ge__(y) <==> x>=y
 |  
 |  __gt__(...)
 |      x.__gt__(y) <==> x>y
 |  
 |  __le__(...)
 |      x.__le__(y) <==> x<=y
 |  
 |  __lt__(...)
 |      x.__lt__(y) <==> x<y
 |  
 |  __mul__(...)
 |      x.__mul__(y) <==> x*y
 |  
 |  __nonzero__(...)
 |  
 |  __radd__(...)
 |      x.__radd__(y) <==> y+x
 |  
 |  __rdiv__(...)
 |      x.__rdiv__(y) <==> y/x
 |  
 |  __reduce__(...)
 |  
 |  __repr__(...)
 |      x.__repr__() <==> repr(x)
 |  
 |  __rmul__(...)
 |      x.__rmul__(y) <==> y*x
 |  
 |  __rsub__(...)
 |      x.__rsub__(y) <==> y-x
 |  
 |  __sub__(...)
 |      x.__sub__(y) <==> x-y
 |  
 |  ----------------------------------------------------------------------
 |  Data and other attributes inherited from ROOT.ObjectProxy:
 |  
 |  __new__ = <built-in method __new__ of ROOT.PyRootType object>
 |      T.__new__(S, ...) -> a new object with type S, a subtype of T


In [16]:
# First children nodes.
fGeo.GetTopVolume().GetNodes()
Out[16]:
<ROOT.TObjArray object ("TObjArray") at 0x6e41000>
In [17]:
# Actually we want to see their names...
for node in fGeo.GetTopVolume().GetNodes():
    print node.GetName()
MuonShieldArea_1
rockS_1
rockD_1
TargetArea_1
magyoke_1
MCoil_1
DecayVolume_1
MagVolume_1
TimeDet_1
VetoTimeDet_1
Detector2_1
volMagneticSpectrometer_1
volBase_1
volGoliath_1
Veto_5
Tr1_1
Tr2_2
Tr3_3
Tr4_4
Ecal_1
Hcal_1
MuonDetector_1

In [18]:
# Get the z coordinate of the center of a certain node.
fGeo.GetTopVolume().GetNode('Veto_5')
fGeo.GetTopVolume().GetNode('Veto_5').GetMatrix()
fGeo.GetTopVolume().GetNode('Veto_5').GetMatrix().GetTranslation()
zveto5_center = fGeo.GetTopVolume().GetNode('Veto_5').GetMatrix().GetTranslation()[2]
In [19]:
# Get its half-width
dzveto5 = fGeo.GetTopVolume().GetNode('Veto_5').GetVolume().GetShape().GetDZ()
In [42]:
# Get the end point of this node.
zveto5_end = zveto5_center + dzveto5
# Get the starting point of the first tracking station.
ztr1_start = fGeo.GetTopVolume().GetNode('Tr1_1').GetMatrix().GetTranslation()[2] - fGeo.GetTopVolume().GetNode('Tr1_1').GetVolume().GetShape().GetDZ()
In [21]:
# Reconstructed candidates are places in the Particles array.
# In some events this array can be empty.
t.Particles
t.Particles[0]
---------------------------------------------------------------------------
IndexError                                Traceback (most recent call last)
<ipython-input-21-ea53e38b6172> in <module>()
      1 t.Particles
----> 2 t.Particles[0]

IndexError: index out of range
In [22]:
# Let's find the events with reconstructed particles.
for i,event in enumerate(t):
    try:
        p0 = event.Particles[0]
        print 'I found a particle in event', i
    except:
        continue
I found a particle in event 7
I found a particle in event 9
I found a particle in event 14
I found a particle in event 15
I found a particle in event 26
I found a particle in event 34
I found a particle in event 36
I found a particle in event 37
I found a particle in event 38
I found a particle in event 39
I found a particle in event 41
I found a particle in event 50
I found a particle in event 53
I found a particle in event 60
I found a particle in event 62
I found a particle in event 71
I found a particle in event 85
I found a particle in event 91
I found a particle in event 98
I found a particle in event 99

In [23]:
# These are ROOT TParticles. Here are all the methods you can use with them.
for p in t.Particles:
    print p
dir(t.Particles[0])
<ROOT.TParticle object ("N2") at 0xcb36d80>

Out[23]:
['AbstractMethod',
 'AppendPad',
 'Beauty',
 'Browse',
 'Charm',
 'Class',
 'ClassName',
 'Class_Name',
 'Class_Version',
 'Clear',
 'Clone',
 'Compare',
 'Copy',
 'DeclFileLine',
 'DeclFileName',
 'Delete',
 'Dictionary',
 'DistancetoLine',
 'DistancetoPrimitive',
 'Draw',
 'DrawClass',
 'DrawClone',
 'Dump',
 'Energy',
 'Error',
 'Eta',
 'Execute',
 'ExecuteEvent',
 'Fatal',
 'FindObject',
 'GetCalcMass',
 'GetDaughter',
 'GetDrawOption',
 'GetDtorOnly',
 'GetFirstDaughter',
 'GetFirstMother',
 'GetIconName',
 'GetLastDaughter',
 'GetLineColor',
 'GetLineStyle',
 'GetLineWidth',
 'GetMass',
 'GetMother',
 'GetNDaughters',
 'GetName',
 'GetObjectInfo',
 'GetObjectStat',
 'GetOption',
 'GetPDG',
 'GetPdgCode',
 'GetPolarisation',
 'GetSecondMother',
 'GetStatusCode',
 'GetTitle',
 'GetUniqueID',
 'GetWeight',
 'HandleTimer',
 'Hash',
 'ImplFileLine',
 'ImplFileName',
 'Info',
 'InheritsFrom',
 'Inspect',
 'InvertBit',
 'IsA',
 'IsEqual',
 'IsFolder',
 'IsOnHeap',
 'IsPrimary',
 'IsSortable',
 'IsZombie',
 'MayNotUse',
 'Modify',
 'Momentum',
 'Notify',
 'Obsolete',
 'P',
 'Paint',
 'Phi',
 'Pop',
 'Print',
 'ProductionVertex',
 'Pt',
 'Px',
 'Py',
 'Pz',
 'R',
 'Read',
 'RecursiveRemove',
 'ResetAttLine',
 'ResetBit',
 'Rho',
 'SaveAs',
 'SaveLineAttributes',
 'SavePrimitive',
 'SetBit',
 'SetCalcMass',
 'SetDaughter',
 'SetDrawOption',
 'SetDtorOnly',
 'SetFirstDaughter',
 'SetFirstMother',
 'SetLastDaughter',
 'SetLastMother',
 'SetLineAttributes',
 'SetLineColor',
 'SetLineColorAlpha',
 'SetLineStyle',
 'SetLineWidth',
 'SetMomentum',
 'SetMother',
 'SetObjectStat',
 'SetPdgCode',
 'SetPolarisation',
 'SetProductionVertex',
 'SetStatusCode',
 'SetUniqueID',
 'SetWeight',
 'ShowMembers',
 'Sizeof3D',
 'Strangeness',
 'Streamer',
 'StreamerNVirtual',
 'SysError',
 'T',
 'TestBit',
 'TestBits',
 'Theta',
 'UseCurrentStyle',
 'Vx',
 'Vy',
 'Vz',
 'Warning',
 'Write',
 'Y',
 '_TObject__DoError',
 '_TObject__MakeZombie',
 '__add__',
 '__assign__',
 '__bool__',
 '__class__',
 '__cmp__',
 '__contains__',
 '__delattr__',
 '__dict__',
 '__div__',
 '__doc__',
 '__eq__',
 '__format__',
 '__ge__',
 '__getattribute__',
 '__gt__',
 '__hash__',
 '__init__',
 '__le__',
 '__lt__',
 '__module__',
 '__mul__',
 '__ne__',
 '__new__',
 '__nonzero__',
 '__radd__',
 '__rdiv__',
 '__reduce__',
 '__reduce_ex__',
 '__repr__',
 '__rmul__',
 '__rsub__',
 '__setattr__',
 '__sizeof__',
 '__str__',
 '__sub__',
 '__subclasshook__',
 '__weakref__',
 'kBitMask',
 'kCanDelete',
 'kCannotPick',
 'kHasUUID',
 'kInvalidObject',
 'kIsOnHeap',
 'kIsReferenced',
 'kMustCleanup',
 'kNoContextMenu',
 'kNotDeleted',
 'kObjInCanvas',
 'kOverwrite',
 'kSingleKey',
 'kWriteDelete',
 'kZombie',
 'ls',
 'operator delete',
 'operator delete[]',
 'operator new',
 'operator new[]']
In [24]:
# Let us take an event with one candidate.
t.GetEntry(98)
p0 = t.Particles[0]
In [25]:
# Closer look to the ROOT TParticle documentation
help(p0)
Help on TParticle in module __main__ object:

class TParticle(ROOT.TObject, ROOT.TAttLine, TAtt3D)
 |  Method resolution order:
 |      TParticle
 |      ROOT.TObject
 |      ROOT.TAttLine
 |      TAtt3D
 |      ROOT.ObjectProxy
 |      __builtin__.object
 |  
 |  Methods defined here:
 |  
 |  Beauty(self)
 |      Int_t TParticle::Beauty()
 |  
 |  Charm(self)
 |      Int_t TParticle::Charm()
 |  
 |  Class(self)
 |      static TClass* TParticle::Class()
 |  
 |  Class_Name(self)
 |      static const char* TParticle::Class_Name()
 |  
 |  Class_Version(self)
 |      static Version_t TParticle::Class_Version()
 |  
 |  DeclFileLine(self)
 |      static int TParticle::DeclFileLine()
 |  
 |  DeclFileName(self)
 |      static const char* TParticle::DeclFileName()
 |  
 |  Dictionary(self)
 |      static void TParticle::Dictionary()
 |  
 |  DistancetoPrimitive(self, Int_t px, Int_t py)
 |      Int_t TParticle::DistancetoPrimitive(Int_t px, Int_t py)
 |  
 |  Energy(self)
 |      Double_t TParticle::Energy()
 |  
 |  Eta(self)
 |      Double_t TParticle::Eta()
 |  
 |  ExecuteEvent(self, Int_t event, Int_t px, Int_t py)
 |      void TParticle::ExecuteEvent(Int_t event, Int_t px, Int_t py)
 |  
 |  GetCalcMass(self)
 |      Double_t TParticle::GetCalcMass()
 |  
 |  GetDaughter(self, Int_t i)
 |      Int_t TParticle::GetDaughter(Int_t i)
 |  
 |  GetFirstDaughter(self)
 |      Int_t TParticle::GetFirstDaughter()
 |  
 |  GetFirstMother(self)
 |      Int_t TParticle::GetFirstMother()
 |  
 |  GetLastDaughter(self)
 |      Int_t TParticle::GetLastDaughter()
 |  
 |  GetMass(self)
 |      Double_t TParticle::GetMass()
 |  
 |  GetMother(self, Int_t i)
 |      Int_t TParticle::GetMother(Int_t i)
 |  
 |  GetNDaughters(self)
 |      Int_t TParticle::GetNDaughters()
 |  
 |  GetName(self)
 |      const char* TParticle::GetName()
 |  
 |  GetPDG(self, Int_t mode=0)
 |      TParticlePDG* TParticle::GetPDG(Int_t mode = 0)
 |  
 |  GetPdgCode(self)
 |      Int_t TParticle::GetPdgCode()
 |  
 |  GetPolarisation(self, TVector3& v)
 |      void TParticle::GetPolarisation(TVector3& v)
 |  
 |  GetSecondMother(self)
 |      Int_t TParticle::GetSecondMother()
 |  
 |  GetStatusCode(self)
 |      Int_t TParticle::GetStatusCode()
 |  
 |  GetTitle(self)
 |      const char* TParticle::GetTitle()
 |  
 |  GetWeight(self)
 |      Float_t TParticle::GetWeight()
 |  
 |  ImplFileLine(self)
 |      static int TParticle::ImplFileLine()
 |  
 |  ImplFileName(self)
 |      static const char* TParticle::ImplFileName()
 |  
 |  IsA(self)
 |      TClass* TParticle::IsA()
 |  
 |  IsPrimary(self)
 |      Bool_t TParticle::IsPrimary()
 |  
 |  Momentum(self, TLorentzVector& v)
 |      void TParticle::Momentum(TLorentzVector& v)
 |  
 |  P(self)
 |      Double_t TParticle::P()
 |  
 |  Paint(self, Option_t* option='')
 |      void TParticle::Paint(Option_t* option = "")
 |  
 |  Phi(self)
 |      Double_t TParticle::Phi()
 |  
 |  Print(self, Option_t* option='')
 |      void TParticle::Print(Option_t* option = "")
 |  
 |  ProductionVertex(self, TLorentzVector& v)
 |      void TParticle::ProductionVertex(TLorentzVector& v)
 |  
 |  Pt(self)
 |      Double_t TParticle::Pt()
 |  
 |  Px(self)
 |      Double_t TParticle::Px()
 |  
 |  Py(self)
 |      Double_t TParticle::Py()
 |  
 |  Pz(self)
 |      Double_t TParticle::Pz()
 |  
 |  R(self)
 |      Double_t TParticle::R()
 |  
 |  Rho(self)
 |      Double_t TParticle::Rho()
 |  
 |  SetCalcMass(self, Double_t mass)
 |      void TParticle::SetCalcMass(Double_t mass)
 |  
 |  SetDaughter(self, int i, int code)
 |      void TParticle::SetDaughter(int i, int code)
 |  
 |  SetFirstDaughter(self, int code)
 |      void TParticle::SetFirstDaughter(int code)
 |  
 |  SetFirstMother(self, int code)
 |      void TParticle::SetFirstMother(int code)
 |  
 |  SetLastDaughter(self, int code)
 |      void TParticle::SetLastDaughter(int code)
 |  
 |  SetLastMother(self, int code)
 |      void TParticle::SetLastMother(int code)
 |  
 |  SetMomentum(self, Double_t px, Double_t py, Double_t pz, Double_t e)
 |      void TParticle::SetMomentum(Double_t px, Double_t py, Double_t pz, Double_t e)
 |      void TParticle::SetMomentum(const TLorentzVector& p)
 |  
 |  SetMother(self, int i, int code)
 |      void TParticle::SetMother(int i, int code)
 |  
 |  SetPdgCode(self, Int_t pdg)
 |      void TParticle::SetPdgCode(Int_t pdg)
 |  
 |  SetPolarisation(self, Double_t polx, Double_t poly, Double_t polz)
 |      void TParticle::SetPolarisation(Double_t polx, Double_t poly, Double_t polz)
 |      void TParticle::SetPolarisation(const TVector3& v)
 |  
 |  SetProductionVertex(self, Double_t vx, Double_t vy, Double_t vz, Double_t t)
 |      void TParticle::SetProductionVertex(Double_t vx, Double_t vy, Double_t vz, Double_t t)
 |      void TParticle::SetProductionVertex(const TLorentzVector& v)
 |  
 |  SetStatusCode(self, int status)
 |      void TParticle::SetStatusCode(int status)
 |  
 |  SetWeight(self, Float_t weight=1)
 |      void TParticle::SetWeight(Float_t weight = 1)
 |  
 |  ShowMembers(self, TMemberInspector&)
 |      void TParticle::ShowMembers(TMemberInspector&)
 |  
 |  Sizeof3D(self)
 |      void TParticle::Sizeof3D()
 |  
 |  Strangeness(self)
 |      Int_t TParticle::Strangeness()
 |  
 |  Streamer(self, TBuffer&)
 |      void TParticle::Streamer(TBuffer&)
 |  
 |  StreamerNVirtual(self, TBuffer& ClassDef_StreamerNVirtual_b)
 |      void TParticle::StreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
 |  
 |  T(self)
 |      Double_t TParticle::T()
 |  
 |  Theta(self)
 |      Double_t TParticle::Theta()
 |  
 |  Vx(self)
 |      Double_t TParticle::Vx()
 |  
 |  Vy(self)
 |      Double_t TParticle::Vy()
 |  
 |  Vz(self)
 |      Double_t TParticle::Vz()
 |  
 |  Y(self)
 |      Double_t TParticle::Y()
 |  
 |  __assign__(self, const TParticle&)
 |      TParticle& TParticle::operator=(const TParticle&)
 |  
 |  __init__(self, Int_t pdg, Int_t status, Int_t mother1, Int_t mother2, Int_t daughter1, Int_t daughter2, Double_t px, Double_t py, Double_t pz, Double_t etot, Double_t vx, Double_t vy, Double_t vz, Double_t time)
 |      TParticle::TParticle()
 |      TParticle::TParticle(Int_t pdg, Int_t status, Int_t mother1, Int_t mother2, Int_t daughter1, Int_t daughter2, Double_t px, Double_t py, Double_t pz, Double_t etot, Double_t vx, Double_t vy, Double_t vz, Double_t time)
 |      TParticle::TParticle(Int_t pdg, Int_t status, Int_t mother1, Int_t mother2, Int_t daughter1, Int_t daughter2, const TLorentzVector& p, const TLorentzVector& v)
 |      TParticle::TParticle(const TParticle& part)
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.TObject:
 |  
 |  AbstractMethod(self, const char* method) from ROOT.TObject
 |      void TObject::AbstractMethod(const char* method)
 |  
 |  AppendPad(self, Option_t* option='') from ROOT.TObject
 |      void TObject::AppendPad(Option_t* option = "")
 |  
 |  Browse(self, TBrowser* b) from ROOT.TObject
 |      void TObject::Browse(TBrowser* b)
 |  
 |  ClassName(self) from ROOT.TObject
 |      const char* TObject::ClassName()
 |  
 |  Clear(self, Option_t*='') from ROOT.TObject
 |      void TObject::Clear(Option_t* = "")
 |  
 |  Clone(self, const char* newname='') from ROOT.TObject
 |      TObject* TObject::Clone(const char* newname = "")
 |  
 |  Compare(self, const TObject* obj) from ROOT.TObject
 |      Int_t TObject::Compare(const TObject* obj)
 |  
 |  Copy(self, TObject& object) from ROOT.TObject
 |      void TObject::Copy(TObject& object)
 |  
 |  Delete(self, Option_t* option='') from ROOT.TObject
 |      void TObject::Delete(Option_t* option = "")
 |  
 |  Draw(self, Option_t* option='') from ROOT.TObject
 |      void TObject::Draw(Option_t* option = "")
 |  
 |  DrawClass(self) from ROOT.TObject
 |      void TObject::DrawClass()
 |  
 |  DrawClone(self, Option_t* option='') from ROOT.TObject
 |      TObject* TObject::DrawClone(Option_t* option = "")
 |  
 |  Dump(self) from ROOT.TObject
 |      void TObject::Dump()
 |  
 |  Error(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Error(const char* method, const char* msgfmt)
 |  
 |  Execute(self, const char* method, const char* params, Int_t* error=0) from ROOT.TObject
 |      void TObject::Execute(const char* method, const char* params, Int_t* error = 0)
 |      void TObject::Execute(TMethod* method, TObjArray* params, Int_t* error = 0)
 |  
 |  Fatal(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Fatal(const char* method, const char* msgfmt)
 |  
 |  FindObject(self, const char* name) from ROOT.TObject
 |      TObject* TObject::FindObject(const char* name)
 |      TObject* TObject::FindObject(const TObject* obj)
 |  
 |  GetDrawOption(self) from ROOT.TObject
 |      Option_t* TObject::GetDrawOption()
 |  
 |  GetDtorOnly(self) from ROOT.TObject
 |      static Long_t TObject::GetDtorOnly()
 |  
 |  GetIconName(self) from ROOT.TObject
 |      const char* TObject::GetIconName()
 |  
 |  GetObjectInfo(self, Int_t px, Int_t py) from ROOT.TObject
 |      char* TObject::GetObjectInfo(Int_t px, Int_t py)
 |  
 |  GetObjectStat(self) from ROOT.TObject
 |      static Bool_t TObject::GetObjectStat()
 |  
 |  GetOption(self) from ROOT.TObject
 |      Option_t* TObject::GetOption()
 |  
 |  GetUniqueID(self) from ROOT.TObject
 |      UInt_t TObject::GetUniqueID()
 |  
 |  HandleTimer(self, TTimer* timer) from ROOT.TObject
 |      Bool_t TObject::HandleTimer(TTimer* timer)
 |  
 |  Hash(self) from ROOT.TObject
 |      ULong_t TObject::Hash()
 |  
 |  Info(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Info(const char* method, const char* msgfmt)
 |  
 |  InheritsFrom(self, const char* classname) from ROOT.TObject
 |      Bool_t TObject::InheritsFrom(const char* classname)
 |      Bool_t TObject::InheritsFrom(const TClass* cl)
 |  
 |  Inspect(self) from ROOT.TObject
 |      void TObject::Inspect()
 |  
 |  InvertBit(self, UInt_t f) from ROOT.TObject
 |      void TObject::InvertBit(UInt_t f)
 |  
 |  IsEqual(self, const TObject* obj) from ROOT.TObject
 |      Bool_t TObject::IsEqual(const TObject* obj)
 |  
 |  IsFolder(self) from ROOT.TObject
 |      Bool_t TObject::IsFolder()
 |  
 |  IsOnHeap(self) from ROOT.TObject
 |      Bool_t TObject::IsOnHeap()
 |  
 |  IsSortable(self) from ROOT.TObject
 |      Bool_t TObject::IsSortable()
 |  
 |  IsZombie(self) from ROOT.TObject
 |      Bool_t TObject::IsZombie()
 |  
 |  MayNotUse(self, const char* method) from ROOT.TObject
 |      void TObject::MayNotUse(const char* method)
 |  
 |  Notify(self) from ROOT.TObject
 |      Bool_t TObject::Notify()
 |  
 |  Obsolete(self, const char* method, const char* asOfVers, const char* removedFromVers) from ROOT.TObject
 |      void TObject::Obsolete(const char* method, const char* asOfVers, const char* removedFromVers)
 |  
 |  Pop(self) from ROOT.TObject
 |      void TObject::Pop()
 |  
 |  Read(self, const char* name) from ROOT.TObject
 |      Int_t TObject::Read(const char* name)
 |  
 |  RecursiveRemove(self, TObject* obj) from ROOT.TObject
 |      void TObject::RecursiveRemove(TObject* obj)
 |  
 |  ResetBit(self, UInt_t f) from ROOT.TObject
 |      void TObject::ResetBit(UInt_t f)
 |  
 |  SaveAs(self, const char* filename='', Option_t* option='') from ROOT.TObject
 |      void TObject::SaveAs(const char* filename = "", Option_t* option = "")
 |  
 |  SavePrimitive(self, basic_ostream<char,char_traits<char> >& out, Option_t* option='') from ROOT.TObject
 |      void TObject::SavePrimitive(basic_ostream<char,char_traits<char> >& out, Option_t* option = "")
 |  
 |  SetBit(self, UInt_t f, Bool_t set) from ROOT.TObject
 |      void TObject::SetBit(UInt_t f, Bool_t set)
 |      void TObject::SetBit(UInt_t f)
 |  
 |  SetDrawOption(self, Option_t* option='') from ROOT.TObject
 |      void TObject::SetDrawOption(Option_t* option = "")
 |  
 |  SetDtorOnly(self, void* obj) from ROOT.TObject
 |      static void TObject::SetDtorOnly(void* obj)
 |  
 |  SetObjectStat(self, Bool_t stat) from ROOT.TObject
 |      static void TObject::SetObjectStat(Bool_t stat)
 |  
 |  SetUniqueID(self, UInt_t uid) from ROOT.TObject
 |      void TObject::SetUniqueID(UInt_t uid)
 |  
 |  SysError(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::SysError(const char* method, const char* msgfmt)
 |  
 |  TestBit(self, UInt_t f) from ROOT.TObject
 |      Bool_t TObject::TestBit(UInt_t f)
 |  
 |  TestBits(self, UInt_t f) from ROOT.TObject
 |      Int_t TObject::TestBits(UInt_t f)
 |  
 |  UseCurrentStyle(self) from ROOT.TObject
 |      void TObject::UseCurrentStyle()
 |  
 |  Warning(self, const char* method, const char* msgfmt) from ROOT.TObject
 |      void TObject::Warning(const char* method, const char* msgfmt)
 |  
 |  Write(self, const char* name=0, Int_t option=0, Int_t bufsize=0) from ROOT.TObject
 |      Int_t TObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
 |      Int_t TObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
 |  
 |  __cmp__(...)
 |  
 |  __contains__(...)
 |  
 |  __eq__(...)
 |  
 |  __ne__(...)
 |  
 |  ls(self, Option_t* option='') from ROOT.TObject
 |      void TObject::ls(Option_t* option = "")
 |  
 |  operator delete(self, void* ptr, void* vp) from ROOT.TObject
 |      static void TObject::operator delete(void* ptr)
 |      static void TObject::operator delete(void* ptr, void* vp)
 |  
 |  operator delete[](self, void* ptr, void* vp) from ROOT.TObject
 |      static void TObject::operator delete[](void* ptr)
 |      static void TObject::operator delete[](void* ptr, void* vp)
 |  
 |  operator new(self, size_t sz, void* vp) from ROOT.TObject
 |      void* TObject::operator new(size_t sz)
 |      void* TObject::operator new(size_t sz, void* vp)
 |  
 |  operator new[](self, size_t sz, void* vp) from ROOT.TObject
 |      void* TObject::operator new[](size_t sz)
 |      void* TObject::operator new[](size_t sz, void* vp)
 |  
 |  ----------------------------------------------------------------------
 |  Data descriptors inherited from ROOT.TObject:
 |  
 |  __dict__
 |      dictionary for instance variables (if defined)
 |  
 |  __weakref__
 |      list of weak references to the object (if defined)
 |  
 |  ----------------------------------------------------------------------
 |  Data and other attributes inherited from ROOT.TObject:
 |  
 |  kBitMask = 16777215
 |  
 |  kCanDelete = 1
 |  
 |  kCannotPick = 64
 |  
 |  kHasUUID = 32
 |  
 |  kInvalidObject = 8192
 |  
 |  kIsOnHeap = 16777216
 |  
 |  kIsReferenced = 16
 |  
 |  kMustCleanup = 8
 |  
 |  kNoContextMenu = 256
 |  
 |  kNotDeleted = 33554432
 |  
 |  kObjInCanvas = 8
 |  
 |  kOverwrite = 2
 |  
 |  kSingleKey = 1
 |  
 |  kWriteDelete = 4
 |  
 |  kZombie = 67108864
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.TAttLine:
 |  
 |  DistancetoLine(self, Int_t px, Int_t py, Double_t xp1, Double_t yp1, Double_t xp2, Double_t yp2) from ROOT.TAttLine
 |      Int_t TAttLine::DistancetoLine(Int_t px, Int_t py, Double_t xp1, Double_t yp1, Double_t xp2, Double_t yp2)
 |  
 |  GetLineColor(self) from ROOT.TAttLine
 |      Color_t TAttLine::GetLineColor()
 |  
 |  GetLineStyle(self) from ROOT.TAttLine
 |      Style_t TAttLine::GetLineStyle()
 |  
 |  GetLineWidth(self) from ROOT.TAttLine
 |      Width_t TAttLine::GetLineWidth()
 |  
 |  Modify(self) from ROOT.TAttLine
 |      void TAttLine::Modify()
 |  
 |  ResetAttLine(self, Option_t* option='') from ROOT.TAttLine
 |      void TAttLine::ResetAttLine(Option_t* option = "")
 |  
 |  SaveLineAttributes(self, basic_ostream<char,char_traits<char> >& out, const char* name, Int_t coldef=1, Int_t stydef=1, Int_t widdef=1) from ROOT.TAttLine
 |      void TAttLine::SaveLineAttributes(basic_ostream<char,char_traits<char> >& out, const char* name, Int_t coldef = 1, Int_t stydef = 1, Int_t widdef = 1)
 |  
 |  SetLineAttributes(self) from ROOT.TAttLine
 |      void TAttLine::SetLineAttributes()
 |  
 |  SetLineColor(self, Color_t lcolor) from ROOT.TAttLine
 |      void TAttLine::SetLineColor(Color_t lcolor)
 |  
 |  SetLineColorAlpha(self, Color_t lcolor, Float_t lalpha) from ROOT.TAttLine
 |      void TAttLine::SetLineColorAlpha(Color_t lcolor, Float_t lalpha)
 |  
 |  SetLineStyle(self, Style_t lstyle) from ROOT.TAttLine
 |      void TAttLine::SetLineStyle(Style_t lstyle)
 |  
 |  SetLineWidth(self, Width_t lwidth) from ROOT.TAttLine
 |      void TAttLine::SetLineWidth(Width_t lwidth)
 |  
 |  ----------------------------------------------------------------------
 |  Methods inherited from ROOT.ObjectProxy:
 |  
 |  __add__(...)
 |      x.__add__(y) <==> x+y
 |  
 |  __bool__(...)
 |  
 |  __div__(...)
 |      x.__div__(y) <==> x/y
 |  
 |  __ge__(...)
 |      x.__ge__(y) <==> x>=y
 |  
 |  __gt__(...)
 |      x.__gt__(y) <==> x>y
 |  
 |  __le__(...)
 |      x.__le__(y) <==> x<=y
 |  
 |  __lt__(...)
 |      x.__lt__(y) <==> x<y
 |  
 |  __mul__(...)
 |      x.__mul__(y) <==> x*y
 |  
 |  __nonzero__(...)
 |  
 |  __radd__(...)
 |      x.__radd__(y) <==> y+x
 |  
 |  __rdiv__(...)
 |      x.__rdiv__(y) <==> y/x
 |  
 |  __reduce__(...)
 |  
 |  __repr__(...)
 |      x.__repr__() <==> repr(x)
 |  
 |  __rmul__(...)
 |      x.__rmul__(y) <==> y*x
 |  
 |  __rsub__(...)
 |      x.__rsub__(y) <==> y-x
 |  
 |  __sub__(...)
 |      x.__sub__(y) <==> x-y
 |  
 |  ----------------------------------------------------------------------
 |  Data and other attributes inherited from ROOT.ObjectProxy:
 |  
 |  __new__ = <built-in method __new__ of ROOT.PyRootType object>
 |      T.__new__(S, ...) -> a new object with type S, a subtype of T


In [26]:
# The simples analysis ever. Put selections in TTree::Draw.
# Here's how you do it in pyroot.
t.Draw("Particles.fVz", "")
t.Draw("Particles.fVz", "Particles.fVz<0")
t.Draw("Particles.fVz", "Particles.fVz>%s && Particles.fVz<%s"%(zveto5_end, ztr1_start))
Out[26]:
21L
In [27]:
# Let's start to do things in loops. E.G.: find the reconstructed vertices.
for event in t:
    for candidate in event.Particles:
        vtx = r.TLorentzVector()
        candidate.ProductionVertex(vtx)
        print "vertex:", vtx.X(), vtx.Y(), vtx.Z(), vtx.T()
vertex: -34.1353660525 101.253487404 2334.33488573 0.313047184129
vertex: 114.551541144 -143.387887678 2628.57601468 16.3379271866
vertex: 111.361009569 -146.593353991 2296.66518145 8.00779206009
vertex: 126.3541342 -146.079844991 2594.25561827 0.0684620240403
vertex: 126.305301325 -146.089403484 2594.4170677 0.0550978456631
vertex: -8.99156556423 124.39495533 -1691.61605198 0.57347611328
vertex: 60.9643880706 -210.665375627 -675.272949893 0.0550266433574
vertex: -41.7707950578 30.7375435303 1881.05927462 0.273677956344
vertex: -131.901364057 141.854154678 898.954546289 0.50887759781
vertex: 18.7553829227 -39.5128458767 1953.0398594 2.01671603084
vertex: -35.1481367213 93.1259452578 -1065.51400709 0.459928656441
vertex: 157.952798423 142.024760286 2372.08006999 20.1351966889
vertex: -180.585668633 77.9651632787 1858.63971671 0.421969374874
vertex: -102.246626687 -68.2069633716 -880.910974436 0.827645380593
vertex: 61.9443824766 47.0989463604 -1522.49593534 0.375078319848
vertex: 22.5934831798 0.556577333333 -820.447807401 0.0674950453175
vertex: 46.371858293 -96.1022501404 -439.156267684 0.676162627526
vertex: 3.45703367781 29.2206331138 -2486.57131982 0.0555349184644
vertex: -39.7338228897 -213.302469085 -17.8368662016 0.428616369111
vertex: 19.7920246958 -235.50873585 -1024.93246371 0.0189837563539
vertex: -67.4618473196 -28.7943541674 462.000297503 0.194734080379
vertex: 142.894941973 -59.1565393643 172.127096724 0.553946272779
vertex: 31.5993851039 121.719061476 2064.71341991 0.0781145947893

In [28]:
# The fourth component of the reconstructed vertex is actually the DOCA, that is made persistent this way.
h_doca = r.TH1F('h_doca', 'h_doca', 100, 0., 103.)
In [29]:
# Retrieve also the reconstructed momentum
for event in t:
    for candidate in event.Particles:
        vtx = r.TLorentzVector()
        candidate.ProductionVertex(vtx)
        print "vertex:", vtx.X(), vtx.Y(), vtx.Z(), vtx.T()
        h_doca.Fill(vtx.T())
        mom = r.TLorentzVector()
        candidate.Momentum(mom)
        print "momentum:", mom.X(), mom.Y(), mom.Z(), mom.T()

# Draw the DOCA
h_doca.Draw()
vertex: -34.1353660525 101.253487404 2334.33488573 0.313047184129
momentum: -0.109912174092 0.319334048877 35.4379088445 35.4536268487
vertex: 114.551541144 -143.387887678 2628.57601468 16.3379271866
momentum: -0.43823545764 -0.0404361722514 32.1235885664 32.1911412792
vertex: 111.361009569 -146.593353991 2296.66518145 8.00779206009
momentum: 0.797793083413 -0.123210070506 52.2479618392 52.2747841496
vertex: 126.3541342 -146.079844991 2594.25561827 0.0684620240403
momentum: -0.0641217791079 0.0361776523825 14.1977744222 14.2685860286
vertex: 126.305301325 -146.089403484 2594.4170677 0.0550978456631
momentum: 1.1719183061 -0.0465942909559 34.3203398816 34.3515786624
vertex: -8.99156556423 124.39495533 -1691.61605198 0.57347611328
momentum: -0.0547348069666 0.671682814873 38.7947464921 38.8133698451
vertex: 60.9643880706 -210.665375627 -675.272949893 0.0550266433574
momentum: 0.281964977243 -0.979970327465 38.6481173522 38.6744883466
vertex: -41.7707950578 30.7375435303 1881.05927462 0.273677956344
momentum: -0.0767453674971 0.0566993045415 19.1264527276 19.1526877731
vertex: -131.901364057 141.854154678 898.954546289 0.50887759781
momentum: -0.618579730539 0.656660800484 45.5482151575 45.5679453591
vertex: 18.7553829227 -39.5128458767 1953.0398594 2.01671603084
momentum: 0.0509255172384 -0.0833350418266 9.24712816799 9.29481755316
vertex: -35.1481367213 93.1259452578 -1065.51400709 0.459928656441
momentum: -0.281054797604 0.762307472997 64.6237063283 64.6366424005
vertex: 157.952798423 142.024760286 2372.08006999 20.1351966889
momentum: 0.0575801218167 0.919749180348 31.0345134258 31.0832538576
vertex: -180.585668633 77.9651632787 1858.63971671 0.421969374874
momentum: -0.389992659201 0.167612864016 23.285640001 23.31117646
vertex: -102.246626687 -68.2069633716 -880.910974436 0.827645380593
momentum: -0.831908431795 -0.551745233906 65.4896131887 65.5048135674
vertex: 61.9443824766 47.0989463604 -1522.49593534 0.375078319848
momentum: 0.485092601424 0.37215922277 57.276173388 57.2881131079
vertex: 22.5934831798 0.556577333333 -820.447807401 0.0674950453175
momentum: 0.296762068267 0.0103048007352 109.931152363 109.936168158
vertex: 46.371858293 -96.1022501404 -439.156267684 0.676162627526
momentum: 0.272674269972 -0.572290180521 50.8687067432 50.8825052495
vertex: 3.45703367781 29.2206331138 -2486.57131982 0.0555349184644
momentum: 0.0279264432495 0.199433622165 44.6071805447 44.6186889742
vertex: -39.7338228897 -213.302469085 -17.8368662016 0.428616369111
momentum: -0.0901573711553 -0.505651127738 21.0368228737 21.0669267104
vertex: 19.7920246958 -235.50873585 -1024.93246371 0.0189837563539
momentum: 0.0872157756732 -1.0210201753 34.2199096735 34.2500062649
vertex: -67.4618473196 -28.7943541674 462.000297503 0.194734080379
momentum: -0.264625064224 -0.11642314403 37.6202163388 37.6346121315
vertex: 142.894941973 -59.1565393643 172.127096724 0.553946272779
momentum: 0.805766028961 -0.324474694182 50.0742349756 50.0918202207
vertex: 31.5993851039 121.719061476 2064.71341991 0.0781145947893
momentum: 0.0816767812429 0.304768005486 27.7151723319 27.7350777951

In [30]:
# For some specific applications (use at your own risk), or for when you do not have a geometry file,
# you can retrieve geometrical positions using this script from FairShip.
from ShipGeoConfig import ConfigRegistry
ShipGeo = ConfigRegistry.loadpy("$FAIRSHIP/geometry/geometry_config.py", Yheight = 10.)
dir(ShipGeo)
Out[30]:
['Bfield',
 'Chamber1',
 'Chamber2',
 'Chamber3',
 'Chamber4',
 'Chamber5',
 'Chamber6',
 'HcalOption',
 'Muon',
 'MuonFilter0',
 'MuonFilter1',
 'MuonFilter2',
 'MuonStation0',
 'MuonStation1',
 'MuonStation2',
 'MuonStation3',
 'NuTauTarget',
 'TrackStation1',
 'TrackStation2',
 'TrackStation3',
 'TrackStation4',
 'Yheight',
 '__class__',
 '__cmp__',
 '__contains__',
 '__delattr__',
 '__delitem__',
 '__dict__',
 '__doc__',
 '__eq__',
 '__format__',
 '__ge__',
 '__getattribute__',
 '__getitem__',
 '__gt__',
 '__hash__',
 '__init__',
 '__iter__',
 '__le__',
 '__len__',
 '__lt__',
 '__module__',
 '__ne__',
 '__new__',
 '__reduce__',
 '__reduce_ex__',
 '__repr__',
 '__setattr__',
 '__setitem__',
 '__sizeof__',
 '__str__',
 '__subclasshook__',
 '__weakref__',
 'chambers',
 'clear',
 'clone',
 'copy',
 'decayVolume',
 'dump',
 'dumps',
 'ecal',
 'fromkeys',
 'get',
 'hadronAbsorber',
 'has_key',
 'hcal',
 'items',
 'iteritems',
 'iterkeys',
 'itervalues',
 'keys',
 'load',
 'loads',
 'muShield',
 'muShieldDesign',
 'pop',
 'popitem',
 'scintillator',
 'setdefault',
 'straw',
 'strawDesign',
 'strawtubes',
 'target',
 'targetOpt',
 'tauMS',
 'update',
 'values',
 'vetoStation',
 'z']
In [31]:
# Let's do something serious and compute the impact parameter to the target.
def IPtoTarget(vtx, mom):
    p = mom.P()
    target = r.TVector3(0., 0., ShipGeo.target.z0)
    delta = 0.
    for i in range(3):
        delta += (target(i) - vtx(i)) * mom(i)/p
    ip = 0.
    for i in range(3):
        ip += (target(i) - vtx(i) - delta*mom(i)/p)**2.
    return r.TMath.Sqrt(ip)
In [32]:
# Let's look at the IPs in order to define a selection.
for event in t:
        for candidate in event.Particles:
                vtx = r.TLorentzVector()
                candidate.ProductionVertex(vtx)
                print "vertex:", vtx.X(), vtx.Y(), vtx.Z(), vtx.T()
                mom = r.TLorentzVector()
                candidate.Momentum(mom)
                print "momentum:", mom.X(), mom.Y(), mom.Z(), mom.T()
                print 'IP:', IPtoTarget(vtx, mom)
vertex: -34.1353660525 101.253487404 2334.33488573 0.313047184129
momentum: -0.109912174092 0.319334048877 35.4379088445 35.4536268487
IP: 0.82301980716
vertex: 114.551541144 -143.387887678 2628.57601468 16.3379271866
momentum: -0.43823545764 -0.0404361722514 32.1235885664 32.1911412792
IP: 301.127242483
vertex: 111.361009569 -146.593353991 2296.66518145 8.00779206009
momentum: 0.797793083413 -0.123210070506 52.2479618392 52.2747841496
IP: 134.282928964
vertex: 126.3541342 -146.079844991 2594.25561827 0.0684620240403
momentum: -0.0641217791079 0.0361776523825 14.1977744222 14.2685860286
IP: 250.197820407
vertex: 126.305301325 -146.089403484 2594.4170677 0.0550978456631
momentum: 1.1719183061 -0.0465942909559 34.3203398816 34.3515786624
IP: 297.12729042
vertex: -8.99156556423 124.39495533 -1691.61605198 0.57347611328
momentum: -0.0547348069666 0.671682814873 38.7947464921 38.8133698451
IP: 1.49957861078
vertex: 60.9643880706 -210.665375627 -675.272949893 0.0550266433574
momentum: 0.281964977243 -0.979970327465 38.6481173522 38.6744883466
IP: 1.62235947922
vertex: -41.7707950578 30.7375435303 1881.05927462 0.273677956344
momentum: -0.0767453674971 0.0566993045415 19.1264527276 19.1526877731
IP: 2.06053608453
vertex: -131.901364057 141.854154678 898.954546289 0.50887759781
momentum: -0.618579730539 0.656660800484 45.5482151575 45.5679453591
IP: 1.55481921548
vertex: 18.7553829227 -39.5128458767 1953.0398594 2.01671603084
momentum: 0.0509255172384 -0.0833350418266 9.24712816799 9.29481755316
IP: 71.5577214577
vertex: -35.1481367213 93.1259452578 -1065.51400709 0.459928656441
momentum: -0.281054797604 0.762307472997 64.6237063283 64.6366424005
IP: 1.03450475787
vertex: 157.952798423 142.024760286 2372.08006999 20.1351966889
momentum: 0.0575801218167 0.919749180348 31.0345134258 31.0832538576
IP: 236.480198973
vertex: -180.585668633 77.9651632787 1858.63971671 0.421969374874
momentum: -0.389992659201 0.167612864016 23.285640001 23.31117646
IP: 0.333290412282
vertex: -102.246626687 -68.2069633716 -880.910974436 0.827645380593
momentum: -0.831908431795 -0.551745233906 65.4896131887 65.5048135674
IP: 0.420939191782
vertex: 61.9443824766 47.0989463604 -1522.49593534 0.375078319848
momentum: 0.485092601424 0.37215922277 57.276173388 57.2881131079
IP: 1.27037757465
vertex: 22.5934831798 0.556577333333 -820.447807401 0.0674950453175
momentum: 0.296762068267 0.0103048007352 109.931152363 109.936168158
IP: 0.73818036972
vertex: 46.371858293 -96.1022501404 -439.156267684 0.676162627526
momentum: 0.272674269972 -0.572290180521 50.8687067432 50.8825052495
IP: 1.06641804446
vertex: 3.45703367781 29.2206331138 -2486.57131982 0.0555349184644
momentum: 0.0279264432495 0.199433622165 44.6071805447 44.6186889742
IP: 0.715746847545
vertex: -39.7338228897 -213.302469085 -17.8368662016 0.428616369111
momentum: -0.0901573711553 -0.505651127738 21.0368228737 21.0669267104
IP: 1.7657426844
vertex: 19.7920246958 -235.50873585 -1024.93246371 0.0189837563539
momentum: 0.0872157756732 -1.0210201753 34.2199096735 34.2500062649
IP: 0.437465591867
vertex: -67.4618473196 -28.7943541674 462.000297503 0.194734080379
momentum: -0.264625064224 -0.11642314403 37.6202163388 37.6346121315
IP: 1.44242400799
vertex: 142.894941973 -59.1565393643 172.127096724 0.553946272779
momentum: 0.805766028961 -0.324474694182 50.0742349756 50.0918202207
IP: 3.52799814676
vertex: 31.5993851039 121.719061476 2064.71341991 0.0781145947893
momentum: 0.0816767812429 0.304768005486 27.7151723319 27.7350777951
IP: 1.16221814961

In [33]:
h_ip = r.TH1F('h_ip', 'h_ip', 100, 0., 2000.)
ips = []
for event in t:
        for candidate in event.Particles:
                vtx = r.TLorentzVector()
                candidate.ProductionVertex(vtx)
                print "vertex:", vtx.X(), vtx.Y(), vtx.Z(), vtx.T()
                mom = r.TLorentzVector()
                candidate.Momentum(mom)
                print "momentum:", mom.X(), mom.Y(), mom.Z(), mom.T()
                print 'IP:', IPtoTarget(vtx, mom)
                h_ip.Fill(IPtoTarget(vtx, mom))
                ips.append(IPtoTarget(vtx, mom))
ips
h_ip.Draw()
vertex: -34.1353660525 101.253487404 2334.33488573 0.313047184129
momentum: -0.109912174092 0.319334048877 35.4379088445 35.4536268487
IP: 0.82301980716
vertex: 114.551541144 -143.387887678 2628.57601468 16.3379271866
momentum: -0.43823545764 -0.0404361722514 32.1235885664 32.1911412792
IP: 301.127242483
vertex: 111.361009569 -146.593353991 2296.66518145 8.00779206009
momentum: 0.797793083413 -0.123210070506 52.2479618392 52.2747841496
IP: 134.282928964
vertex: 126.3541342 -146.079844991 2594.25561827 0.0684620240403
momentum: -0.0641217791079 0.0361776523825 14.1977744222 14.2685860286
IP: 250.197820407
vertex: 126.305301325 -146.089403484 2594.4170677 0.0550978456631
momentum: 1.1719183061 -0.0465942909559 34.3203398816 34.3515786624
IP: 297.12729042
vertex: -8.99156556423 124.39495533 -1691.61605198 0.57347611328
momentum: -0.0547348069666 0.671682814873 38.7947464921 38.8133698451
IP: 1.49957861078
vertex: 60.9643880706 -210.665375627 -675.272949893 0.0550266433574
momentum: 0.281964977243 -0.979970327465 38.6481173522 38.6744883466
IP: 1.62235947922
vertex: -41.7707950578 30.7375435303 1881.05927462 0.273677956344
momentum: -0.0767453674971 0.0566993045415 19.1264527276 19.1526877731
IP: 2.06053608453
vertex: -131.901364057 141.854154678 898.954546289 0.50887759781
momentum: -0.618579730539 0.656660800484 45.5482151575 45.5679453591
IP: 1.55481921548
vertex: 18.7553829227 -39.5128458767 1953.0398594 2.01671603084
momentum: 0.0509255172384 -0.0833350418266 9.24712816799 9.29481755316
IP: 71.5577214577
vertex: -35.1481367213 93.1259452578 -1065.51400709 0.459928656441
momentum: -0.281054797604 0.762307472997 64.6237063283 64.6366424005
IP: 1.03450475787
vertex: 157.952798423 142.024760286 2372.08006999 20.1351966889
momentum: 0.0575801218167 0.919749180348 31.0345134258 31.0832538576
IP: 236.480198973
vertex: -180.585668633 77.9651632787 1858.63971671 0.421969374874
momentum: -0.389992659201 0.167612864016 23.285640001 23.31117646
IP: 0.333290412282
vertex: -102.246626687 -68.2069633716 -880.910974436 0.827645380593
momentum: -0.831908431795 -0.551745233906 65.4896131887 65.5048135674
IP: 0.420939191782
vertex: 61.9443824766 47.0989463604 -1522.49593534 0.375078319848
momentum: 0.485092601424 0.37215922277 57.276173388 57.2881131079
IP: 1.27037757465
vertex: 22.5934831798 0.556577333333 -820.447807401 0.0674950453175
momentum: 0.296762068267 0.0103048007352 109.931152363 109.936168158
IP: 0.73818036972
vertex: 46.371858293 -96.1022501404 -439.156267684 0.676162627526
momentum: 0.272674269972 -0.572290180521 50.8687067432 50.8825052495
IP: 1.06641804446
vertex: 3.45703367781 29.2206331138 -2486.57131982 0.0555349184644
momentum: 0.0279264432495 0.199433622165 44.6071805447 44.6186889742
IP: 0.715746847545
vertex: -39.7338228897 -213.302469085 -17.8368662016 0.428616369111
momentum: -0.0901573711553 -0.505651127738 21.0368228737 21.0669267104
IP: 1.7657426844
vertex: 19.7920246958 -235.50873585 -1024.93246371 0.0189837563539
momentum: 0.0872157756732 -1.0210201753 34.2199096735 34.2500062649
IP: 0.437465591867
vertex: -67.4618473196 -28.7943541674 462.000297503 0.194734080379
momentum: -0.264625064224 -0.11642314403 37.6202163388 37.6346121315
IP: 1.44242400799
vertex: 142.894941973 -59.1565393643 172.127096724 0.553946272779
momentum: 0.805766028961 -0.324474694182 50.0742349756 50.0918202207
IP: 3.52799814676
vertex: 31.5993851039 121.719061476 2064.71341991 0.0781145947893
momentum: 0.0816767812429 0.304768005486 27.7151723319 27.7350777951
IP: 1.16221814961

In [34]:
# Let's prepare a selection based on the fiducial volume.
def in_vessel(vtx):
    x, y, z = vtx.X(), vtx.Y(), vtx.Z()
    if z < zveto5_end: return False
    if z > ShipGeo.TrackStation1.z - 5.: return False
    if (x/245.)**2 + (y/495.)**2 > 1: return False
    return True

total = 0
selected = 0
for event in t:
    for candidate in event.Particles:
        total += 1
        vtx = r.TLorentzVector()
        mom = r.TLorentzVector()
        candidate.ProductionVertex(vtx)
        candidate.Momentum(mom)
        if in_vessel(vtx) and IPtoTarget(vtx, mom) < 250.:
            selected += 1
print total, selected
23 19

In [35]:
# Let's introduce weights.
# This is the recipe to compute the HNL acceptance.
# We produce a lot of HNLs, and we use the weights to model the exponential distribution of their decay position.
total = 0
selected = 0
wtotal = 0.
wselected = 0.
for event in t:
    for candidate in event.Particles:
        total += 1
        wtotal += event.MCTrack[1].GetWeight()
        vtx = r.TLorentzVector()
        mom = r.TLorentzVector()
        candidate.ProductionVertex(vtx)
        candidate.Momentum(mom)
        if in_vessel(vtx) and IPtoTarget(vtx, mom) < 250.:
            selected += 1
            wselected += event.MCTrack[1].GetWeight()
print total, selected
print wtotal/t.GetEntries(), wselected/t.GetEntries()
23 19
7.51578242671e-06 6.76745660712e-06

In [36]:
# But wait, did we match the reconstructed candidate to the true HNL?
def match2MC(event, candidate):
    d1, d2 = candidate.GetDaughter(0), candidate.GetDaughter(1)
    # the fitTrack2MC leave is an array of the same length as FitTracks.
    # it contains the index of the corresponding MCTrack.
    d1_mc, d2_mc = event.fitTrack2MC[d1], event.fitTrack2MC[d2]
    for d in [d1_mc, d2_mc]:
        mum = event.MCTrack[d].GetMotherId()
        if not pdg.GetParticle(event.MCTrack[mum].GetPdgCode()).GetName() == 'N2':
            return False
    return True
In [37]:
total = 0
selected = 0
wtotal = 0.
wselected = 0.
for event in t:
    for candidate in event.Particles:
        if not match2MC(event, candidate): continue
        total += 1
        wtotal += event.MCTrack[1].GetWeight()
        vtx = r.TLorentzVector()
        mom = r.TLorentzVector()
        candidate.ProductionVertex(vtx)
        candidate.Momentum(mom)
        if in_vessel(vtx) and IPtoTarget(vtx, mom) < 250.:
            selected += 1
            wselected += event.MCTrack[1].GetWeight()
print total, selected
print wtotal/t.GetEntries(), wselected/t.GetEntries()
17 16
5.4142179124e-06 5.14913724146e-06

In [38]:
# By the way: reconstructed tracks are here.
t.FitTracks[0]
Out[38]:
<ROOT.genfit::Track object ("genfit::Track") at 0x1092f310>
In [39]:
# How to quickly implement vetoes.
import shipVeto
veto = shipVeto.Task()
total = 0
selected = 0
wtotal = 0.
wselected = 0.
for event in t:
    # veto decisions have weights.
    # They represent the probability, given a certain veto efficiency,
    # that an event passes a VETO decision.
    sbt, sbtw, sbtn = veto.SBT_decision(event)
    print 'SBT: veto decision ', sbt, 'with weight', sbtw
    uvt, uvtw, uvtn = veto.UVT_decision(event)
    print 'UVT: veto decision ', uvt, 'with weight', uvtw
    svt, svtw, svtn = veto.SVT_decision(event)
    print 'SVT: veto decision ', svt, 'with weight', svtw
    # If decision is True, event is vetoed!
    if sbt or uvt or svt: continue
    for candidate in event.Particles:
        if not match2MC(event, candidate): continue
        total += 1
        wtotal += event.MCTrack[1].GetWeight()
        vtx = r.TLorentzVector()
        mom = r.TLorentzVector()
        candidate.ProductionVertex(vtx)
        candidate.Momentum(mom)
        if in_vessel(vtx) and IPtoTarget(vtx, mom) < 250.:
            selected += 1
            wselected += event.MCTrack[1].GetWeight()
print total, selected
print wtotal/t.GetEntries(), wselected/t.GetEntries()
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  True with weight 1.86264514923e-67
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.0001
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-14
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-10
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-06
UVT: veto decision  False with weight 1.0
SVT: veto decision  True with weight 2.44140625e-28
SBT: veto decision  True with weight 1e-18
UVT: veto decision  True with weight 1e-06
SVT: veto decision  True with weight 3.46944695195e-134
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-08
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-08
UVT: veto decision  False with weight 1.0
SVT: veto decision  True with weight 9.765625e-24
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.0001
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-06
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-08
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.0001
UVT: veto decision  True with weight 1e-06
SVT: veto decision  True with weight 7.8125e-17
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 3.125e-12
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.0001
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  True with weight 1e-06
SVT: veto decision  True with weight 1.220703125e-30
SBT: veto decision  True with weight 1e-06
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  True with weight 9.765625e-24
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-06
UVT: veto decision  False with weight 1.0
SVT: veto decision  True with weight 3.90625e-19
SBT: veto decision  True with weight 0.0001
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.0001
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-12
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 1.49011611938e-60
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 3.125e-12
SBT: veto decision  True with weight 0.0001
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.0001
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 1e-08
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  True with weight 1e-12
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.0001
UVT: veto decision  True with weight 1e-09
SVT: veto decision  True with weight 1.953125e-21
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.0001
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  False with weight 1.0
UVT: veto decision  True with weight 0.001
SVT: veto decision  True with weight 6.25e-10
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  True with weight 0.01
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
SBT: veto decision  False with weight 1.0
UVT: veto decision  False with weight 1.0
SVT: veto decision  False with weight 1.0
14 14
4.72911772704e-06 4.72911772704e-06

In [40]:
print wtotal/t.GetEntries(), wselected/t.GetEntries()
4.72911772704e-06 4.72911772704e-06

In []: