15from pathlib
import Path
17from caf.framework
import Calibration, CAF
18from caf.utils
import IoV
19from caf.strategies
import SequentialBoundaries
22b2.set_log_level(b2.LogLevel.DEBUG)
29 print(
"Usage: basf2 caf_boundary_strategy.py <data directory>")
37 input_files_test.append(Path(Path(data_dir).absolute(),
'*.root').as_posix())
41 from ROOT
import Belle2
42 from ROOT.Belle2
import TestCalibrationAlgorithm
43 alg_test = TestCalibrationAlgorithm()
44 alg_test.setMinEntries(15000)
45 alg_test.setAllowedMeanShift(0.1)
48 cal_test =
Calibration(name=
"TestCalibration", collector=
"CaTest", algorithms=alg_test, input_files=input_files_test)
55 cal_test.strategies = SequentialBoundaries
57 cal_test.algorithms[0].params[
"iov_coverage"] = IoV(0, 0, -1, -1)
62 cal_fw.add_calibration(cal_test)
64 print(
"End of CAF processing.")
67if __name__ ==
"__main__":