9"""ECL calibration to specify edges of each crystal."""
11from prompt
import CalibrationSettings, INPUT_DATA_FILTERS
15settings = CalibrationSettings(
17 expert_username=
"hearty",
19 input_data_formats=[
"cdst"],
20 input_data_names=[
"mumu_tight_or_highm_calib"],
22 "mumu_tight_or_highm_calib": [
23 INPUT_DATA_FILTERS[
"Data Tag"][
"mumu_tight_or_highm_calib"],
24 INPUT_DATA_FILTERS[
"Data Quality Tag"][
"Good"]]},
31def get_calibrations(input_data, **kwargs):
33 from ROOT
import Belle2
34 from caf.utils
import IoV
35 from caf.framework
import Calibration
39 file_to_iov_mu_mu = input_data[
"mumu_tight_or_highm_calib"]
40 input_files_mu_mu = list(file_to_iov_mu_mu.keys())
46 ecledge_collector = basf2.register_module(
"eclEdgeCollector")
47 cal_ecl_edge =
Calibration(name=
"ecl_edge", collector=ecledge_collector, algorithms=algo_edge,
48 input_files=input_files_mu_mu[:1], max_collector_jobs=1)
51 ecl_edge_pre_path = basf2.create_path()
52 ecl_edge_pre_path.add_module(
"Gearbox")
53 ecl_edge_pre_path.add_module(
"Geometry")
54 cal_ecl_edge.pre_collector_path = ecl_edge_pre_path
58 requested_iov = kwargs.get(
"requested_iov",
None)
59 output_iov = IoV(requested_iov.exp_low, requested_iov.run_low, -1, -1)
60 for algorithm
in cal_ecl_edge.algorithms:
61 algorithm.params = {
"apply_iov": output_iov}
..Obtain payloads specifying the location of the edges of each ECL crystal