Skip to content

A Python module to read LHE (Les Houches Event) file and access the event information in an object oriented way.

License

Notifications You must be signed in to change notification settings

diptaparna/lhereader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

lhereader

A Python module to read LHE (Les Houches Event) file and access the event information in an object oriented way. Requires ROOT (root.cern.ch) and pyroot as external dependencies.

Sample code to use this module -

from lhereader import readLHEF  
from ROOT import TCanvas, TH1F  

data=readLHEF('unweighted_events.lhe')  
parts=data.getParticlesByIDs([5,-5]) # collect all botom and anti-bottom quarks  
c=TCanvas()  
hist=TH1F("pt", "Pt of b/#bar{b}",100,0,1000)  
for p in parts:  
  hist.Fill(p.pt)  
hist.Draw()  
c.SaveAs("pt_b_bbar.png")  

About

A Python module to read LHE (Les Houches Event) file and access the event information in an object oriented way.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages