28 sys.exit(
"trggdlUnpacker.py> # of arg is strange.\n 1.rootname\n Exit.")
34b2.set_log_level(b2.LogLevel.INFO)
36b2.use_central_database(
"TRGGDL_201811")
39if f_in_root[-6:] ==
".sroot":
40 rootfiletype =
"sroot"
41 input = b2.register_module(
'SeqRootInput')
42if f_in_root[-5:] ==
".root":
44 input = b2.register_module(
'RootInput')
46input.param(
'inputFileName', f_in_root)
49unpacker = b2.register_module(
'TRGGDLUnpacker')
52trgReadoutBoardSearch =
False
53unpacker.param(
'trgReadoutBoardSearch', trgReadoutBoardSearch)
56output = b2.register_module(
'RootOutput')
59main = b2.create_path()
63main.add_module(unpacker)
65input.param(
"inputFileName", f_in_root)
66output.param(
"outputFileName",
"gdltrg_test.root")
68main.add_module(output, branchNames=[
"TRGGDLUnpackerStores"])
70if trgReadoutBoardSearch:
71 b2.process(main, max_event=100)