/search.css" rel="stylesheet" type="text/css"/> /search.js">
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

Public Member Functions | Public Attributes
Ge68EnergyStats::EnergyStatsAlg Class Reference
Inheritance diagram for Ge68EnergyStats::EnergyStatsAlg:
Inheritance graph
[legend]
Collaboration diagram for Ge68EnergyStats::EnergyStatsAlg:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def __init__
def initialize
def execute
def finalize

Public Attributes

 cableSvc

Detailed Description

Definition at line 28 of file Ge68EnergyStats.py.


Constructor & Destructor Documentation

def Ge68EnergyStats::EnergyStatsAlg::__init__ (   self,
  name 
)

Definition at line 30 of file Ge68EnergyStats.py.

00031                            :
00032         DybPythonAlg.__init__(self,name)
00033         return


Member Function Documentation

def Ge68EnergyStats::EnergyStatsAlg::initialize (   self)

Definition at line 34 of file Ge68EnergyStats.py.

00035                         :
00036         status = DybPythonAlg.initialize(self)
00037         if status.isFailure(): return status
00038         self.info("initializing")
00039 
00040         self.cableSvc = self.svc('ICableSvc','CableSvc')
00041         if self.cableSvc == None:
00042             self.error("Failed to get CableSvc")
00043             return FAILURE
00044 
00045         # Make energy histograms
00046 
00047         hist = TH1F("EnergyBias","Energy Bias",500,-2.0,2.5)
00048         hist.GetXaxis().SetTitle("Energy Difference [MeV]")
00049         hist.GetYaxis().SetTitle("Generated Particles")
00050         hist.SetLineColor(4)
00051         self.stats["/file0/energy/EnergyBias"] = hist
00052 
00053         hist = TH1F("reconEnergy","Reconstructed Energy",500,0.0,3.0)
00054         hist.GetXaxis().SetTitle("Reconstructed Visible Energy [E_rec]")
00055         hist.GetYaxis().SetTitle("Triggered Readouts")
00056         hist.SetLineColor(4)
00057         self.stats["/file0/energy/reconEnergy"] = hist
00058         return SUCCESS

def Ge68EnergyStats::EnergyStatsAlg::execute (   self)

Definition at line 59 of file Ge68EnergyStats.py.

00060                      :
00061         self.info("executing")
00062         
00063         evt = self.evtSvc()
00064 
00065 
00066         # reconstructed energy
00067         recHdr = evt["/Event/Rec/RecHeader"]
00068 
00069 
00070         roHdr = evt["/Event/Readout/ReadoutHeader"]
00071         readout = roHdr.readout()
00072         if readout != None:
00073            trigTime = readout.triggerTime()
00074            print "seconds=", trigTime.GetSec()
00075            print "nanoseconds=", trigTime.GetNanoSec()
00076          
00077 
00078         if recHdr == None:
00079             self.error("Failed to get RecHeader")
00080             return FAILURE
00081         recResults = recHdr.recResults()
00082         recTrigger = recResults["AdSimple"]
00083         if recTrigger.energyStatus() == ReconStatus.kGood:
00084             reconEnergy = recTrigger.energy()
00085             self.stats["/file0/energy/reconEnergy"].Fill(reconEnergy)
00086             self.stats["/file0/energy/EnergyBias"].Fill(reconEnergy-1.022)
00087         return SUCCESS

def Ge68EnergyStats::EnergyStatsAlg::finalize (   self)

Definition at line 88 of file Ge68EnergyStats.py.

00089                       :
00090         self.info("finalizing")
00091 
00092         status = DybPythonAlg.finalize(self)
00093         return status
00094 


Member Data Documentation

Definition at line 34 of file Ge68EnergyStats.py.


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Fri May 16 2014 09:54:38 for Calibration by doxygen 1.7.4