1
# Author: Christopher Tunnell <tunnell@hep.uchicago.edu>
6
from src.GenericWorker import *
9
class IsEntireModuleBad(GenericWorker):
10
"Checks to see if isBad is true for an entire module"
12
def __init__(self, runType = 'CIS'):
13
self.runType = runType
15
def ProcessStart(self):
18
def ProcessStop(self):
19
print 'There are', self.nBad, 'modules with only bad events'
21
def ProcessRegion(self, region):
22
if 'c' in region.GetHash() or 'm' not in region.GetHash():
27
for event in region.RecursiveGetEvents():
28
if event.runType == self.runType and event.data.has_key('goodRegion'):
30
if event.data['goodRegion']:
33
if found and not good:
34
print 'No good events within: ', region.GetHash()