27 b2.set_log_level(b2.LogLevel.DEBUG)
29 main = b2.create_path()
31 if argc == 2
and argvs[1][-6:] ==
".sroot":
33 input = b2.register_module(
'SeqRootInput')
34 matchobj = re.search(
r"([^\/]+)\.sroot", f_in_root)
35 basename = re.sub(
r'\.sroot$',
'', matchobj.group())
36 input.param(
'inputFileName', f_in_root)
37 elif argc == 2
and argvs[1][-5:] ==
".root":
39 input = b2.register_module(
'RootInput')
40 matchobj = re.search(
r"([^\/]+)\.root", f_in_root)
41 basename = re.sub(
r'\.root$',
'', matchobj.group())
42 input.param(
'inputFileName', f_in_root)
44 input = b2.register_module(
'RootInput')
45 input.param(
'inputFileName',
'/home/belle/nkzw/e3.4S/r034*/all/raw/sub00/raw.physics.hlt_hadron.0003.*.root')
46 basename =
"e3.4S.r034"
48 sys.exit(
"trgcdctsfDQM.py> # of arg is strange. Exit.")
50 main.add_module(input)
51 histo = b2.register_module(
'HistoManager')
52 histo.param(
"histoFileName",
"dqm.%s.superlayer4.root" % basename)
55 trgcdctsfUnpacker = b2.register_module(
"TRGCDCTSFUnpacker")
56 trgcdctsfUnpacker.param(
'TSFMOD', 4)
57 main.add_module(trgcdctsfUnpacker)
58 main.add_module(histo)
61 trgcdctsfdqm = b2.register_module(
'TRGCDCTSFDQM')
62 trgcdctsfdqm.param(
'generatePostscript',
True)
63 trgcdctsfdqm.param(
'TSFMOD', 4)
65 psname =
"dqm.%s.ps" % basename
66 trgcdctsfdqm.param(
'postScriptName', psname)
68 main.add_module(trgcdctsfdqm)
70 progress = b2.register_module(
'Progress')
71 main.add_module(progress)