11from ROOT
import Belle2
12from caf.framework
import Calibration, CAF
13from caf
import backends
15b2.set_log_level(b2.LogLevel.INFO)
16data_dir =
'/gpfs/fs02/belle2/users/dvthanh/201702_unpacked/'
18with open(
'runlist')
as runlist:
19 lines = runlist.readlines()
21 runs.append(
'cr.' + line.rstrip() +
'.root')
22input_files_test = [data_dir + f
for f
in runs]
27 def cdc_pre_algorithm(algorithm, iteration):
28 b2.B2INFO(
"Running pre_algorithm function")
38 col_test = b2.register_module(
'CDCCrudeT0Collector')
39 col_test.set_name(f
'CDCCrudeT0{i}')
40 col_test.param(
'granularity',
'all')
46 alg_test.setPrefix(f
'CDCCrudeT0{i}')
48 cal_test =
Calibration(name=f
'CrudeT0Calibration{i}',
51 input_files=input_files_test)
52 cal_test.pre_algorithms = cdc_pre_algorithm
53 cal_test.max_files_per_collector_job = 1
54 cal_test.backend_args = {
"queue":
"s"}
56 cal_test.use_local_database(
'database.txt',
'/home/belle/muchida/basf2/release/work/caf/test/localDB')
57 calibrations.append(cal_test)
63 for cal
in calibrations:
64 cal_fw.add_calibration(cal)
66 cal_fw.backend = backends.LSF()
72 print(
"End of CAF processing.")
75if __name__ ==
"__main__":
Algorithm class for crude T0 calibration.