/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
DataQuality::OnlineOfflineTestRefactored::OnlineOfflineAlg Class Reference
Inheritance diagram for DataQuality::OnlineOfflineTestRefactored::OnlineOfflineAlg:
Inheritance graph
[legend]
Collaboration diagram for DataQuality::OnlineOfflineTestRefactored::OnlineOfflineAlg:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def __init__
def initialize
def execute
def finalize

Public Attributes

 eventnum

Detailed Description

Definition at line 211 of file OnlineOfflineTestRefactored.py.


Constructor & Destructor Documentation

def DataQuality::OnlineOfflineTestRefactored::OnlineOfflineAlg::__init__ (   self,
  name 
)

Definition at line 213 of file OnlineOfflineTestRefactored.py.

00214                            :
00215         DybPythonAlg.__init__(self,name)
00216         self.eventnum = 0
00217         return


Member Function Documentation

def DataQuality::OnlineOfflineTestRefactored::OnlineOfflineAlg::initialize (   self)

Definition at line 218 of file OnlineOfflineTestRefactored.py.

00219                         :
00220         status = DybPythonAlg.initialize(self)
00221         if status.isFailure(): return status
00222         self.info("initializing")
00223         return SUCCESS

def DataQuality::OnlineOfflineTestRefactored::OnlineOfflineAlg::execute (   self)

Definition at line 224 of file OnlineOfflineTestRefactored.py.

00225                      :
00226         self.eventnum += 1              # for debuggin
00227         self.debug("executing event %d"%self.eventnum)
00228         
00229         # Access current data
00230         evt = self.evtSvc()
00231         readoutHdr = evt["/Event/Readout/ReadoutHeader"]
00232         if readoutHdr == None:
00233             self.error("Failed to get current readout header")
00234             return FAILURE
00235 
00236         readout = readoutHdr.readout()
00237         if readout == None:
00238             self.error("Failed to get readout from header")
00239             return FAILURE
00240 
00241         detector = readout.detector()
00242         detint = detector.fullPackedData()
00243 
00244         # Fill per-detector hists
00245         try:
00246             prh = PerReadoutHistograms.hists[detint]
00247         except KeyError:
00248             prh = PerReadoutHistograms(self,detector)
00249         prh.fill_readout(readout)
00250 
00251 
00252         # Loop over channel data
00253         self.verbose('Event %d with %d channels'%(self.eventnum,len(readout.channelReadout())))
00254         for channelPair in readout.channelReadout():
00255             channel = channelPair.second
00256             channelId = channel.channelId()
00257             chanint = channelId.fullPackedData()
00258             try:
00259                 pch = PerChannelHistograms.hists[chanint]
00260             except KeyError:
00261                 pch = PerChannelHistograms(self,detector,channelId)
00262             pch.fill(channel)
00263             prh.fill_channelId(channelId)
00264             continue
00265 
00266         return SUCCESS
        
def DataQuality::OnlineOfflineTestRefactored::OnlineOfflineAlg::finalize (   self)

Definition at line 267 of file OnlineOfflineTestRefactored.py.

00268                       :
00269         self.info("finalizing")
00270         # Fill summary histograms
00271         for id,pch in PerChannelHistograms.hists.iteritems():
00272             detint = pch.detector.fullPackedData()
00273             try:
00274                 csh = ChannelSummaryHistograms.hists[detint]
00275             except KeyError:
00276                 csh = ChannelSummaryHistograms(self,pch.detector)
00277 
00278             csh.fill(pch.chanint,pch.adc)
00279             continue
00280 
00281         for prh in PerReadoutHistograms.hists.itervalues():
00282             prh.norm()
00283             continue
00284 
00285         status = DybPythonAlg.finalize(self)
00286         return status
00287 


Member Data Documentation

Definition at line 213 of file OnlineOfflineTestRefactored.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 10:06:20 for DataQuality by doxygen 1.7.4