From f353a7126cbb2722a7fd122dbdeda9aaa8bdaf85 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Fri, 3 Nov 2023 12:30:50 +0100 Subject: [PATCH 01/11] Dropped test hlt2_fast_reco --- Hlt/RecoConf/options/hlt2_fast_reco.py | 16 ---------------- 1 file changed, 16 deletions(-) delete mode 100644 Hlt/RecoConf/options/hlt2_fast_reco.py diff --git a/Hlt/RecoConf/options/hlt2_fast_reco.py b/Hlt/RecoConf/options/hlt2_fast_reco.py deleted file mode 100644 index 34811886c58..00000000000 --- a/Hlt/RecoConf/options/hlt2_fast_reco.py +++ /dev/null @@ -1,16 +0,0 @@ -############################################################################### -# (c) Copyright 2019 CERN for the benefit of the LHCb Collaboration # -# # -# This software is distributed under the terms of the GNU General Public # -# Licence version 3 (GPL Version 3), copied verbatim in the file "COPYING". # -# # -# In applying this licence, CERN does not waive the privileges and immunities # -# granted to it by virtue of its status as an Intergovernmental Organization # -# or submit itself to any jurisdiction. # -############################################################################### -from Moore import options, run_reconstruction -from RecoConf.standalone import standalone_hlt2_reco -from RecoConf.hlt2_tracking import make_hlt2_tracks - -with make_hlt2_tracks.bind(fast_reco=True): - run_reconstruction(options, standalone_hlt2_reco) -- GitLab From 796b6c466a7ca64d9dd8d0af391a0e6526793a14 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Fri, 12 Jan 2024 09:53:44 +0100 Subject: [PATCH 02/11] Dropped outdated prod_conf test --- Hlt/Moore/python/Moore/compat/tests/params.py | 28 --------- .../options/prod_conf_mock/hlt2_pp_default.py | 20 ------- .../tests/options/prod_conf_mock/mock.py | 58 ------------------- .../tests/options/prod_conf_mock/reference.py | 40 ------------- Hlt/Moore/tests/options/prod_conf_mock/run.sh | 25 -------- Hlt/Moore/tests/qmtest/test_prod_conf.qmt | 22 ------- 6 files changed, 193 deletions(-) delete mode 100644 Hlt/Moore/python/Moore/compat/tests/params.py delete mode 100644 Hlt/Moore/tests/options/prod_conf_mock/hlt2_pp_default.py delete mode 100644 Hlt/Moore/tests/options/prod_conf_mock/mock.py delete mode 100644 Hlt/Moore/tests/options/prod_conf_mock/reference.py delete mode 100644 Hlt/Moore/tests/options/prod_conf_mock/run.sh delete mode 100644 Hlt/Moore/tests/qmtest/test_prod_conf.qmt diff --git a/Hlt/Moore/python/Moore/compat/tests/params.py b/Hlt/Moore/python/Moore/compat/tests/params.py deleted file mode 100644 index 6507b7d149c..00000000000 --- a/Hlt/Moore/python/Moore/compat/tests/params.py +++ /dev/null @@ -1,28 +0,0 @@ -############################################################################### -# (c) Copyright 2021 CERN for the benefit of the LHCb Collaboration # -# # -# This software is distributed under the terms of the GNU General Public # -# Licence version 3 (GPL Version 3), copied verbatim in the file "COPYING". # -# # -# In applying this licence, CERN does not waive the privileges and immunities # -# granted to it by virtue of its status as an Intergovernmental Organization # -# or submit itself to any jurisdiction. # -############################################################################### -from PRConfig.TestFileDB import test_file_db - -test_entry = test_file_db["upgrade_DC19_01_MinBiasMD"] - -# Properties of the ProfConf configurable. -prod_conf_params = { - "OptionFormat": "", - "InputFiles": test_entry.filenames, - "OutputFilePrefix": "Moore", - "OutputFileTypes": ["DST"], - "XMLFileCatalog": "pool_xml_catalog.xml", - "XMLSummaryFile": "summary.xml", - "HistogramFile": "hist.root", - "DDDBTag": test_entry.qualifiers["DDDB"], - "CondDBTag": test_entry.qualifiers["CondDB"], - "DQTag": "", - "NOfEvents": 10, -} diff --git a/Hlt/Moore/tests/options/prod_conf_mock/hlt2_pp_default.py b/Hlt/Moore/tests/options/prod_conf_mock/hlt2_pp_default.py deleted file mode 100644 index b7190f690c0..00000000000 --- a/Hlt/Moore/tests/options/prod_conf_mock/hlt2_pp_default.py +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################### -# (c) Copyright 2021 CERN for the benefit of the LHCb Collaboration # -# # -# This software is distributed under the terms of the GNU General Public # -# Licence version 3 (GPL Version 3), copied verbatim in the file "COPYING". # -# # -# In applying this licence, CERN does not waive the privileges and immunities # -# granted to it by virtue of its status as an Intergovernmental Organization # -# or submit itself to any jurisdiction. # -############################################################################### -from Moore import options -from Hlt2Conf.lines import all_lines - - -def make_lines(): - return [builder() for builder in all_lines.values()] - - -options.simulation = True -options.lines_maker = make_lines diff --git a/Hlt/Moore/tests/options/prod_conf_mock/mock.py b/Hlt/Moore/tests/options/prod_conf_mock/mock.py deleted file mode 100644 index 22958418524..00000000000 --- a/Hlt/Moore/tests/options/prod_conf_mock/mock.py +++ /dev/null @@ -1,58 +0,0 @@ -############################################################################### -# (c) Copyright 2021 CERN for the benefit of the LHCb Collaboration # -# # -# This software is distributed under the terms of the GNU General Public # -# Licence version 3 (GPL Version 3), copied verbatim in the file "COPYING". # -# # -# In applying this licence, CERN does not waive the privileges and immunities # -# granted to it by virtue of its status as an Intergovernmental Organization # -# or submit itself to any jurisdiction. # -############################################################################### -from Configurables import Moore -from Configurables import LHCbApp -from Gaudi.Configuration import FileCatalog - -from Moore.compat.tests.params import prod_conf_params - - -def dressInputFileNames(name): - """Small helper to decorate the input file names.""" - if name.endswith(".raw"): - return "DATAFILE='%s' SVC='LHCb::MDFSelector'" % name - return "DATAFILE='%s' TYP='POOL_ROOTTREE' OPT='READ'" % name - - -### The common part defined in ProdConf.__apply_configuration__() - -# common configuration -app = LHCbApp() - -# Propagate options to LHCbApp, if set. -app.EvtMax = prod_conf_params["NOfEvents"] -app.DDDBtag = prod_conf_params["DDDBTag"] -app.CondDBtag = prod_conf_params["CondDBTag"] -app.DQFLAGStag = prod_conf_params["DQTag"] -app.TimeStamp = True -app.XMLSummary = prod_conf_params["XMLSummaryFile"] - -FileCatalog(Catalogs=["xmlcatalog_file:" + prod_conf_params["XMLFileCatalog"]]) - -from Configurables import EventSelector -EventSelector().Input = [ - dressInputFileNames(f) for f in prod_conf_params["InputFiles"] -] - -from Configurables import Gaudi__Histograming__Sink__Root -Gaudi__Histograming__Sink__Root( - "Gaudi__Histograming__Sink__Root", FileName="hist.root") - -# self.abortStalledEvents() -# self.stopOnSignal() - -### The Moore-specific part, defined in in ProdConf._Moore() - -moore = Moore() -moore.DDDBtag = prod_conf_params["DDDBTag"] -moore.CondDBtag = prod_conf_params["CondDBTag"] -moore.outputFile = (prod_conf_params["OutputFilePrefix"] + '.' + - prod_conf_params["OutputFileTypes"][0].lower()) diff --git a/Hlt/Moore/tests/options/prod_conf_mock/reference.py b/Hlt/Moore/tests/options/prod_conf_mock/reference.py deleted file mode 100644 index 34280b8bed1..00000000000 --- a/Hlt/Moore/tests/options/prod_conf_mock/reference.py +++ /dev/null @@ -1,40 +0,0 @@ -############################################################################### -# (c) Copyright 2021 CERN for the benefit of the LHCb Collaboration # -# # -# This software is distributed under the terms of the GNU General Public # -# Licence version 3 (GPL Version 3), copied verbatim in the file "COPYING". # -# # -# In applying this licence, CERN does not waive the privileges and immunities # -# granted to it by virtue of its status as an Intergovernmental Organization # -# or submit itself to any jurisdiction. # -############################################################################### -from Moore import options, run_moore -from RecoConf.global_tools import stateProvider_with_simplified_geom -from RecoConf.reconstruction_objects import reconstruction -from RecoConf.decoders import default_ft_decoding_version - -from Moore.compat.tests.params import prod_conf_params - -default_ft_decoding_version.global_bind(value=6) - -options.input_files = prod_conf_params["InputFiles"] -options.dddb_tag = prod_conf_params["DDDBTag"] -options.conddb_tag = prod_conf_params["CondDBTag"] -options.histo_file = prod_conf_params["HistogramFile"] -options.evt_max = prod_conf_params["NOfEvents"] -options.output_file = (prod_conf_params["OutputFilePrefix"] + '.' + - prod_conf_params["OutputFileTypes"][0].lower()) - -options.use_iosvc = False -options.event_store = 'HiveWhiteBoard' -options.input_type = "ROOT" -options.output_type = "ROOT" - -public_tools = [stateProvider_with_simplified_geom()] -with reconstruction.bind(from_file=False): - run_moore(options, public_tools=public_tools) - -# prod_conf_params = { -# "XMLFileCatalog": "pool_xml_catalog.xml", -# "XMLSummaryFile": "summary.xml", -# } diff --git a/Hlt/Moore/tests/options/prod_conf_mock/run.sh b/Hlt/Moore/tests/options/prod_conf_mock/run.sh deleted file mode 100644 index 80a6d476447..00000000000 --- a/Hlt/Moore/tests/options/prod_conf_mock/run.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash -############################################################################### -# (c) Copyright 2021 CERN for the benefit of the LHCb Collaboration # -# # -# This software is distributed under the terms of the GNU General Public # -# Licence version 3 (GPL Version 3), copied verbatim in the file "COPYING". # -# # -# In applying this licence, CERN does not waive the privileges and immunities # -# granted to it by virtue of its status as an Intergovernmental Organization # -# or submit itself to any jurisdiction. # -############################################################################### -set -euo pipefail - -# https://docs.python.org/3/using/cmdline.html#envvar-PYTHONHASHSEED -export PYTHONHASHSEED=0 - -gaudirun.py -n $MOOREROOT/tests/options/prod_conf_mock/{hlt2_pp_default,reference}.py -o prod_conf_ref.opts - -gaudirun.py -n $MOOREROOT/tests/options/prod_conf_mock/{hlt2_pp_default,mock}.py -o prod_conf_mock.opts - -diffopts.py \ - -e 'MessageSvc,Format' -e 'FileCatalog,Catalogs' -e 'EventSelector,Input' \ - -e 'CopyInputStream,Output' -e 'CounterSummarySvc,.*' -e 'EventClockSvc,EventTimeDecoder' \ - -e 'ApplicationMgr,ExtSvc' \ - prod_conf_{ref,mock}.opts diff --git a/Hlt/Moore/tests/qmtest/test_prod_conf.qmt b/Hlt/Moore/tests/qmtest/test_prod_conf.qmt deleted file mode 100644 index b788dab5d6f..00000000000 --- a/Hlt/Moore/tests/qmtest/test_prod_conf.qmt +++ /dev/null @@ -1,22 +0,0 @@ - - - - -bash - - ../options/prod_conf_mock/run.sh - -true -600 - -- GitLab From 14d911423fbee732e494dfa576eadb07b203d4f8 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Mon, 25 Mar 2024 13:12:48 +0100 Subject: [PATCH 03/11] Dropped unused Hlt/Moore/python/Moore/compat --- Hlt/Moore/CMakeLists.txt | 1 - .../python/Moore/compat/Configuration.py | 100 ------------------ Hlt/Moore/python/Moore/compat/__init__.py | 0 .../python/Moore/compat/tests/__init__.py | 0 4 files changed, 101 deletions(-) delete mode 100644 Hlt/Moore/python/Moore/compat/Configuration.py delete mode 100644 Hlt/Moore/python/Moore/compat/__init__.py delete mode 100644 Hlt/Moore/python/Moore/compat/tests/__init__.py diff --git a/Hlt/Moore/CMakeLists.txt b/Hlt/Moore/CMakeLists.txt index b0cd93862de..a583314c88e 100644 --- a/Hlt/Moore/CMakeLists.txt +++ b/Hlt/Moore/CMakeLists.txt @@ -14,7 +14,6 @@ Hlt/Moore #]=======================================================================] gaudi_install(PYTHON) -gaudi_generate_confuserdb(Moore.compat.Configuration) gaudi_add_tests(pytest ${CMAKE_CURRENT_SOURCE_DIR}/python) gaudi_add_tests(QMTest) diff --git a/Hlt/Moore/python/Moore/compat/Configuration.py b/Hlt/Moore/python/Moore/compat/Configuration.py deleted file mode 100644 index e35ee83bb9e..00000000000 --- a/Hlt/Moore/python/Moore/compat/Configuration.py +++ /dev/null @@ -1,100 +0,0 @@ -############################################################################### -# (c) Copyright 2021 CERN for the benefit of the LHCb Collaboration # -# # -# This software is distributed under the terms of the GNU General Public # -# Licence version 3 (GPL Version 3), copied verbatim in the file "COPYING". # -# # -# In applying this licence, CERN does not waive the privileges and immunities # -# granted to it by virtue of its status as an Intergovernmental Organization # -# or submit itself to any jurisdiction. # -############################################################################### -import os -import re -from Gaudi.Configuration import ConfigurableUser, appendPostConfigAction -from Configurables import ( - LHCbApp, - DDDBConf, - HistogramPersistencySvc, - EventSelector, -) - - -def undressInputFileName(selector): - m = re.match(r"DATAFILE='([^']+)'", selector) - return m.group(1) - - -def remove_duplicates(): - """Remove duplicates introduced by using both PyConf and LHCbApp""" - from Gaudi.Configuration import allConfigurables - for name, prop in (("ApplicationMgr", "ExtSvc"), ("EventPersistencySvc", - "CnvServices"), - ("FileRecordPersistencySvc", "CnvServices")): - try: - c = allConfigurables[name] - # we have a mixture of configurables and strings, - # so we count as duplicates the entries with the same name - new_items = {} - for element in getattr(c, prop): - el_name = element.name() if hasattr( - element, "name") else element.rsplit("/", 1)[-1] - new_items.setdefault(el_name, element) - setattr(c, prop, list(new_items.values())) - except (AttributeError, KeyError): - pass - - -class Moore(ConfigurableUser): - __used_configurables__ = [ - LHCbApp, - DDDBConf, - ] - - __slots__ = { - "DDDBtag": "", - "CondDBtag": "", - "outputFile": "", - "from_file": False, - "spruce": False, - } - - def __apply_configuration__(self): - from Configurables import LHCbApp - - from Moore import options, run_moore - from RecoConf.global_tools import stateProvider_with_simplified_geom - from RecoConf.reconstruction_objects import reconstruction - - from RecoConf.decoders import default_ft_decoding_version - - default_ft_decoding_version.global_bind(value=6) - - options.evt_max = LHCbApp().getProp("EvtMax") - options.output_file = self.getProp("outputFile") - ext = os.path.splitext(options.output_file)[1].lower() - options.output_type = "MDF" if ext in [".mdf", ".raw"] else "ROOT" - - options.dddb_tag = self.getProp("DDDBtag") - options.conddb_tag = self.getProp("CondDBtag") - - options.use_iosvc = False - options.event_store = 'HiveWhiteBoard' - - options.input_type = getattr(options, "input_type", "ROOT") - options.input_files = [ - undressInputFileName(s) for s in EventSelector().Input - ] - - if HistogramPersistencySvc().isPropertySet("OutputFile"): - options.histo_file = HistogramPersistencySvc().OutputFile - # TODO this will also produce a *_new.root file with new histograms - # that won't be known to dirac. - - from_file = self.getProp("from_file") - spruce = self.getProp("spruce") - - public_tools = [stateProvider_with_simplified_geom()] - with reconstruction.bind(from_file=from_file, spruce=spruce): - run_moore(options, public_tools=public_tools) - - appendPostConfigAction(remove_duplicates) diff --git a/Hlt/Moore/python/Moore/compat/__init__.py b/Hlt/Moore/python/Moore/compat/__init__.py deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/Hlt/Moore/python/Moore/compat/tests/__init__.py b/Hlt/Moore/python/Moore/compat/tests/__init__.py deleted file mode 100644 index e69de29bb2d..00000000000 -- GitLab From 276156f93bcddf258534d6bf07ffcc85fbf11818 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Fri, 12 Jan 2024 09:54:04 +0100 Subject: [PATCH 04/11] Ported all tests to IOAlg --- .../allen_hlt1_production_options.yaml | 5 +- Hlt/Hlt1Conf/options/hlt1_lumi_minbias.py | 2 +- .../tests/options/allen_hlt1_dst_output.py | 11 + .../tests/options/allen_hlt1_mdf_input.py | 2 + .../hlt1_bandwidth_streamless_streams.py | 1 - Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py | 2 +- Hlt/Hlt1Conf/tests/options/hlt1_dst_output.py | 1 + .../tests/options/hlt1_filtered_mdf_input.py | 2 +- Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py | 2 +- .../allen_single_track_tos.qmt | 3 + .../tests/qmtest/persistency.qms/dst_read.qmt | 2 +- .../tests/qmtest/persistency.qms/mdf_read.qmt | 2 +- .../qmtest/persistency.qms/selreports.qmt | 3 +- .../dump_for_standalone_allen_Sim10aU1.ref | 2 +- Hlt/Hlt2Conf/CMakeLists.txt | 1 - ...lavour_taggers_on_example_b2jpsik_lines.py | 1 + ...kaon_tagger_on_example_bs2jpsiphi_lines.py | 1 + .../hlt2_all_lines_with_reco_with_streams.py | 1 - ...t2_all_lines_with_reco_with_streams_mdf.py | 1 - .../options/hlt2_2or3bodytopo_realtime_dst.py | 2 + .../hlt2_all_lines_for_config_check.py | 2 + .../options/hlt2_all_lines_with_reco.py | 3 +- ..._lines_with_reco_fastest_reconstruction.py | 1 - .../hlt2_all_lines_with_reco_for_config.py | 1 - ...l_lines_with_reco_legacy_reconstruction.py | 1 - Hlt/Hlt2Conf/options/hlt2_check_output.py | 54 ++-- Hlt/Hlt2Conf/options/hlt2_example.py | 2 + Hlt/Hlt2Conf/options/hlt2_ganga.py | 7 +- .../options/hlt2_noUT_trackeff_test.py | 1 + .../options/hlt2_persistreco_realtime.py | 2 + ..._reprocessing_data_production_options.yaml | 2 +- ...2_pp_commissioning_production_options.yaml | 3 +- .../options/hlt2_production_options.yaml | 3 +- Hlt/Hlt2Conf/options/hlt2_trackeff_test.py | 1 + .../lbexec_yamls/excl_spruce_2022_data.yaml | 2 +- .../lbexec_yamls/pass_spruce_2022_data.yaml | 1 + ...ruce_all_lines_realtime_test_old_json.yaml | 2 +- .../lbexec_yamls/spruce_example_realtime.yaml | 2 +- .../spruce_example_realtime_dstinput.yaml | 5 +- .../spruce_example_realtime_extraoutputs.yaml | 4 +- .../spruce_example_realtime_persistreco.yaml | 4 +- .../lbexec_yamls/spruce_hlt2filter.yaml | 2 +- .../lbexec_yamls/spruce_passthrough.yaml | 4 +- .../spruce_passthrough_dstinput.yaml | 5 +- .../lbexec_yamls/turcal_spruce_2022_data.yaml | 4 +- .../sprucing/spruce_example_realtime.py | 2 +- .../spruce_example_realtime_dstinput.py | 3 +- .../spruce_example_realtime_extraoutputs.py | 2 +- .../spruce_example_realtime_persistreco.py | 2 +- .../options/sprucing/spruce_hlt2filter.py | 2 +- .../options/sprucing/spruce_passthrough.py | 6 +- .../sprucing/spruce_passthrough_dstinput.py | 3 +- .../options/streaming/hlt2_test_streaming.py | 7 + .../streaming/spruce_test_streaming.py | 2 +- .../streaming/spruce_test_streaming.yaml | 4 +- .../python/Hlt2Conf/Sprucing_tests.py | 5 +- Hlt/Hlt2Conf/python/Hlt2Conf/check_output.py | 3 +- .../python/Hlt2Conf/lines/charm/hyperons.py | 10 +- .../settings/hlt2_pp_commissioning.py | 3 - .../Hlt2Conf/tests/test_algorithms_thor.py | 11 + .../spruce_bandwidth_input_latest.py | 2 +- .../tests/options/hlt2_check_packed_data.py | 8 + .../options/hlt2_checksum_packed_data.py | 8 + Hlt/Hlt2Conf/tests/options/hlt2_dst_output.py | 2 + .../tests/options/hlt2_lumi_events_check.py | 124 +++---- .../hlt2_passthrough_persistreco_check.py | 42 +-- .../tests/options/hlt2_persistreco_check.py | 61 ++-- .../hlt2_persistreco_check_flavourtags.py | 50 +-- .../tests/options/hlt2_thor_selections.py | 8 + .../tests/options/hlt2_with_hlt1_filtering.py | 5 + .../tests/options/hlt_filters_test.py | 1 - .../options/hlt_filters_test_sprucepass.py | 2 +- .../tests/options/sprucing/spruce_check.py | 52 ++- .../sprucing/spruce_check_2022_data.py | 45 +-- .../sprucing/spruce_check_extraoutputs.py | 45 ++- .../sprucing/spruce_check_persistreco.py | 50 ++- .../tests/options/streaming/stream_check.py | 78 ++--- .../tests/options/test_soa_packing.py | 175 ++++------ .../test_excl_spruce_2022_data_b2cc_check.qmt | 43 --- ...spruce_example_realtime_dstinput_check.qmt | 1 + ...ample_realtime_dstinput_gaudirun_check.qmt | 1 + ...test_spruce_passthrough_dstinput_check.qmt | 1 + ...ce_passthrough_dstinput_gaudirun_check.qmt | 1 + ...l_spruce_2022_data_monitoring_rb_check.qmt | 4 +- ...t_turcal_spruce_2022_data_pid_rb_check.qmt | 4 +- ...cal_spruce_2022_data_trackeff_rb_check.qmt | 6 +- .../test_hlt2_streaming_check_A.qmt | 1 + .../test_hlt2_streaming_check_B.qmt | 1 + ...heck_output_with_reco_with_streams_mdf.qmt | 2 +- .../test_sprucing_streaming_check_A.qmt | 1 + .../test_sprucing_streaming_check_B.qmt | 1 + .../test_hlt2_check_output_with_reco.qmt | 2 +- .../test_persistreco_check_flavourtags.qmt | 4 +- ...heck_output_with_reco_with_streams_mdf.qmt | 2 +- ...l_spruce_2022_data_monitoring_rb_check.ref | 297 +++++++++++++++++ ...t_turcal_spruce_2022_data_pid_rb_check.ref | 294 +++++++++++++++++ ...cal_spruce_2022_data_trackeff_rb_check.ref | 306 ++++++++++++++++++ Hlt/Moore/python/Moore/config.py | 2 +- Hlt/Moore/python/Moore/lines.py | 2 +- .../python/Moore/persistence/__init__.py | 7 +- .../Moore/persistence/truth_matching.py | 24 +- Hlt/Moore/python/Moore/qmtest/exclusions.py | 5 +- Hlt/Moore/python/Moore/stream_writers.py | 14 +- Hlt/Moore/python/Moore/tests/test_lines.py | 21 +- .../tests/options/default_conds_hlt1.py} | 15 +- ...onds_for_ut_v4r2_decoding_retinacluster.py | 1 + .../options/input_add_retina_clusters.py | 3 +- .../lead_lead_input_and_conds_hlt2_mdf.py | 2 - .../tests/options/mdf_input_and_conds.py | 2 - .../tests/options/mdf_input_and_conds_hlt2.py | 2 - Hlt/Moore/tests/options/minimal_options.py | 9 +- .../tests/qmtest/test_ioextension_input.qmt | 30 -- ...c_hlt2_pp_2022_reprocessing_data_check.qmt | 41 ++- .../options/add_retina_clusters_to_digi.py | 13 +- ...mpare_hlt1_hlt2_ut_hits_with_mcchecking.py | 4 +- .../options/examples/mc_matching_example.py | 36 +-- .../examples/run_pr_tracking_losses.py | 26 +- .../hlt1_reco_allen_calo_resolution.py | 8 +- .../options/mdf_for_standalone_Allen.py | 8 + .../options/phoenix_event_data_dump.py | 8 - .../run_cheated_pattern_recognition.py | 18 +- .../run_pr_parameterisation_data.py | 10 +- .../run_pr_tracking_debug.py | 14 +- .../RecoConf/calorimeter_mc_checking.py | 16 +- .../python/RecoConf/data_from_file.py | 95 +++--- Hlt/RecoConf/python/RecoConf/hlt1_allen.py | 2 +- .../python/RecoConf/hlt2_global_reco.py | 13 +- Hlt/RecoConf/python/RecoConf/mc_checking.py | 119 ++++--- .../python/RecoConf/rich_mc_checking.py | 6 +- Hlt/RecoConf/python/RecoConf/standalone.py | 30 +- .../RecoConf/velo_cluster_data_monitoring.py | 8 +- .../refs/VP_tracking_monitors.ref.detdesc | 3 + .../refs/hlt1_reco_velo_only.ref.detdesc | 2 +- .../tests/refs/hlt2_reco_data_2023.ref | 3 + .../tests/refs/hlt2_ttracks_mva_filter.ref | 3 + .../refs/hlt2_ttracks_mva_filter.ref.detdesc | 3 + .../refs/legacy_rec_hlt1_reco_velo_only.ref | 2 +- doc/recoconf/recoconf.rst | 5 +- doc/tutorials/different_samples.rst | 5 +- doc/tutorials/running.rst | 1 - 140 files changed, 1739 insertions(+), 862 deletions(-) delete mode 100644 Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_excl_spruce_2022_data_b2cc_check.qmt create mode 100644 Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_monitoring_rb_check.ref create mode 100644 Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_pid_rb_check.ref create mode 100644 Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_trackeff_rb_check.ref rename Hlt/{Hlt2Conf/options/hlt2_ganga_input.py => Moore/tests/options/default_conds_hlt1.py} (60%) delete mode 100644 Hlt/Moore/tests/qmtest/test_ioextension_input.qmt diff --git a/Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml b/Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml index a58b5ca4fda..04da2b57610 100644 --- a/Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml +++ b/Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml @@ -8,9 +8,12 @@ input_files: - LFN:/lhcb/MC/Upgrade/XDIGI/00172009/0000/00172009_00003403_1_evt_20_39.xdigi input_type: "ROOT" input_raw_format: 0.5 -evt_max: -1 +evt_max: 30 xml_summary_file: "hlt1_summary.xml" xml_file_catalog: "hlt1_pool_xml_catalog.xml" output_file: 'allen_production_test.dst' output_type: 'ROOT' +root_ioalg_name: 'RootIOAlgExt' +# as DumpFTGeometry may create it first +root_ioalg_opts: {'IgnorePaths': ['/Event/DAQ']} diff --git a/Hlt/Hlt1Conf/options/hlt1_lumi_minbias.py b/Hlt/Hlt1Conf/options/hlt1_lumi_minbias.py index 780f8d8e7e2..a8e3cc1be5f 100644 --- a/Hlt/Hlt1Conf/options/hlt1_lumi_minbias.py +++ b/Hlt/Hlt1Conf/options/hlt1_lumi_minbias.py @@ -29,7 +29,7 @@ NOBIAS_FRACTION = 0.25 def make_emulated_odin(make_raw=default_raw_banks): """Return an emulated ODIN object, based on the original one.""" # Decode the original LHCb::ODIN object from the raw bank - odin = createODIN(RawBanks=make_raw(("ODIN"))).ODIN + odin = createODIN(RawBanks=make_raw("ODIN")).ODIN # Emulate a new LHCb::ODIN object based on the original emulated = ODINEmulator( InputODINLocation=odin, diff --git a/Hlt/Hlt1Conf/tests/options/allen_hlt1_dst_output.py b/Hlt/Hlt1Conf/tests/options/allen_hlt1_dst_output.py index 7e90f5081b9..83848054869 100644 --- a/Hlt/Hlt1Conf/tests/options/allen_hlt1_dst_output.py +++ b/Hlt/Hlt1Conf/tests/options/allen_hlt1_dst_output.py @@ -13,6 +13,17 @@ from Moore import options options.output_file = 'test_allen_hlt1_persistence_dst_write.dst' options.output_type = 'ROOT' +options.root_ioalg_name = 'RootIOAlgExt' +options.root_ioalg_opts = { + 'IgnorePaths': [ + '/Event/DAQ', + '/Event/Gen/Collisions', + '/Event/PrevPrev/Gen/Collisions', + '/Event/Prev/Gen/Collisions', + '/Event/Next/Gen/Collisions', + '/Event/NextNext/Gen/Collisions', + ] +} # as DumpGeometry will potentially create it first # there is no rejection, so avoid writing out too many events options.evt_max = 100 diff --git a/Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py b/Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py index 529b3c636c3..e540f306404 100644 --- a/Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py +++ b/Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py @@ -13,4 +13,6 @@ from Moore import options options.input_files = ['test_allen_hlt1_persistence_mdf_write.mdf'] options.input_type = 'MDF' +options.mdf_ioalg_name = 'IOAlgMemoryMap' options.set_conds_from_testfiledb('upgrade_Sept2022_BsPhiPhi_0fb_md_xdigi') +options.evt_max = 190 diff --git a/Hlt/Hlt1Conf/tests/options/bandwidth/hlt1_bandwidth_streamless_streams.py b/Hlt/Hlt1Conf/tests/options/bandwidth/hlt1_bandwidth_streamless_streams.py index 62b6edd5971..e4e0bd4a7f3 100644 --- a/Hlt/Hlt1Conf/tests/options/bandwidth/hlt1_bandwidth_streamless_streams.py +++ b/Hlt/Hlt1Conf/tests/options/bandwidth/hlt1_bandwidth_streamless_streams.py @@ -33,7 +33,6 @@ options.output_file = fname_helper.mdfdst_fname_for_Moore( stream_config="streamless", ext=".mdf").format(stream="streamless") options.output_type = 'MDF' options.output_manifest_file = fname_helper.tck(stream_config="streamless") -options.use_iosvc = False if UseDD4Hep: DDDBConf().GeometryVersion = 'run3/before-rich1-geom-update-26052022' diff --git a/Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py b/Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py index 24cce84c60c..223b2f0fbac 100644 --- a/Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py +++ b/Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py @@ -13,4 +13,4 @@ from Moore import options options.input_files = ['test_hlt1_persistence_dst_write.dst'] options.input_type = 'ROOT' -options.evt_max = -1 +options.evt_max = 39 diff --git a/Hlt/Hlt1Conf/tests/options/hlt1_dst_output.py b/Hlt/Hlt1Conf/tests/options/hlt1_dst_output.py index 8d50c7ca988..0b5b6b09ffa 100644 --- a/Hlt/Hlt1Conf/tests/options/hlt1_dst_output.py +++ b/Hlt/Hlt1Conf/tests/options/hlt1_dst_output.py @@ -13,3 +13,4 @@ from Moore import options options.output_file = 'test_hlt1_persistence_dst_write.dst' options.output_type = 'ROOT' +options.root_ioalg_name = 'RootIOAlgExt' diff --git a/Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py b/Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py index 48e9df0011f..f715c58d982 100644 --- a/Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py +++ b/Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py @@ -14,5 +14,5 @@ options.dddb_tag = "dddb-20180815" options.conddb_tag = "sim-20180530-vc-md100" options.input_files = ['test_allen_hlt1_persistence_mdf_write.mdf'] options.input_type = "MDF" -options.evt_max = 1000 +options.evt_max = 195 options.simulation = True diff --git a/Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py b/Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py index 54efd6f1565..a0c0fe86cc6 100644 --- a/Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py +++ b/Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py @@ -13,4 +13,4 @@ from Moore import options options.input_files = ['test_hlt1_persistence_mdf_write.mdf'] options.input_type = 'MDF' -options.evt_max = -1 +options.evt_max = 39 diff --git a/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/allen_single_track_tos.qmt b/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/allen_single_track_tos.qmt index d5401cb0440..d8b675c183a 100644 --- a/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/allen_single_track_tos.qmt +++ b/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/allen_single_track_tos.qmt @@ -13,6 +13,9 @@ Run Allen HLT1 and check forward tracks against SelReports with TOSFilters. --> + + persistency.allen_mdf_writePASS + gaudirun.py $HLT1CONFROOT/tests/options/allen_hlt1_mdf_input.py diff --git a/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/dst_read.qmt b/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/dst_read.qmt index 5e5644bdfaf..6163cf130bd 100644 --- a/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/dst_read.qmt +++ b/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/dst_read.qmt @@ -18,7 +18,7 @@ Run HLT1 on an HLT1-filtered DST file. gaudirun.py - $MOOREROOT/tests/options/default_input_and_conds_hlt1.py + $MOOREROOT/tests/options/default_conds_hlt1.py $HLT1CONFROOT/tests/options/hlt1_dst_input.py $HLT1CONFROOT/options/hlt1_pp_default.py diff --git a/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/mdf_read.qmt b/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/mdf_read.qmt index 465f7bf83d6..1bd0f9252e4 100644 --- a/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/mdf_read.qmt +++ b/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/mdf_read.qmt @@ -18,7 +18,7 @@ Run HLT1 on an HLT1-filtered MDF file. gaudirun.py - $MOOREROOT/tests/options/default_input_and_conds_hlt1.py + $MOOREROOT/tests/options/default_conds_hlt1.py $HLT1CONFROOT/tests/options/hlt1_mdf_input.py $HLT1CONFROOT/options/hlt1_pp_default.py diff --git a/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/selreports.qmt b/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/selreports.qmt index 7e04ee50eaa..10c1fe9e3f3 100644 --- a/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/selreports.qmt +++ b/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/selreports.qmt @@ -25,8 +25,7 @@ mdf_write job). gaudirun.py - - $MOOREROOT/tests/options/default_input_and_conds_hlt1.py + $MOOREROOT/tests/options/default_conds_hlt1.py $HLT1CONFROOT/tests/options/hlt1_mdf_input.py $HLT1CONFROOT/options/hlt1_selreports_filtering.py diff --git a/Hlt/Hlt1Conf/tests/refs/dump_for_standalone_allen_Sim10aU1.ref b/Hlt/Hlt1Conf/tests/refs/dump_for_standalone_allen_Sim10aU1.ref index 68beb0cba13..80bc91715aa 100644 --- a/Hlt/Hlt1Conf/tests/refs/dump_for_standalone_allen_Sim10aU1.ref +++ b/Hlt/Hlt1Conf/tests/refs/dump_for_standalone_allen_Sim10aU1.ref @@ -1,4 +1,4 @@ -LHCb__MDFWriter_5851b3f3 INFO +LHCb__MDFWriter_7ab0076f INFO ApplicationMgr INFO Application Manager Finalized successfully ApplicationMgr INFO Application Manager Terminated successfully DeviceBeamline INFO Number of counters : 1 diff --git a/Hlt/Hlt2Conf/CMakeLists.txt b/Hlt/Hlt2Conf/CMakeLists.txt index 956d63cde04..c8dff3313b9 100644 --- a/Hlt/Hlt2Conf/CMakeLists.txt +++ b/Hlt/Hlt2Conf/CMakeLists.txt @@ -136,7 +136,6 @@ if(BUILD_TESTING AND NOT USE_DD4HEP) Hlt2Conf.sprucing.test_turcal_spruce_2022_data_trackeff_rb_check Hlt2Conf.sprucing.test_turcal_spruce_2022_data_monitoring_check Hlt2Conf.sprucing.test_turcal_spruce_2022_data_monitoring_rb_check - Hlt2Conf.sprucing.test_excl_spruce_2022_data_b2cc_check Hlt2Conf.sprucing.test_excl_spruce_2022_data_b2oc_check Hlt2Conf.sprucing.test_excl_spruce_2022_data_bandq_check Hlt2Conf.sprucing.test_excl_spruce_2022_data_qee_check diff --git a/Hlt/Hlt2Conf/options/FlavourTagging/hlt2_flavour_taggers_on_example_b2jpsik_lines.py b/Hlt/Hlt2Conf/options/FlavourTagging/hlt2_flavour_taggers_on_example_b2jpsik_lines.py index be56851f9e9..ce833d24e0f 100644 --- a/Hlt/Hlt2Conf/options/FlavourTagging/hlt2_flavour_taggers_on_example_b2jpsik_lines.py +++ b/Hlt/Hlt2Conf/options/FlavourTagging/hlt2_flavour_taggers_on_example_b2jpsik_lines.py @@ -198,6 +198,7 @@ options.data_type = 'Upgrade' options.dddb_tag = 'dddb-20210617' options.conddb_tag = 'sim-20210617-vc-md100' options.input_raw_format = 0.3 +options.root_ioalg_name = "RootIOAlgExt" make_digits.global_bind(calo_raw_bank=False) options.output_file = 'hlt2_b2jpsik_flavourtagging.dst' diff --git a/Hlt/Hlt2Conf/options/FlavourTagging/hlt2_sskaon_tagger_on_example_bs2jpsiphi_lines.py b/Hlt/Hlt2Conf/options/FlavourTagging/hlt2_sskaon_tagger_on_example_bs2jpsiphi_lines.py index cb64a41af96..22816edcfa6 100644 --- a/Hlt/Hlt2Conf/options/FlavourTagging/hlt2_sskaon_tagger_on_example_bs2jpsiphi_lines.py +++ b/Hlt/Hlt2Conf/options/FlavourTagging/hlt2_sskaon_tagger_on_example_bs2jpsiphi_lines.py @@ -115,6 +115,7 @@ options.conddb_tag = 'sim-20210617-vc-md100' options.geometry_version = 'run3/trunk' options.conditions_version = 'master' options.input_raw_format = 0.3 +options.root_ioalg_name = 'RootIOAlgExt' make_digits.global_bind(calo_raw_bank=False) options.output_file = 'hlt2_bs2jpsiphi_flavourtagging_sskaontagger.dst' diff --git a/Hlt/Hlt2Conf/options/fest/hlt2_all_lines_with_reco_with_streams.py b/Hlt/Hlt2Conf/options/fest/hlt2_all_lines_with_reco_with_streams.py index 250fe46dbcd..b1c1b670fa4 100644 --- a/Hlt/Hlt2Conf/options/fest/hlt2_all_lines_with_reco_with_streams.py +++ b/Hlt/Hlt2Conf/options/fest/hlt2_all_lines_with_reco_with_streams.py @@ -29,7 +29,6 @@ options.output_file = 'hlt2_all_lines_with_reco.{stream}.mdf' options.output_type = 'MDF' options.output_manifest_file = "hlt2_all_lines_with_reco_with_streams.tck.json" # temporarily use HiveWhiteBoard, see lhcb/LHCb!2878 -options.use_iosvc = False options.event_store = 'HiveWhiteBoard' diff --git a/Hlt/Hlt2Conf/options/fest/hlt2_all_lines_with_reco_with_streams_mdf.py b/Hlt/Hlt2Conf/options/fest/hlt2_all_lines_with_reco_with_streams_mdf.py index 847470c971c..0d9d6acdf8e 100755 --- a/Hlt/Hlt2Conf/options/fest/hlt2_all_lines_with_reco_with_streams_mdf.py +++ b/Hlt/Hlt2Conf/options/fest/hlt2_all_lines_with_reco_with_streams_mdf.py @@ -50,7 +50,6 @@ options.output_type = 'MDF' options.output_file = '{stream}_hlt2_all_lines_with_reco_with_streams_mdf.mdf' options.output_manifest_file = "hlt2_all_lines_with_reco_with_streams_mdf.tck.json" -options.use_iosvc = False options.event_store = 'HiveWhiteBoard' hlt2_lines = all_lines diff --git a/Hlt/Hlt2Conf/options/hlt2_2or3bodytopo_realtime_dst.py b/Hlt/Hlt2Conf/options/hlt2_2or3bodytopo_realtime_dst.py index cfdad58dc7d..2c9e94054c6 100644 --- a/Hlt/Hlt2Conf/options/hlt2_2or3bodytopo_realtime_dst.py +++ b/Hlt/Hlt2Conf/options/hlt2_2or3bodytopo_realtime_dst.py @@ -40,6 +40,8 @@ options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' options.geometry_version = 'run3/trunk' options.conditions_version = 'master' +options.root_ioalg_name = "RootIOAlgExt" +options.root_ioalg_opts = {'IgnorePaths': ['/Event/Rec/Summary']} options.output_file = 'hlt2_2or3bodytopo_realtime_dst.dst' options.output_type = 'ROOT' diff --git a/Hlt/Hlt2Conf/options/hlt2_all_lines_for_config_check.py b/Hlt/Hlt2Conf/options/hlt2_all_lines_for_config_check.py index 9f4995fea91..6ed2e9ceae7 100644 --- a/Hlt/Hlt2Conf/options/hlt2_all_lines_for_config_check.py +++ b/Hlt/Hlt2Conf/options/hlt2_all_lines_for_config_check.py @@ -27,6 +27,8 @@ default_VeloCluster_source.global_bind(bank_type="VPRetinaCluster") options.set_input_and_conds_from_testfiledb('expected_2024_minbias_xdigi') options.evt_max = 100 +options.root_ioalg_name = 'RootIOAlgExt' +options.root_ioalg_opts = {'IgnorePaths': ['/Event/Rec/Summary']} options.output_file = 'hlt2_all_lines.dst' options.output_type = 'ROOT' diff --git a/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco.py b/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco.py index 4b0ae811ee6..a3ccf1c9e7c 100644 --- a/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco.py +++ b/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco.py @@ -20,12 +20,11 @@ from RecoConf.global_tools import stateProvider_with_simplified_geom from RecoConf.reconstruction_objects import reconstruction from Hlt2Conf.lines import all_lines -options.evt_max = 200 +options.evt_max = -1 options.output_file = 'hlt2_all_lines_with_reco.dst' options.output_type = 'ROOT' options.output_manifest_file = "hlt2_all_lines_with_reco.tck.json" # temporarily use HiveWhiteBoard, see lhcb/LHCb!2878 -options.use_iosvc = False options.event_store = 'HiveWhiteBoard' hlt2_lines = all_lines diff --git a/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_fastest_reconstruction.py b/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_fastest_reconstruction.py index 0554912f579..6d20824bb77 100644 --- a/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_fastest_reconstruction.py +++ b/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_fastest_reconstruction.py @@ -27,7 +27,6 @@ options.output_file = 'hlt2_all_lines_with_reco_fastest_reconstruction.dst' options.output_manifest_file = "hlt2_all_lines_with_reco_fastest_reconstruction.tck.json" options.output_type = 'ROOT' # temporarily use HiveWhiteBoard, see lhcb/LHCb!2878 -options.use_iosvc = False options.event_store = 'HiveWhiteBoard' diff --git a/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_for_config.py b/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_for_config.py index 99f5dc2f392..cba7cd2d8d7 100644 --- a/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_for_config.py +++ b/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_for_config.py @@ -25,7 +25,6 @@ options.output_file = 'hlt2_all_lines_with_reco_for_config.dst' options.output_type = 'ROOT' options.output_manifest_file = "hlt2_all_lines_with_reco_for_config.tck.json" # temporarily use HiveWhiteBoard, see lhcb/LHCb!2878 -options.use_iosvc = False options.event_store = 'HiveWhiteBoard' diff --git a/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_legacy_reconstruction.py b/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_legacy_reconstruction.py index 15d82933c9b..8251c57a81e 100644 --- a/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_legacy_reconstruction.py +++ b/Hlt/Hlt2Conf/options/hlt2_all_lines_with_reco_legacy_reconstruction.py @@ -27,7 +27,6 @@ options.output_file = 'hlt2_all_lines_with_reco_legacy_reconstruction.dst' options.output_manifest_file = "hlt2_all_lines_with_reco_legacy_reconstruction.tck.json" options.output_type = 'ROOT' # temporarily use HiveWhiteBoard, see lhcb/LHCb!2878 -options.use_iosvc = False options.event_store = 'HiveWhiteBoard' diff --git a/Hlt/Hlt2Conf/options/hlt2_check_output.py b/Hlt/Hlt2Conf/options/hlt2_check_output.py index 8c226837564..034b1e636ef 100644 --- a/Hlt/Hlt2Conf/options/hlt2_check_output.py +++ b/Hlt/Hlt2Conf/options/hlt2_check_output.py @@ -26,11 +26,10 @@ Takes command-line arguments: import sys import GaudiPython as GP -from GaudiConf import IOHelper -from Configurables import (ApplicationMgr, LHCbApp, IODataManager) - +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure +from Moore import options from GaudiConf.reading import do_unpacking -from PyConf.application import configured_ann_svc def error(msg): @@ -41,33 +40,35 @@ def warning(msg): print("Hlt2CheckOutput WARNING: ", msg) -LHCbApp( - DataType="Upgrade", - Simulation=True, - DDDBtag="dddb-20171126", - CondDBtag="sim-20171127-vc-md100", -) - -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) -algs = do_unpacking(input_process='Hlt2') +input_file = sys.argv[1] +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [input_file] +options.input_type = "ROOT" if input_file.find(".dst") != -1 else "MDF" +options.gaudipython_mode = True +options.evt_max = int(sys.argv[2]) +config = configure_input(options) + +algs = do_unpacking( + input_process='Hlt2', + has_mc_data=(options.input_type == "ROOT"), + stream='') decdecoder = None for alg in algs: - for m in getattr(alg, "Members", - []): # deal with sequencers (but only one layer of them) - if "HltDecReportsDecoder" in m.getFullName(): - decdecoder = m - if "HltDecReportsDecoder" in alg.getFullName(): + if "Hlt2DecReportsDecoder" == alg.name: decdecoder = alg assert decdecoder -appmgr = ApplicationMgr(TopAlg=algs) -appmgr.ExtSvc += [configured_ann_svc()] +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) -input_file = sys.argv[1] -input_type = "ROOT" if input_file.find(".dst") != -1 else "RAW" -IOHelper(input_type).inputFiles([input_file], clear=True) +config.update(configure(options, cf_node)) stream = None if input_file.startswith('sprucing'): stream = 'Sprucing' @@ -89,11 +90,12 @@ cppyy.gbl.DataSvcHelpers.RegistryEntry.__bool__ = lambda x: True # The test can't check anything if no event fired found_events = False found_child_relations = False +n = 1 while TES['/Event']: print('Checking next event.') #TES.dump() - decRep = TES[str(decdecoder.OutputHltDecReportsLocation)].decReports() + decRep = TES[decdecoder.OutputHltDecReportsLocation.location].decReports() for name, report in decRep.items(): # for _these_ tests: Hlt2Topo is in 'Spruce' and the rest in 'Turbo' _if_ (and only if) we could recognize the stream @@ -110,6 +112,8 @@ while TES['/Event']: error("empty Particles container in " + prefix + "/Particles") found_events = True + n += 1 + if n == options.evt_max: break # avoid EndOfinput warning appMgr.run(1) if not found_events: diff --git a/Hlt/Hlt2Conf/options/hlt2_example.py b/Hlt/Hlt2Conf/options/hlt2_example.py index 634fc760b75..e4c71a97e4a 100644 --- a/Hlt/Hlt2Conf/options/hlt2_example.py +++ b/Hlt/Hlt2Conf/options/hlt2_example.py @@ -31,6 +31,8 @@ input_files = [ options.input_files = input_files options.input_type = 'ROOT' options.input_raw_format = 4.3 +options.root_ioalg_name = 'RootIOAlgExt' +options.root_ioalg_opts = {'IgnorePaths': ['/Event/Rec/Summary']} # When running from Upgrade MC, must use the post-juggling locations of the raw # event diff --git a/Hlt/Hlt2Conf/options/hlt2_ganga.py b/Hlt/Hlt2Conf/options/hlt2_ganga.py index 74f823e1a44..9ffa57a2338 100644 --- a/Hlt/Hlt2Conf/options/hlt2_ganga.py +++ b/Hlt/Hlt2Conf/options/hlt2_ganga.py @@ -12,7 +12,7 @@ This demonstrates what an options file for use with Ganga looks like. -Requires a separate file that defines the input data using IOExtension. +Requires a separate file that defines the input data. """ from Moore import options, run_moore @@ -28,6 +28,11 @@ options.input_type = 'ROOT' options.input_raw_format = 4.3 options.persistreco_version = 0.0 options.data_type = 'Upgrade' +options.input_files = [ + # D*-tagged D0 to KK, 27163002 + # sim+std://MC/Upgrade/Beam7000GeV-Upgrade-MagDown-Nu7.6-25ns-Pythia8/Sim09c-Up02/Reco-Up01/27163002/LDST + 'root://eoslhcb.cern.ch//eos/lhcb/grid/prod/lhcb/MC/Upgrade/LDST/00070317/0000/00070317_00000033_2.ldst' +] options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' options.geometry_version = 'run3/trunk' diff --git a/Hlt/Hlt2Conf/options/hlt2_noUT_trackeff_test.py b/Hlt/Hlt2Conf/options/hlt2_noUT_trackeff_test.py index 098ff2908bb..009c3191ae1 100644 --- a/Hlt/Hlt2Conf/options/hlt2_noUT_trackeff_test.py +++ b/Hlt/Hlt2Conf/options/hlt2_noUT_trackeff_test.py @@ -42,6 +42,7 @@ options.conddb_tag = 'sim-20210617-vc-md100' options.input_files = input_files options.input_type = 'ROOT' options.input_raw_format = 0.3 +options.root_ioalg_name = 'RootIOAlgExt' options.evt_max = 100 options.simulation = True diff --git a/Hlt/Hlt2Conf/options/hlt2_persistreco_realtime.py b/Hlt/Hlt2Conf/options/hlt2_persistreco_realtime.py index abc4db407ae..4dfdbd161a5 100644 --- a/Hlt/Hlt2Conf/options/hlt2_persistreco_realtime.py +++ b/Hlt/Hlt2Conf/options/hlt2_persistreco_realtime.py @@ -109,6 +109,8 @@ input_files = [ options.input_files = input_files options.input_type = 'ROOT' options.input_raw_format = 4.3 +options.root_ioalg_name = 'RootIOAlgExt' +options.root_ioalg_opts = {'IgnorePaths': ['/Event/Rec/Summary']} # When running from Upgrade MC, must use the post-juggling locations of the raw # event diff --git a/Hlt/Hlt2Conf/options/hlt2_pp_2022_reprocessing_data_production_options.yaml b/Hlt/Hlt2Conf/options/hlt2_pp_2022_reprocessing_data_production_options.yaml index b37161784a8..ed026a0918c 100644 --- a/Hlt/Hlt2Conf/options/hlt2_pp_2022_reprocessing_data_production_options.yaml +++ b/Hlt/Hlt2Conf/options/hlt2_pp_2022_reprocessing_data_production_options.yaml @@ -6,7 +6,7 @@ geometry_version: run3/trunk conditions_version: master input_files: - - LFN:/lhcb/data/2022/RAW/PASSTHROUGH/LHCb/COLLISION22/256264/256264_00090018_0006.raw + - mdf:root://eoslhcb.cern.ch//eos/lhcb/cern-swtest/lhcb/data/2022/RAW/PASSTHROUGH/LHCb/COLLISION22/256264/256264_00090018_0006.raw input_type: RAW evt_max: 100 diff --git a/Hlt/Hlt2Conf/options/hlt2_pp_commissioning_production_options.yaml b/Hlt/Hlt2Conf/options/hlt2_pp_commissioning_production_options.yaml index 8af0538c31f..c7311be1d4f 100644 --- a/Hlt/Hlt2Conf/options/hlt2_pp_commissioning_production_options.yaml +++ b/Hlt/Hlt2Conf/options/hlt2_pp_commissioning_production_options.yaml @@ -6,8 +6,9 @@ conddb_tag: 'sim-20220929-vc-md100' input_files: - LFN:allen_production_test.dst input_type: "ROOT" +root_ioalg_name: 'RootIOAlgExt' input_raw_format: 0.5 -evt_max: -1 +evt_max: 9 xml_summary_file: hlt2_pp_commissioning_summary.xml xml_file_catalog: hlt1_pool_xml_catalog.xml diff --git a/Hlt/Hlt2Conf/options/hlt2_production_options.yaml b/Hlt/Hlt2Conf/options/hlt2_production_options.yaml index 8dfb418ae9e..c96c57fe6fa 100644 --- a/Hlt/Hlt2Conf/options/hlt2_production_options.yaml +++ b/Hlt/Hlt2Conf/options/hlt2_production_options.yaml @@ -7,8 +7,9 @@ input_files: - LFN:/lhcb/MC/Upgrade/XDIGI/00172009/0000/00172009_00003403_1_evt_0_9.xdigi - LFN:/lhcb/MC/Upgrade/XDIGI/00172009/0000/00172009_00003403_1_evt_20_39.xdigi input_type: "ROOT" +root_ioalg_name: "RootIOAlgExt" input_raw_format: 0.5 -evt_max: -1 +evt_max: 30 xml_summary_file: "hlt2_summary.xml" xml_file_catalog: "hlt2_pool_xml_catalog.xml" diff --git a/Hlt/Hlt2Conf/options/hlt2_trackeff_test.py b/Hlt/Hlt2Conf/options/hlt2_trackeff_test.py index 44a3b8e2f31..fd0e07e9b87 100644 --- a/Hlt/Hlt2Conf/options/hlt2_trackeff_test.py +++ b/Hlt/Hlt2Conf/options/hlt2_trackeff_test.py @@ -30,6 +30,7 @@ HiveDataBrokerSvc().OutputLevel = 5 options.set_input_and_conds_from_testfiledb('upgrade_DC19_01_Bs2JPsiPhi_MD') options.input_raw_format = 0.3 options.evt_max = 100 +options.root_ioalg_name = 'RootIOAlgExt' default_ft_decoding_version.global_bind(value=6) make_digits.global_bind(calo_raw_bank=False) options.output_file = 'hlt2_trackeff_alllines.dst' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml index 579844c7322..df8d32e62bc 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml @@ -7,7 +7,7 @@ input_files : [ 'mdf:root://eoslhcb.cern.ch//eos/lhcb/wg/dpa/wp1/data/2022_1_FULL_255620_00150001_0005.raw' ] -evt_max : -1 +evt_max : 12795 simulation : False geometry_version: run3/trunk diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml index 18c28a4ffa3..1213c2bd389 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml @@ -5,6 +5,7 @@ input_type : 'RAW' input_files : [ 'mdf:root://eoslhcb.cern.ch//eos/lhcb/wg/dpa/wp1/data/2022_1_TURBO_255620_00150000_0003.raw' ] +evt_max : 53606 simulation : False geometry_version: run3/trunk diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_all_lines_realtime_test_old_json.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_all_lines_realtime_test_old_json.yaml index 561b9a8a875..ccc3d9b7586 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_all_lines_realtime_test_old_json.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_all_lines_realtime_test_old_json.yaml @@ -7,7 +7,7 @@ input_files : [ ] input_manifest_file : 'root://eoslhcb.cern.ch//eos/lhcb/wg/rta/samples/mc/Hlt1Hlt2filtered_MinBias_sprucing/hlt2_2or3bodytopo_realtime_newPacking.tck.json' -evt_max : -1 +evt_max : 475 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime.yaml index 4a167d764ad..ecc3794a30e 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime.yaml @@ -4,7 +4,7 @@ input_files : ['hlt2_2or3bodytopo_realtime.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime.tck.json" input_type : 'RAW' -evt_max : -1 +evt_max : 30 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_dstinput.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_dstinput.yaml index f0773049f07..83d37122fb7 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_dstinput.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_dstinput.yaml @@ -3,8 +3,9 @@ input_raw_format : 0.5 input_files : ['hlt2_2or3bodytopo_realtime_dst.dst'] input_manifest_file : "hlt2_2or3bodytopo_realtime_dst.tck.json" input_type : 'ROOT' +root_ioalg_name: 'RootIOAlgExt' -evt_max : -1 +evt_max : 31 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' @@ -12,4 +13,4 @@ conddb_tag : 'sim-20171127-vc-md100' output_file : 'spruce_realtimereco_dstinput.{stream}.dst' output_type : 'ROOT' output_manifest_file : "spruce_example_realtime_dstinput.tck.json" -input_process: Hlt2 \ No newline at end of file +input_process: Hlt2 diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_extraoutputs.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_extraoutputs.yaml index 3b7c13f4976..bd00fc6ebe4 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_extraoutputs.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_extraoutputs.yaml @@ -4,7 +4,7 @@ input_files : ['hlt2_2or3bodytopo_realtime_with_extras.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime_with_extras.tck.json" input_type : 'RAW' -evt_max : -1 +evt_max : 11 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' @@ -12,4 +12,4 @@ conddb_tag : 'sim-20171127-vc-md100' output_file : 'spruce_realtimereco_extraoutputs.dst' output_type : 'ROOT' output_manifest_file : "spruce_example_realtime_extraoutputs.tck.json" -input_process: Hlt2 \ No newline at end of file +input_process: Hlt2 diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_persistreco.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_persistreco.yaml index 6b1014a86a4..e86e33fc655 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_persistreco.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_persistreco.yaml @@ -4,7 +4,7 @@ input_files : ['hlt2_2or3bodytopo_realtime.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime.tck.json" input_type : 'RAW' -evt_max : -1 +evt_max : 11 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' @@ -12,4 +12,4 @@ conddb_tag : 'sim-20171127-vc-md100' output_file : 'spruce_realtimereco_persistreco.dst' output_type : 'ROOT' output_manifest_file : "spruce_example_realtime_persistreco.tck.json" -input_process: Hlt2 \ No newline at end of file +input_process: Hlt2 diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml index 69df8d8ea57..9f5b716d322 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml @@ -4,7 +4,7 @@ input_files : ['hlt2_2or3bodytopo_realtime.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime.tck.json" input_type : 'RAW' -evt_max : -1 +evt_max : 30 simulation : True dddb_tag : 'dddb-20180815' conddb_tag : 'sim-20180530-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough.yaml index 4a67fa1fbc8..a1e2d877e36 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough.yaml @@ -4,7 +4,7 @@ input_files : ['hlt2_test_persistreco_fromfile.test_stream_B.mdf'] input_type : 'RAW' input_manifest_file : 'hlt2_test_streaming.tck.json' -evt_max : -1 +evt_max : 1000 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' @@ -12,4 +12,4 @@ conddb_tag : 'sim-20171127-vc-md100' output_file : 'spruce_passthrough.{stream}.dst' output_type : 'ROOT' output_manifest_file : "spruce_passthrough.tck.json" -input_process: Hlt2 \ No newline at end of file +input_process: Hlt2 diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml index 7d865881a96..392296d3394 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml @@ -2,9 +2,10 @@ process: TurboPass input_raw_format : 0.5 input_files : ['hlt2_2or3bodytopo_realtime_dst.dst'] input_type : 'ROOT' +root_ioalg_name : 'RootIOAlgExt' input_manifest_file : 'hlt2_2or3bodytopo_realtime_dst.tck.json' -evt_max : -1 +evt_max : 31 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' @@ -12,4 +13,4 @@ conddb_tag : 'sim-20171127-vc-md100' output_file : 'spruce_passthrough_dstinput.dst' output_type : 'ROOT' output_manifest_file : "spruce_passthrough_dstinput.tck.json" -input_process: Hlt2 \ No newline at end of file +input_process: Hlt2 diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml index c04a0b88a9b..bd8a1fb1255 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml @@ -10,9 +10,9 @@ input_files : [ simulation : False geometry_version: run3/trunk conditions_version: master -evt_max: -1 +evt_max: 116674 output_file : 'pass_turcal_lines_production.{stream}.dst' output_type : 'ROOT' output_manifest_file : "pass_turcal_lines_production.tck.json" -input_process: Hlt2 \ No newline at end of file +input_process: Hlt2 diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py index 33c2ffdba69..282d4bd268f 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py @@ -23,7 +23,7 @@ options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = -1 +options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_dstinput.py b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_dstinput.py index 5b2a10e5dd8..bb380c5fc88 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_dstinput.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_dstinput.py @@ -27,8 +27,9 @@ options.input_process = 'Hlt2' options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime_dst.tck.json" options.input_type = 'ROOT' +options.root_ioalg_name = 'RootIOAlgExt' -options.evt_max = -1 +options.evt_max = 31 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_extraoutputs.py b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_extraoutputs.py index d1e363fd139..c266682d12f 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_extraoutputs.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_extraoutputs.py @@ -23,7 +23,7 @@ options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = -1 +options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_persistreco.py b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_persistreco.py index b44bcde6d61..e51a0365839 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_persistreco.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_persistreco.py @@ -23,7 +23,7 @@ options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = -1 +options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py b/Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py index c30025ff6e5..9768cdffd09 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py @@ -30,7 +30,7 @@ options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = -1 +options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20180815' options.conddb_tag = 'sim-20180530-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py index bf79b3f5035..76af8faa4bc 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py @@ -16,6 +16,7 @@ Run like any other options file: """ from Moore import options, run_moore from RecoConf.global_tools import stateProvider_with_simplified_geom +from PyConf.application import create_or_reuse_rootIOAlg from Moore.lines import PassLine input_files = ['hlt2_2or3bodytopo_realtime.mdf'] @@ -26,7 +27,7 @@ options.input_files = input_files options.input_type = 'MDF' options.input_manifest_file = 'hlt2_2or3bodytopo_realtime.tck.json' -options.evt_max = -1 +options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' @@ -39,6 +40,9 @@ options.output_manifest_file = "spruce_passthrough_gaudirun.tck.json" def pass_through_line(name="Passthrough"): """Return a Sprucing line that performs no selection """ + # As unpackers are expecting the I/O to be setup and nobody does it, + # we need to precreate RootIOAlg here + create_or_reuse_rootIOAlg(options) return PassLine(name=name) diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py index cbabd218978..1adeb56d6a2 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py @@ -27,9 +27,10 @@ options.input_raw_format = 0.3 options.input_process = 'Hlt2' options.input_files = input_files options.input_type = 'ROOT' +options.root_ioalg_name = 'RootIOAlgExt' options.input_manifest_file = 'hlt2_2or3bodytopo_realtime_dst.tck.json' -options.evt_max = -1 +options.evt_max = 31 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/streaming/hlt2_test_streaming.py b/Hlt/Hlt2Conf/options/streaming/hlt2_test_streaming.py index 33cc2492b18..8f14c105148 100644 --- a/Hlt/Hlt2Conf/options/streaming/hlt2_test_streaming.py +++ b/Hlt/Hlt2Conf/options/streaming/hlt2_test_streaming.py @@ -18,6 +18,7 @@ from Moore import options, run_moore from RecoConf.global_tools import stateProvider_with_simplified_geom from Moore.lines import Hlt2Line, Hlt2LuminosityLine from Moore.streams import Stream, Streams +from PyConf.application import input_from_root_file, configure_input options.set_input_and_conds_from_testfiledb('upgrade_minbias_hlt1_filtered') options.input_raw_format = 4.3 @@ -26,6 +27,12 @@ options.output_file = 'hlt2_test_persistreco_fromfile.{stream}.mdf' options.output_type = 'MDF' options.output_manifest_file = "hlt2_test_streaming.tck.json" +# make sure RawEvent is read from input file, as the lines writers are not +# declaring what they write but take anything in the TES +config = configure_input(options) +input_from_root_file( + "/Event/DAQ/RawEvent", forced_type='LHCb::RawEvent', options=options), + from RecoConf.decoders import default_ft_decoding_version ft_decoding_version = 2 #4,6 default_ft_decoding_version.global_bind(value=ft_decoding_version) diff --git a/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py b/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py index dcf7c799121..bb8b2bae1f5 100644 --- a/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py +++ b/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py @@ -29,7 +29,7 @@ options.input_type = 'MDF' # When running from Upgrade MC, must use the post-juggling locations of the raw # event -options.evt_max = -1 +options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml b/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml index c00a63fa334..cc99c86fdf1 100644 --- a/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml +++ b/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml @@ -4,7 +4,7 @@ input_files : ['hlt2_2or3bodytopo_realtime.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime.tck.json" input_type : 'RAW' -evt_max : -1 +evt_max : 11 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' @@ -12,4 +12,4 @@ input_process: Hlt2 output_file : 'spruce_streaming.{stream}.dst' output_type : 'ROOT' -output_manifest_file : "spruce_streaming.tck.json" \ No newline at end of file +output_manifest_file : "spruce_streaming.tck.json" diff --git a/Hlt/Hlt2Conf/python/Hlt2Conf/Sprucing_tests.py b/Hlt/Hlt2Conf/python/Hlt2Conf/Sprucing_tests.py index 231f3eed395..2d5a8badd55 100644 --- a/Hlt/Hlt2Conf/python/Hlt2Conf/Sprucing_tests.py +++ b/Hlt/Hlt2Conf/python/Hlt2Conf/Sprucing_tests.py @@ -16,7 +16,7 @@ from Hlt2Conf.lines.test.spruce_test import Test_sprucing_line, Test_extraoutput from Hlt2Conf.lines.b_to_open_charm import b_to_dh from Moore.lines import PassLine, SpruceLine from Moore.persistence import persist_line_outputs -from PyConf.application import metainfo_repos +from PyConf.application import metainfo_repos, create_or_reuse_rootIOAlg from Moore.persistence.hlt2_tistos import list_of_full_stream_lines from Moore.streams import Stream, Streams, DETECTORS @@ -86,6 +86,9 @@ def spruce_sp_passthrough(options: Options): Run like any other options file: ./Moore/run gaudirun.py spruce_passthrough.py """ + # As unpackers are expecting the I/O to be setup and nobody does it, + # we need to precreate RootIOAlg here + create_or_reuse_rootIOAlg(options) def make_streams(): return Streams(streams=[ diff --git a/Hlt/Hlt2Conf/python/Hlt2Conf/check_output.py b/Hlt/Hlt2Conf/python/Hlt2Conf/check_output.py index 1e3346aeb7d..dc55e99ea11 100644 --- a/Hlt/Hlt2Conf/python/Hlt2Conf/check_output.py +++ b/Hlt/Hlt2Conf/python/Hlt2Conf/check_output.py @@ -90,7 +90,8 @@ def check_MCoutput(TES, RECO_ROOT, fs=4, mcpart=100): header = TES['/Event/Gen/Header'] if not header: error("MC Headers not being propagated") - print("MC eventtype is ", header.evType()) + else: + print("MC eventtype is ", header.evType()) MCTrackInfo = TES['/Event/MC/TrackInfo'] if not MCTrackInfo: error("MC TrackInfo not being propagated") diff --git a/Hlt/Hlt2Conf/python/Hlt2Conf/lines/charm/hyperons.py b/Hlt/Hlt2Conf/python/Hlt2Conf/lines/charm/hyperons.py index 11add3a6278..d3ffb71b1be 100644 --- a/Hlt/Hlt2Conf/python/Hlt2Conf/lines/charm/hyperons.py +++ b/Hlt/Hlt2Conf/python/Hlt2Conf/lines/charm/hyperons.py @@ -2887,7 +2887,7 @@ def o_to_xipipi_line(name="Hlt2Charm_OmToXimPimPip_LongXim_SP"): return Hlt2Line( name=name, algs=charm_prefilters() + [omegas], - #extra_outputs=[("RichRawBanks", default_raw_event(["Rich"]))] + #extra_outputs=[("RichRawBanks", default_raw_event("Rich"))] ) @@ -3074,7 +3074,7 @@ def lcp_to_smkpi_longsm_line( return Hlt2Line( name=name, algs=charm_prefilters() + [lcs, lbs], - #extra_outputs=[("RichRawBanks", default_raw_event(["Rich"]))] + #extra_outputs=[("RichRawBanks", default_raw_event("Rich"))] ) @@ -3440,7 +3440,7 @@ def xicp_to_spkpi_longsp_line( return Hlt2Line( name=name, algs=charm_prefilters() + [xicps, xib0s], - #extra_outputs=[("RichRawBanks", default_raw_event(["Rich"]))] + #extra_outputs=[("RichRawBanks", default_raw_event("Rich"))] ) @@ -3666,7 +3666,7 @@ def xicp_to_ximpipi_longxim_line( return Hlt2Line( name=name, algs=charm_prefilters() + [xicps, xib0s], - #extra_outputs=[("RichRawBanks", default_raw_event(["Rich"]))] + #extra_outputs=[("RichRawBanks", default_raw_event("Rich"))] ) @@ -3882,7 +3882,7 @@ def xicp_to_omkpi_longom_line( return Hlt2Line( name=name, algs=charm_prefilters() + [xicps, xib0s], - #extra_outputs=[("RichRawBanks", default_raw_event(["Rich"]))] + #extra_outputs=[("RichRawBanks", default_raw_event("Rich"))] ) diff --git a/Hlt/Hlt2Conf/python/Hlt2Conf/settings/hlt2_pp_commissioning.py b/Hlt/Hlt2Conf/python/Hlt2Conf/settings/hlt2_pp_commissioning.py index 39bdda353f5..9efb982d824 100644 --- a/Hlt/Hlt2Conf/python/Hlt2Conf/settings/hlt2_pp_commissioning.py +++ b/Hlt/Hlt2Conf/python/Hlt2Conf/settings/hlt2_pp_commissioning.py @@ -166,9 +166,7 @@ def make_streams(real_make_streams=_make_streams): from RecoConf.hlt2_tracking import ( make_PrKalmanFilter_noUT_tracks, make_PrKalmanFilter_Seed_tracks, make_PrKalmanFilter_Velo_tracks, make_TrackBestTrackCreator_tracks) - # Workaround to enable running of Tracking efficiency lines using special muon reconstruction from PyConf.Tools import TrackMasterFitter - with make_TrackBestTrackCreator_tracks.bind(max_chi2ndof=4.),\ make_PrKalmanFilter_Velo_tracks.bind(max_chi2ndof=6.),\ make_PrKalmanFilter_noUT_tracks.bind(max_chi2ndof=8.),\ @@ -178,5 +176,4 @@ def make_streams(real_make_streams=_make_streams): make_reco_pvs.bind(make_pvs_from_velo_tracks=make_PatPV3DFuture_pvs),\ make_PatPV3DFuture_pvs.bind(velo_open=True),\ TrackMasterFitter.bind(FastMaterialApproximation=True): - return real_make_streams() diff --git a/Hlt/Hlt2Conf/python/Hlt2Conf/tests/test_algorithms_thor.py b/Hlt/Hlt2Conf/python/Hlt2Conf/tests/test_algorithms_thor.py index d1a0cc5979c..374de9f0f4b 100644 --- a/Hlt/Hlt2Conf/python/Hlt2Conf/tests/test_algorithms_thor.py +++ b/Hlt/Hlt2Conf/python/Hlt2Conf/tests/test_algorithms_thor.py @@ -19,9 +19,19 @@ from ..standard_particles import make_long_cb_pions from PyConf.packing import persistreco_version persistreco_version.global_bind(version=0.0) +from PyConf.application import configure_input +from Moore import options +# minimum config to be able to configure +options.simulation = True +options.input_type = "Root" +options.input_files = ["fake"] +options.dddb_tag = "v1" +options.conddb_tag = "v1" + def test_v1_filter_v2_inputs(): """A v1 filter cannot be instantiated with v2 input.""" + configure_input(options) v2_pions = make_long_cb_pions() with thor.thor_backend.bind(particle_api=thor.PARTICLE_V1): with pytest.raises(TypeError): @@ -30,6 +40,7 @@ def test_v1_filter_v2_inputs(): def test_v1_combiner_v2_inputs(): """A v1 combiner cannot be instantiated with v2 input.""" + configure_input(options) v2_pions = make_long_cb_pions() with thor.thor_backend.bind(particle_api=thor.PARTICLE_V1): with pytest.raises(TypeError): diff --git a/Hlt/Hlt2Conf/tests/options/bandwidth/spruce_bandwidth_input_latest.py b/Hlt/Hlt2Conf/tests/options/bandwidth/spruce_bandwidth_input_latest.py index 3cb408e9c75..5c5fab61f2b 100644 --- a/Hlt/Hlt2Conf/tests/options/bandwidth/spruce_bandwidth_input_latest.py +++ b/Hlt/Hlt2Conf/tests/options/bandwidth/spruce_bandwidth_input_latest.py @@ -29,7 +29,7 @@ options.dddb_tag = "dddb-20231017" options.conddb_tag = "sim-20231017-vc-md100" options.simulation = True options.input_type = 'MDF' -options.evt_max = 100 +options.evt_max = 5 options.n_threads = 1 options.input_raw_format = 0.5 diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_check_packed_data.py b/Hlt/Hlt2Conf/tests/options/hlt2_check_packed_data.py index 0107bfb67cb..5e87a25cf39 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_check_packed_data.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_check_packed_data.py @@ -21,6 +21,14 @@ from Hlt2Conf.lines.topological_b import all_lines as all_lines_topo options.output_file = "hlt2_check_packed_data.dst" options.output_type = "ROOT" +options.root_ioalg_name = 'RootIOAlgExt' +options.root_ioalg_opts = { + 'IgnorePaths': [ + '/Event/Gen/Collisions', '/Event/PrevPrev/Gen/Collisions', + '/Event/Prev/Gen/Collisions', '/Event/Next/Gen/Collisions', + '/Event/NextNext/Gen/Collisions' + ] +} def make_lines(): diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_checksum_packed_data.py b/Hlt/Hlt2Conf/tests/options/hlt2_checksum_packed_data.py index 8494f48d915..655c3da3681 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_checksum_packed_data.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_checksum_packed_data.py @@ -21,6 +21,14 @@ from Hlt2Conf.lines.topological_b import all_lines as all_lines_topo options.output_file = "hlt2_checksum_packed_data.dst" options.output_type = "ROOT" +options.root_ioalg_name = 'RootIOAlgExt' +options.root_ioalg_opts = { + 'IgnorePaths': [ + '/Event/Gen/Collisions', '/Event/PrevPrev/Gen/Collisions', + '/Event/Prev/Gen/Collisions', '/Event/Next/Gen/Collisions', + '/Event/NextNext/Gen/Collisions' + ] +} def make_lines(): diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_dst_output.py b/Hlt/Hlt2Conf/tests/options/hlt2_dst_output.py index d08a5b1996c..d553597896f 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_dst_output.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_dst_output.py @@ -11,5 +11,7 @@ """Setup DST output file for the `hlt2_persistreco_fromfile.py` options.""" from Moore import options +options.root_ioalg_name = 'RootIOAlgExt' +options.root_ioalg_opts = {'IgnorePaths': ['/Event/Rec/Summary']} options.output_file = 'hlt2_test_persistreco_fromfile.dst' options.output_type = 'ROOT' diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py b/Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py index 1e348b63878..0ef0db3dc00 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py @@ -21,8 +21,11 @@ import os import sys from pathlib import Path -from GaudiConf import IOExtension -from Configurables import LHCbApp, IODataManager, HltLumiSummaryMonitor +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure, default_raw_banks, default_raw_event, make_odin +from Moore import options + +from Configurables import ApplicationMgr parser = argparse.ArgumentParser() parser.add_argument('input', help='Input filename') @@ -37,69 +40,37 @@ def error(msg): print("Check ERROR", msg) -# FIXME which part of LHCbApp is actually needed? -LHCbApp( - DataType="Upgrade", - Simulation=True, - #DDDBtag="master", - #CondDBtag="2022_12_HLT2Processing", - DDDBtag="dddb-20171126", - CondDBtag="sim-20171127-vc-md100", -) - -IOExtension().inputFiles([args.input], clear=True) -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [args.input] +options.input_type = "MDF" +options.gaudipython_mode = True +config = configure_input(options) if args.lumi_stream: - from Configurables import LHCb__UnpackRawEvent, LHCb__SelectViewForHltSourceID, createODIN, ApplicationMgr, HltLumiSummaryDecoder - unpacker = LHCb__UnpackRawEvent("UnpackRawEvent") - unpacker.RawBankLocations = [ - "DAQ/RawBanks/HltLumiSummary", "DAQ/RawBanks/ODIN" - ] - unpacker.BankTypes = ["HltLumiSummary", "ODIN"] - - decodeODIN = createODIN(RawBanks="DAQ/RawBanks/ODIN") - + from PyConf.Algorithms import LHCb__SelectViewForHltSourceID, HltLumiSummaryDecoder, HltLumiSummaryMonitor + odin = make_odin() + lumiRB = default_raw_banks("HltLumiSummary") sel1 = LHCb__SelectViewForHltSourceID( - "SelectHlt1Lumi", - Input="DAQ/RawBanks/HltLumiSummary", - SourceID="Hlt1", - Output="DAQ/RawBanks/Hlt1LumiSummary") + name="SelectHlt1Lumi", Input=lumiRB, SourceID="Hlt1") sel2 = LHCb__SelectViewForHltSourceID( - "SelectHlt2Lumi", - Input="DAQ/RawBanks/HltLumiSummary", - SourceID="Hlt2", - Output="DAQ/RawBanks/Hlt2LumiSummary") - dec1 = HltLumiSummaryDecoder( - "DecodeHlt1Lumi", - RawBanks="DAQ/RawBanks/Hlt1LumiSummary", - OutputContainerName="Hlt1LumiSummary") - dec2 = HltLumiSummaryDecoder( - "DecodeHlt2Lumi", - RawBanks="DAQ/RawBanks/Hlt2LumiSummary", - OutputContainerName="Hlt2LumiSummary") + name="SelectHlt2Lumi", Input=lumiRB, SourceID="Hlt2") + dec1 = HltLumiSummaryDecoder(name="DecodeHlt1Lumi", RawBanks=sel1) + dec2 = HltLumiSummaryDecoder(name="DecodeHlt2Lumi", RawBanks=sel2) + monit = HltLumiSummaryMonitor( + name="Hlt2LumiSummaryMonitor", + Input=dec2.OutputContainerName, + ODIN=odin, + OutputLevel=1) from PyConf.application import configured_ann_svc from Configurables import Gaudi__Monitoring__MessageSvcSink as MessageSvcSink from Configurables import Gaudi__Monitoring__JSONSink as JSONSink - ApplicationMgr().TopAlg = [ - unpacker, - decodeODIN, - sel1, - sel2, - dec1, - dec2, - # HltLumiSummaryMonitor(name="Hlt1LumiSummaryMonitor", Input="Hlt1LumiSummary", ODIN="/Event/DAQ/ODIN", OutputLevel=1), - HltLumiSummaryMonitor( - name="Hlt2LumiSummaryMonitor", - Input="Hlt2LumiSummary", - ODIN="/Event/DAQ/ODIN", - OutputLevel=1, - ), - ] + algs = [dec1, monit] ApplicationMgr().HistogramPersistency = "ROOT" ApplicationMgr().ExtSvc = [ configured_ann_svc(), @@ -112,14 +83,23 @@ if args.lumi_stream: ], ), ] +else: + algs = [default_raw_event("DAQ")] + +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) +config.update(configure(options, cf_node)) import GaudiPython as GP LHCb = GP.gbl.LHCb -RawBank = LHCb.RawBank +appMgr = GP.AppMgr() +TES = appMgr.evtsvc() -def events(appMgr): - TES = appMgr.evtsvc() +def events(): appMgr.run(1) while TES["/Event"]: yield TES @@ -148,27 +128,27 @@ def routing_bits(rbbanks): return [bit for bit, value in enumerate(ordered) if value] -for TES in events(GP.AppMgr()): +for TES in events(): raw_event = TES["/Event/DAQ/RawEvent"] # TODO also check the bank versions test_equals( - raw_event.banks(RawBank.DAQ).size(), 1, + raw_event.banks(LHCb.RawBank.DAQ).size(), 1, "Every raw event must have exactly one DAQ (MDF header) bank") test_equals( - raw_event.banks(RawBank.ODIN).size(), 1, + raw_event.banks(LHCb.RawBank.ODIN).size(), 1, "Every raw event must have exactly one ODIN bank") test_equals( - raw_event.banks(RawBank.HltRoutingBits).size(), 1, + raw_event.banks(LHCb.RawBank.HltRoutingBits).size(), 1, "Every raw event must have exactly one HltRoutingBits bank") - rb_bank, = raw_event.banks(RawBank.HltRoutingBits) + rb_bank, = raw_event.banks(LHCb.RawBank.HltRoutingBits) assert get_hlt_source_id(rb_bank) == 2 - on_bits = routing_bits(raw_event.banks(RawBank.HltRoutingBits)) + on_bits = routing_bits(raw_event.banks(LHCb.RawBank.HltRoutingBits)) if 95 not in on_bits: # this is not a "content event", so it must be a nanofied event # and we don't have any other banks. @@ -177,13 +157,13 @@ for TES in events(GP.AppMgr()): continue hlt1_dec_reports_bank, = select_hlt_banks( - raw_event.banks(RawBank.HltDecReports), 1) + raw_event.banks(LHCb.RawBank.HltDecReports), 1) hlt2_dec_reports_bank, = select_hlt_banks( - raw_event.banks(RawBank.HltDecReports), 2) - assert raw_event.banks(RawBank.HltDecReports).size() == 2 + raw_event.banks(LHCb.RawBank.HltDecReports), 2) + assert raw_event.banks(LHCb.RawBank.HltDecReports).size() == 2 hlt1_sel_reports_banks = select_hlt_banks( - raw_event.banks(RawBank.HltSelReports), 1) + raw_event.banks(LHCb.RawBank.HltSelReports), 1) assert len(hlt1_sel_reports_banks) <= 1 # TODO check for the presence of some banks overall # check that when one of a set of lines fired, we always have the sel reports @@ -191,20 +171,20 @@ for TES in events(GP.AppMgr()): # assert len(hlt1_sel_reports_banks) == 1 hlt2_sel_reports_banks = select_hlt_banks( - raw_event.banks(RawBank.HltSelReports), 2) + raw_event.banks(LHCb.RawBank.HltSelReports), 2) test_equals( len(hlt2_sel_reports_banks), 0, "There should be no HLT2 HltSelReports banks") if not args.lumi_stream: test_equals( - raw_event.banks(RawBank.HltLumiSummary).size(), 0, + raw_event.banks(LHCb.RawBank.HltLumiSummary).size(), 0, "There should be no HltLumiSummary banks") else: hlt1_lumi_banks = select_hlt_banks( - raw_event.banks(RawBank.HltLumiSummary), 1) + raw_event.banks(LHCb.RawBank.HltLumiSummary), 1) hlt2_lumi_banks = select_hlt_banks( - raw_event.banks(RawBank.HltLumiSummary), 2) + raw_event.banks(LHCb.RawBank.HltLumiSummary), 2) assert len(hlt1_lumi_banks) <= 1 assert len(hlt2_lumi_banks) <= 1 test_equals( diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_passthrough_persistreco_check.py b/Hlt/Hlt2Conf/tests/options/hlt2_passthrough_persistreco_check.py index d066952784d..926115be68e 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_passthrough_persistreco_check.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_passthrough_persistreco_check.py @@ -24,11 +24,11 @@ expect. import argparse import GaudiPython as GP -from GaudiConf import IOExtension -from Configurables import (ApplicationMgr, LHCbApp, IODataManager, - HistogramPersistencySvc) +from PyConf.control_flow import CompositeNode, NodeLogic +from Configurables import HistogramPersistencySvc from GaudiConf.reading import do_unpacking -from PyConf.application import configured_ann_svc +from PyConf.application import configure_input, configure +from Moore import options from Hlt2Conf.check_output import check_persistreco, check_decreports from PyConf.packing import default_persistable_locations @@ -38,25 +38,29 @@ parser.add_argument('input', help='Input filename') parser.add_argument('hlt2_tck', help='HLT2 JSON TCK dump') args = parser.parse_args() -algs = do_unpacking(input_process='Hlt2') - ##Prepare application -LHCbApp( - DataType="Upgrade", - Simulation=True, - DDDBtag="dddb-20171126", - CondDBtag="sim-20171127-vc-md100", -) - -appmgr = ApplicationMgr(TopAlg=algs) -appmgr.ExtSvc += [configured_ann_svc()] - -IOExtension().inputFiles([args.input], clear=True) -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [args.input] +options.input_type = "MDF" +options.gaudipython_mode = True +config = configure_input(options) + +algs = do_unpacking(input_process='Hlt2', has_mc_data=False) + # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) + +config.update(configure(options, cf_node)) + appMgr = GP.AppMgr() TES = appMgr.evtsvc() appMgr.run(1) diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py index ece3fe1e052..a3b10a7c15d 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py @@ -24,20 +24,15 @@ import argparse import sys import GaudiPython as GP -from GaudiConf import IOExtension -from Configurables import ( - ApplicationMgr, - LHCbApp, - IODataManager, - HistogramPersistencySvc, - LHCb__UnpackRawEvent, - createODIN, -) +from Configurables import HistogramPersistencySvc + +from PyConf.control_flow import CompositeNode, NodeLogic from PyConf.packing import default_persistable_locations from GaudiConf.reading import do_unpacking from Hlt2Conf.check_output import check_persistreco, check_particles -from PyConf.application import configured_ann_svc +from PyConf.application import configure_input, configure +from Moore import options parser = argparse.ArgumentParser() parser.add_argument('input', help='Input filename') @@ -52,43 +47,35 @@ def advance_HLT(decision): if not TES['/Event']: sys.exit("Did not find positive {0} decision".format(decision)) - odin = TES["/Event/DAQ/ODIN"] - print(f"Processing event {odin.eventNumber()}") - # skip an event that seems to be selected in v3 but not v2 platforms - # FIXME this is very fragile, as is the whole test, and it particular - # the check for a minimum size of containers. - if odin.eventNumber() == 247685: - continue - reports = TES['/Event/Hlt2/DecReports'] report = reports.decReport('{0}Decision'.format(decision)) if report.decision() == 1: break - return -##Prepare application -LHCbApp( - DataType="Upgrade", - Simulation=True, - DDDBtag="dddb-20171126", - CondDBtag="sim-20171127-vc-md100", -) +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [args.input] +options.input_type = "ROOT" if args.input.find(".dst") != -1 else "MDF" +options.gaudipython_mode = True +config = configure_input(options) -algs = do_unpacking(input_process='Hlt2') -algs += [ - LHCb__UnpackRawEvent( - BankTypes=['ODIN'], RawBankLocations=["DAQ/RawBanks/ODIN"]), - createODIN(RawBanks="DAQ/RawBanks/ODIN"), -] +algs = do_unpacking( + input_process='Hlt2', + has_mc_data=(options.input_type == "ROOT"), + stream='') + +cf_node = CompositeNode( + 'persistereco', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) -app = ApplicationMgr(TopAlg=algs) -app.ExtSvc += [configured_ann_svc()] +config.update(configure(options, cf_node)) -IOExtension().inputFiles([args.input], clear=True) -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) from Gaudi.Configuration import INFO diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py index fa2d0b41ce5..cc6336bb263 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py @@ -15,11 +15,10 @@ Runs over the output file passed as the last argument to this script. """ import GaudiPython as GP -from GaudiConf import IOExtension from GaudiConf.reading import do_unpacking -from Configurables import ApplicationMgr, LHCbApp -from PyConf.application import configured_ann_svc -LHCb = GP.gbl.LHCb +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure +from Moore import options import argparse @@ -29,16 +28,30 @@ parser.add_argument('hlt2_manifest', help='HLT2 JSON manifest dump') args = parser.parse_args() # Change the tags if required -LHCbApp( - DataType="Upgrade", - Simulation=True, - DDDBtag="dddb-20201211", - CondDBtag="sim-20201218-vc-md100", -) +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20201211" +options.conddb_tag = "sim-20201218-vc-md100" +options.input_files = [args.input] +options.input_type = "ROOT" +options.gaudipython_mode = True -IOExtension().inputFiles([args.input], clear=True) +config = configure_input(options) + +algs = do_unpacking(input_process='Hlt2', stream='') + +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) + +config.update(configure(options, cf_node)) + +appMgr = GP.AppMgr() +TES = appMgr.evtsvc() +appMgr.run(1) -stream = "/Event/HLT2" flavour_tags = ['FlavourTags'] locations = [ @@ -47,15 +60,7 @@ locations = [ ] + [f'/Event/HLT2/Hlt2B2JpsiKModified/{ft}' for ft in flavour_tags ] + [f'/Event/HLT2/Hlt2B2JpsiK/{ft}' for ft in flavour_tags] -algs = do_unpacking(input_process="Hlt2") - -app = ApplicationMgr(TopAlg=algs) -app.ExtSvc += [configured_ann_svc()] - -appMgr = GP.AppMgr() -TES = appMgr.evtsvc() -appMgr.run(1) - +n = 0 while TES['/Event/HLT2']: dec_rep = TES['/Event/Hlt2/DecReports'] if not dec_rep: print("could not obtain Hlt2 decisions") @@ -121,5 +126,6 @@ while TES['/Event/HLT2']: print("N tag particles", t.taggerParts().size()) else: print("ERROR: no FlavourTags in Hlt2B2JpsiKModified") - + n = n + 1 + if n == 28: break # Avoid EndOfInput warning appMgr.run(1) diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_thor_selections.py b/Hlt/Hlt2Conf/tests/options/hlt2_thor_selections.py index 9e825a70668..2b8adffa5b5 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_thor_selections.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_thor_selections.py @@ -98,9 +98,17 @@ def make_lines(): options.evt_max = 100 +options.root_ioalg_name = 'RootIOAlgExt' options.output_file = "hlt2_thor_selections.dst" options.output_type = "ROOT" options.output_manifest_file = "hlt2_thor_selections.tck.json" +options.root_ioalg_opts = { + 'IgnorePaths': [ + '/Event/Gen/Collisions', '/Event/PrevPrev/Gen/Collisions', + '/Event/Prev/Gen/Collisions', '/Event/Next/Gen/Collisions', + '/Event/NextNext/Gen/Collisions' + ] +} public_tools = [stateProvider_with_simplified_geom()] with reconstruction.bind(from_file=False): config = run_moore(options, make_lines, public_tools) diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_with_hlt1_filtering.py b/Hlt/Hlt2Conf/tests/options/hlt2_with_hlt1_filtering.py index 9627c410124..f6cbcadd576 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_with_hlt1_filtering.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_with_hlt1_filtering.py @@ -14,6 +14,7 @@ from Moore import options, run_moore from Moore.lines import Hlt2Line from RecoConf.global_tools import stateProvider_with_simplified_geom +from PyConf.application import configure_input, create_or_reuse_rootIOAlg def filter_hlt1_line(name="Hlt2FilterHlt1", prescale=1): @@ -28,5 +29,9 @@ def make_lines(): return [filter_hlt1_line()] +# precreate RootIOAlg as we only have lines using the unpacker machinery which relies on it to exist +config = configure_input(options) +create_or_reuse_rootIOAlg(options) + public_tools = [stateProvider_with_simplified_geom()] run_moore(options, make_lines, public_tools) diff --git a/Hlt/Hlt2Conf/tests/options/hlt_filters_test.py b/Hlt/Hlt2Conf/tests/options/hlt_filters_test.py index 523f5f09ee1..8b0ff1eee43 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt_filters_test.py +++ b/Hlt/Hlt2Conf/tests/options/hlt_filters_test.py @@ -39,7 +39,6 @@ from PyConf.Algorithms import VPRetinaFullClustering # $HLT1CONFROOT/tests/options/allen_hlt1_mdf_input.py # To reproduce do # ./Moore/run gaudirun.py Moore/Hlt/Hlt1Conf/tests/qmtest/persistency.qms/allen_mdf_write.qmt -options.evt_max = 1000 options.simulation = True options.data_type = 'Upgrade' diff --git a/Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py b/Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py index 7850f2ea456..d67a5846854 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py +++ b/Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py @@ -34,7 +34,7 @@ options.input_files = input_files options.input_manifest_file = "hlt_filterstest_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = -1 +options.evt_max = 96 options.simulation = True options.data_type = 'Upgrade' options.dddb_tag = 'dddb-20171126' diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py index 9dd825ab4fc..297d8782985 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py @@ -19,16 +19,12 @@ Find number->RawBank info at https://gitlab.cern.ch/lhcb/LHCb/-/blob/master/Even import argparse import GaudiPython as GP -from GaudiConf import IOExtension -from Configurables import ( - ApplicationMgr, - LHCbApp, - IODataManager, - HistogramPersistencySvc, -) +from Configurables import HistogramPersistencySvc +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure +from Moore import options from GaudiConf.reading import do_unpacking -from PyConf.application import configured_ann_svc from Hlt2Conf.check_output import ( check_MCoutput, check_banks, @@ -37,7 +33,6 @@ from Hlt2Conf.check_output import ( check_decreports, check_hlt2_topo_candidates, ) -from DDDB.CheckDD4Hep import UseDD4Hep parser = argparse.ArgumentParser() parser.add_argument('-i', type=str, help='Input MDF or DST') @@ -54,21 +49,25 @@ parser.add_argument( '-topo', action="store_true", help='Check that Topo candidates from HLT2 are present') +parser.add_argument( + '-usemc', action="store_true", help='Use MC data from the inpu tfile') args = parser.parse_args() assert args.p == "Spruce" or args.p == "Turbo", 'input_process is Turbo (passthrough sprucing) or Spruce' ##Prepare application -LHCbApp( - DataType="Upgrade", - Simulation=True, - DDDBtag="dddb-20171126", - CondDBtag="sim-20171127-vc-md100", -) -if not UseDD4Hep: - from Configurables import CondDB - CondDB(Upgrade=True) +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [args.i] +options.input_manifest_file = args.t +options.input_type = 'ROOT' +options.root_ioalg_name = 'RootIOAlgExt' +options.evt_max = args.n if args.n else -1 +options.gaudipython_mode = True +config = configure_input(options) input_process = args.p stream = args.s @@ -84,21 +83,20 @@ if input_process == "Turbo": algs = do_unpacking( input_process=input_process, stream=stream, - simulation=True, + has_mc_data=args.usemc, raw_event_format=0.3) -app = ApplicationMgr(TopAlg=algs) -app.ExtSvc += [configured_ann_svc(json_file=args.t)] +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) + +config.update(configure(options, cf_node, stream=stream)) -IOExtension().inputFiles([args.i], clear=True) -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) -#from Configurables import MessageSvc -#MessageSvc().setDebug = ['UnpackDstDataBank'] - appMgr = GP.AppMgr() TES = appMgr.evtsvc() appMgr.run(1) diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py index 59635c1978f..394c2ad1c4c 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py @@ -21,15 +21,11 @@ from Hlt2Conf.check_output import ( from Hlt2Conf.lines.b_to_open_charm import sprucing_lines as spruce_b2oc_lines spruce_b2oc_lines.pop('SpruceB2OC_BdToDsmK_DsmToHHH_FEST') from Hlt2Conf.sprucing_settings.Sprucing_2022_1_production import fulllinedict, turbolinedict, turcallinedict -from PyConf.application import configured_ann_svc from GaudiConf.reading import do_unpacking -from Configurables import ( - ApplicationMgr, - LHCbApp, - IODataManager, - HistogramPersistencySvc, -) -from GaudiConf import IOExtension +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure +from Moore import options +from Configurables import HistogramPersistencySvc import argparse import cppyy @@ -82,10 +78,15 @@ print("rb_to_check ", args.rb_to_check) print("rb_to_check_not ", args.rb_to_check_not) # Prepare application -LHCbApp( - DataType="Upgrade", - Simulation=False, -) +options.data_type = "Upgrade" +options.simulation = False +options.geometry_version = "run3/trunk" +options.conditions_version = "master" +options.input_files = [args.input] +options.input_manifest_file = args.manifest +options.input_type = 'ROOT' +options.gaudipython_mode = True +config = configure_input(options) # settings for passthrough data. Only one fired line of first evt is checked in a test. process = "Spruce" if args.job_type == "excl" else "Turbo" @@ -93,15 +94,17 @@ process = "Spruce" if args.job_type == "excl" else "Turbo" algs = do_unpacking( input_process=process, stream=args.stream, - simulation=False, + has_mc_data=False, raw_event_format=0.3) -mgr = ApplicationMgr(TopAlg=algs) -mgr.ExtSvc += [configured_ann_svc(json_file=args.manifest)] +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) + +config.update(configure(options, cf_node, stream=args.stream)) -IOExtension().inputFiles([args.input], clear=True) -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) @@ -114,10 +117,11 @@ cppyy.gbl.DataSvcHelpers.RegistryEntry.__bool__ = lambda x: True raweventloc = f'/Event/{args.stream}/RawEvent' -appMgr.run(1) -TES.dump() nevt = 5 for i in range(nevt): + appMgr.run(1) + if i == 1: + TES.dump() print('Checking next event.') if not TES['/Event']: break @@ -185,4 +189,3 @@ for i in range(nevt): for k in sprucefired: prefix = '/Event/Spruce/' + k check_particles(TES, prefix.removesuffix("Decision")) - appMgr.run(1) diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_extraoutputs.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_extraoutputs.py index 158c0d98564..8bc3f0bcb87 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_extraoutputs.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_extraoutputs.py @@ -14,16 +14,11 @@ import argparse import GaudiPython as GP -from GaudiConf import IOExtension -from Configurables import ( - ApplicationMgr, - CondDB, - LHCbApp, - IODataManager, - HistogramPersistencySvc, -) +from Configurables import HistogramPersistencySvc +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure +from Moore import options -from PyConf.application import configured_ann_svc from PyConf.packing import default_persistable_locations from GaudiConf.reading import do_unpacking @@ -44,27 +39,31 @@ parser.add_argument('t', type=str, help='.tck.json file from the job') args = parser.parse_args() -##Prepare application -LHCbApp( - DataType="Upgrade", - Simulation=True, - DDDBtag="dddb-20171126", - CondDBtag="sim-20171127-vc-md100", -) -CondDB(Upgrade=True) +# Prepare application +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [args.i] +options.input_type = 'ROOT' +options.gaudipython_mode = True +config = configure_input(options) input_process = "Spruce" stream = 'default' dec_to_check = "Spruce_Test_line_extraoutputs" -algs = do_unpacking(input_process=input_process, raw_event_format=0.3) +algs = do_unpacking( + input_process=input_process, raw_event_format=0.3, stream=stream) + +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) -app = ApplicationMgr(TopAlg=algs) -app.ExtSvc += [configured_ann_svc()] +config.update(configure(options, cf_node)) -IOExtension().inputFiles([args.i], clear=True) -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_persistreco.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_persistreco.py index cefb88e18ed..5540c908915 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_persistreco.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_persistreco.py @@ -13,18 +13,13 @@ import argparse import GaudiPython as GP -from GaudiConf import IOExtension -from Configurables import ( - ApplicationMgr, - CondDB, - LHCbApp, - IODataManager, - HistogramPersistencySvc, -) +from Configurables import HistogramPersistencySvc +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure +from Moore import options from PyConf.packing import default_persistable_locations from GaudiConf.reading import do_unpacking -from PyConf.application import configured_ann_svc from Hlt2Conf.check_output import ( check_persistreco, @@ -44,26 +39,27 @@ parser.add_argument('t', type=str, help='.tck.json file from the job') args = parser.parse_args() -##Prepare application -LHCbApp( - DataType="Upgrade", - Simulation=True, - DDDBtag="dddb-20171126", - CondDBtag="sim-20171127-vc-md100", -) -CondDB(Upgrade=True) +# Prepare application +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [args.i] +options.input_type = 'ROOT' +options.gaudipython_mode = True +config = configure_input(options) -dec_to_check = "Spruce_Test_line_persistreco" -stream = 'default' +algs = do_unpacking( + input_process="Spruce", raw_event_format=0.3, has_mc_data=False) -algs = do_unpacking(input_process="Spruce", raw_event_format=0.3) +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.NONLAZY_OR, + children=algs, + force_order=True) -appmgr = ApplicationMgr(TopAlg=algs) -appmgr.ExtSvc += [configured_ann_svc()] +config.update(configure(options, cf_node)) -IOExtension().inputFiles([args.i], clear=True) -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) @@ -89,7 +85,7 @@ for ii in range(nevents): hlt2decisions = check_decreports( TES, decs=['Hlt2Topo2Body', 'Hlt2Topo3Body']) sprucedecisions = check_decreports( - TES, decs=[dec_to_check], stage='Spruce') + TES, decs=["Spruce_Test_line_persistreco"], stage='Spruce') for k, v in sprucedecisions.items(): if v: @@ -107,4 +103,4 @@ for ii in range(nevents): error("persistreco objects not being saved correctly.") # Check the Rich (=9) RawBank is present - check_banks(TES, stream, banks=[9]) + check_banks(TES, 'default', banks=[9]) diff --git a/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py b/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py index ff91146def0..871582703ae 100644 --- a/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py +++ b/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py @@ -17,19 +17,15 @@ import argparse import GaudiPython as GP LHCb = GP.gbl.LHCb -from GaudiConf import IOExtension -from Configurables import ( - ApplicationMgr, - LHCbApp, - IODataManager, - HistogramPersistencySvc, -) +from PyConf.control_flow import CompositeNode, NodeLogic +from Configurables import HistogramPersistencySvc from GaudiConf.reading import do_unpacking -from PyConf.application import configured_ann_svc +from PyConf.application import configure_input, configure + +from Moore import options from Hlt2Conf.check_output import check_particles, check_decreports -from DDDB.CheckDD4Hep import UseDD4Hep def error(msg): @@ -51,6 +47,7 @@ parser.add_argument('input', help='Input filename') parser.add_argument('manifest', help='JSON manifest dump') parser.add_argument('input_process', help='Hlt2 or Spruce') parser.add_argument('stream', help='Stream to test as defined in options') +parser.add_argument('nevents', type=int, help='Number of events to process') args = parser.parse_args() @@ -58,25 +55,34 @@ args = parser.parse_args() if not (args.input_process == "Hlt2" or args.input_process == "Spruce"): error("input_process not supported") -##Prepare application -LHCbApp( - DataType="Upgrade", - Simulation=True, - DDDBtag="dddb-20171126", - CondDBtag="sim-20171127-vc-md100", -) -if not UseDD4Hep: - from Configurables import CondDB - CondDB(Upgrade=True) - -algs = do_unpacking(input_process=args.input_process, stream=args.stream) - -mgr = ApplicationMgr(TopAlg=algs) -mgr.ExtSvc += [configured_ann_svc()] - -IOExtension().inputFiles([args.input], clear=True) -# Disable warning about not being able to navigate ancestors -IODataManager(DisablePFNWarning=True) +# Prepare application +options.data_type = "Upgrade" +options.simulation = True +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [args.input] +options.input_type = 'MDF' if args.input.endswith('.mdf') else 'ROOT' +options.gaudipython_mode = True +config = configure_input(options) + +if args.input_process == "Hlt2": + stream = '' + raweventloc = '/Event/DAQ/RawEvent' +else: + stream = args.stream + raweventloc = f'/Event/{args.stream}/RawEvent' + +algs = do_unpacking( + input_process=args.input_process, stream=stream, has_mc_data=False) + +cf_node = CompositeNode( + 'checking', + combine_logic=NodeLogic.LAZY_AND, + children=algs, + force_order=True) + +config.update(configure(options, cf_node, stream=stream)) + # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) @@ -88,14 +94,9 @@ TES = appMgr.evtsvc() import cppyy cppyy.gbl.DataSvcHelpers.RegistryEntry.__bool__ = lambda x: True -#Raw event location -if args.input_process == "Hlt2": - raweventloc = '/Event/DAQ/RawEvent' -else: - raweventloc = f'/Event/{args.stream}/RawEvent' - first_event = True -while True: +n = 0 +while n < args.nevents: appMgr.run(1) if not TES['/Event']: break @@ -139,7 +140,7 @@ while True: if "A" in args.stream: # RawBank IDs as per LHCb/Event/DAQEvent/include/Event/RawBank.h if args.input_process == 'Hlt2': - saved_banks = {9, 13, 15, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} + saved_banks = {9, 13, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} elif args.input_process == 'Spruce': saved_banks = {9, 13, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} else: @@ -160,7 +161,7 @@ while True: # RawBank IDs as per LHCb/Event/DAQEvent/include/Event/RawBank.h # Rich bank removed if args.input_process == 'Hlt2': - saved_banks = {13, 15, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} + saved_banks = {13, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} elif args.input_process == 'Spruce': saved_banks = {13, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} else: @@ -227,5 +228,4 @@ while True: or (rec_summary.info(rec_summary.nFTClusters, -1) < 1): error("Wrong values in RecSummary for this stream") print(rec_summary) - - appMgr.run(1) + n += 1 diff --git a/Hlt/Hlt2Conf/tests/options/test_soa_packing.py b/Hlt/Hlt2Conf/tests/options/test_soa_packing.py index 3d522affb87..a926c0d6c11 100644 --- a/Hlt/Hlt2Conf/tests/options/test_soa_packing.py +++ b/Hlt/Hlt2Conf/tests/options/test_soa_packing.py @@ -13,113 +13,76 @@ Test the persistency of SOA objects - Tracks """ -from Configurables import (ApplicationMgr, LHCbApp, HltPackedBufferWriter, - HltPackedBufferDecoder, SOATrackPacker, SOAPVPacker) - -from PyConf.application import configured_ann_svc, default_raw_event - +from PyConf.Algorithms import HltPackedBufferWriter, HltPackedBufferDecoder, SOATrackPacker, SOAPVPacker from PyConf.filecontent_metadata import register_encoding_dictionary -from PRConfig import TestFileDB from RecoConf.hlt2_tracking import make_hlt2_tracks_without_UT, convert_tracks_to_v3_from_v1, get_persistable_tracks_per_type from RecoConf.legacy_rec_hlt1_tracking import make_reco_pvs from PyConf.packing import persistable_location -from Configurables import GaudiSequencer -from PyConf.dataflow import dataflow_config - - -def _data_deps(handle): - def __walk(visited, found, top): - - if top.name in visited: return - visited.append(top.name) - found.append(top) - for handles in top.inputs.values(): - handles = handles if isinstance(handles, list) else [handles] - for handle in handles: - __walk(visited, found, handle.producer) - - visited = [] - found = [] - __walk(visited, found, handle.producer) - return found - - -with default_raw_event.bind(raw_event_format=0.5): - hlt2_tracks = make_hlt2_tracks_without_UT( - light_reco=True, fast_reco=False, use_pr_kf=True) - # track conversion to v3 for muon / calo - persisted_tracks = get_persistable_tracks_per_type(hlt2_tracks) - tracks_v3, tracks_rels = convert_tracks_to_v3_from_v1(persisted_tracks) - - # PVs - pvs = make_reco_pvs(hlt2_tracks['Velo'], persistable_location('PVs')) - pv_algs = _data_deps(pvs["v3"]) - track_algs = _data_deps(tracks_v3["Long"]) - track_algs.reverse() - pv_algs.reverse() - algs = track_algs + pv_algs - - configuration = dataflow_config() - for alg in algs: - configuration.update(alg.configuration()) - algs, _ = configuration.apply() - - TES = "/Event/Rec" - locations = [] - locations.append(tracks_v3["Long"].location) - locations.append(pvs["v3"].location) - - encoding_key = int( - register_encoding_dictionary("PackedObjectLocations", - sorted(locations)), 16) - - track_packer = SOATrackPacker( - InputName=[tracks_v3["Long"].location], - OutputName=TES + "/Buffers/Tracks", - EnableCheck=True, - OutputLevel=2, - EncodingKey=encoding_key) - - pv_packer = SOAPVPacker( - InputName=[pvs["v3"].location], - OutputName=TES + "/Buffers/PVs", - EnableCheck=True, - OutputLevel=2, - EncodingKey=encoding_key) - - # Writer - bank_writer = HltPackedBufferWriter( - PackedContainers=[ - track_packer.OutputName.Path, pv_packer.OutputName.Path - ], - OutputView="/Event/RawBanks/DstData", - OutputLevel=2, - SourceID="Hlt2") - - # Decoder - bank_decoder = HltPackedBufferDecoder( - RawBanks=bank_writer.OutputView, OutputLevel=2, SourceID="Hlt2") - - algs += [track_packer, pv_packer, bank_writer, bank_decoder] - seq = GaudiSequencer("Seq", Members=algs) - - ApplicationMgr(TopAlg=[seq], ExtSvc=[configured_ann_svc(name='HltANNSvc')]) - - app = LHCbApp( - DataType="Upgrade", - Simulation=True, - ) - - #app.OutputLevel=2 - app.EvtMax = 5 - from DDDB.CheckDD4Hep import UseDD4Hep - if UseDD4Hep: - from Configurables import DDDBConf - DDDBConf().GeometryVersion = 'run3/before-rich1-geom-update-26052022' - - # Pick a file that has the reconstruction available - # Events are not really used, this is a dummy setup - f = TestFileDB.test_file_db['upgrade_Sept2022_minbias_0fb_md_xdigi'] - - f.setqualifiers(configurable=app) - f.run(configurable=app, withDB=True) +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure, default_raw_banks +from Moore import options +from DDDB.CheckDD4Hep import UseDD4Hep + +# first ocnfigure input +options.data_type = "Upgrade" +options.simulation = True +options.input_raw_format = 0.5 +options.set_input_and_conds_from_testfiledb( + "upgrade_Sept2022_minbias_0fb_md_xdigi") +if UseDD4Hep: + options.geometry_version = 'run3/before-rich1-geom-update-26052022' +options.evt_max = 5 +config = configure_input(options) + +# now create control flow +hlt2_tracks = make_hlt2_tracks_without_UT( + light_reco=True, fast_reco=False, use_pr_kf=True) +# track conversion to v3 for muon / calo +persisted_tracks = get_persistable_tracks_per_type(hlt2_tracks) +tracks_v3, tracks_rels = convert_tracks_to_v3_from_v1(persisted_tracks) + +# PVs +pvs = make_reco_pvs(hlt2_tracks['Velo'], persistable_location('PVs')) + +locations = [] +locations.append(tracks_v3["Long"].location) +locations.append(pvs["v3"].location) + +encoding_key = int( + register_encoding_dictionary("PackedObjectLocations", sorted(locations)), + 16) + +track_packer = SOATrackPacker( + InputName=[tracks_v3["Long"]], + EnableCheck=True, + OutputLevel=2, + EncodingKey=encoding_key) + +pv_packer = SOAPVPacker( + InputName=[pvs["v3"]], + EnableCheck=True, + OutputLevel=2, + EncodingKey=encoding_key) + +# Writer +bank_writer = HltPackedBufferWriter( + PackedContainers=[ + track_packer.OutputName.location, pv_packer.OutputName.location + ], + OutputLevel=2, + SourceID="Hlt2") + +# Decoder +bank_decoder = HltPackedBufferDecoder( + RawBanks=bank_writer.OutputView, + OutputLevel=2, + SourceID="Hlt2", + DecReports=default_raw_banks("HltDecReports")) + +# finally run the test +cf_node = CompositeNode( + 'Seq', + combine_logic=NodeLogic.LAZY_AND, + children=[track_packer, pv_packer, bank_writer, bank_decoder], + force_order=True) +config.update(configure(options, cf_node)) diff --git a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_excl_spruce_2022_data_b2cc_check.qmt b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_excl_spruce_2022_data_b2cc_check.qmt deleted file mode 100644 index 19824a4f97b..00000000000 --- a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_excl_spruce_2022_data_b2cc_check.qmt +++ /dev/null @@ -1,43 +0,0 @@ - - - - - - - sprucing.test_excl_spruce_2022_dataPASS - - -python -300 - - $HLT2CONFROOT/tests/options/sprucing/spruce_check_2022_data.py - -input - spruce_all_lines_production.b2cc.dst - -manifest - spruce_all_lines_production.tck.json - -job_type - excl - -stream - b2cc - -true - - -from Moore.qmtest.exclusions import remove_known_warnings -countErrorLines({"FATAL": 0, "WARNING": 0, "ERROR": 0}, - stdout=remove_known_warnings(stdout)) - - - - diff --git a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_example_realtime_dstinput_check.qmt b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_example_realtime_dstinput_check.qmt index d55d3a802a3..af8a7d7b5bd 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_example_realtime_dstinput_check.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_example_realtime_dstinput_check.qmt @@ -29,6 +29,7 @@ Runs over spruce_realtimereco_dstinput.dst from spruce_example_realtime_dstinput Spruce -s test + -usemc true diff --git a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_example_realtime_dstinput_gaudirun_check.qmt b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_example_realtime_dstinput_gaudirun_check.qmt index b409ca92486..c66175f57e1 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_example_realtime_dstinput_gaudirun_check.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_example_realtime_dstinput_gaudirun_check.qmt @@ -29,6 +29,7 @@ Runs over spruce_realtimereco_dstinput.dst from spruce_example_realtime_dstinput Spruce -s default + -usemc true diff --git a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_passthrough_dstinput_check.qmt b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_passthrough_dstinput_check.qmt index e2b87374bf5..6e04e7885f1 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_passthrough_dstinput_check.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_passthrough_dstinput_check.qmt @@ -28,6 +28,7 @@ Test Sprucing output. Runs over spruce_passthrough_dstinput.dst from spruce_pass Turbo -s default + -usemc true diff --git a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_passthrough_dstinput_gaudirun_check.qmt b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_passthrough_dstinput_gaudirun_check.qmt index cd2a5bbbeb0..a0f1f9737d1 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_passthrough_dstinput_gaudirun_check.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_spruce_passthrough_dstinput_gaudirun_check.qmt @@ -28,6 +28,7 @@ Test Sprucing output. Runs over spruce_passthrough_dstinput.dst from spruce_pass Turbo -s default + -usemc true diff --git a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_monitoring_rb_check.qmt b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_monitoring_rb_check.qmt index ba3fa78677b..6a9561fc29c 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_monitoring_rb_check.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_monitoring_rb_check.qmt @@ -33,11 +33,13 @@ Runs over the output of test_turcal_spruce_2022_data 1673649138477 true +../refs/test_turcal_spruce_2022_data_monitoring_rb_check.ref -from Moore.qmtest.exclusions import remove_known_warnings +from Moore.qmtest.exclusions import remove_known_warnings, preprocessor countErrorLines({"FATAL": 0, "WARNING": 0, "ERROR": 1}, stdout=remove_known_warnings(stdout)) +validateWithReference(preproc=preprocessor) diff --git a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_pid_rb_check.qmt b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_pid_rb_check.qmt index cd1798104a4..65c0fd4c987 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_pid_rb_check.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_pid_rb_check.qmt @@ -33,11 +33,13 @@ Runs over the output of test_turcal_spruce_2022_data 1673649138477 true +../refs/test_turcal_spruce_2022_data_pid_rb_check.ref -from Moore.qmtest.exclusions import remove_known_warnings +from Moore.qmtest.exclusions import remove_known_warnings, preprocessor countErrorLines({"FATAL": 0, "WARNING": 0, "ERROR": 0}, stdout=remove_known_warnings(stdout)) +validateWithReference(preproc=preprocessor) diff --git a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_trackeff_rb_check.qmt b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_trackeff_rb_check.qmt index 02633e69ff6..2248de638a9 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_trackeff_rb_check.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/sprucing.qms/test_turcal_spruce_2022_data_trackeff_rb_check.qmt @@ -33,11 +33,13 @@ Runs over the output of test_turcal_spruce_2022_data 1673649138477 true +../refs/test_turcal_spruce_2022_data_trackeff_rb_check.ref -from Moore.qmtest.exclusions import remove_known_warnings +from Moore.qmtest.exclusions import remove_known_warnings, preprocessor countErrorLines({"FATAL": 0, "WARNING": 0, "ERROR": 1}, stdout=remove_known_warnings(stdout)) +validateWithReference(preproc=preprocessor) - \ No newline at end of file + diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt index 604d2b5d23c..28739901dde 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt @@ -24,6 +24,7 @@ Test HLT2 streaming. Runs over hlt2_test_persistreco_fromfile.test_stream_A.mdf hlt2_test_streaming.tck.json Hlt2 test_stream_A + 1000 true diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt index 2c872d9b57d..8b039c080e8 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt @@ -24,6 +24,7 @@ Test HLT2 streaming. Runs over hlt2_test_persistreco_fromfile.test_stream_B.mdf hlt2_test_streaming.tck.json Hlt2 test_stream_B + 1000 true diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt index ffb38fdc884..e858549fe69 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt @@ -21,7 +21,7 @@ Check that the output of the file contains the candidates corresponding to the d $HLT2CONFROOT/options/hlt2_check_output.py sprucing_hlt2_all_lines_with_reco_with_streams_mdf.mdf - hlt2_all_lines_with_reco_with_streams_mdf.tck.json + 0 from Configurables import HiveDataBrokerSvc diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt index 731d4839614..de111f4c8aa 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt @@ -25,6 +25,7 @@ Runs over hlt2_test_persistreco_fromfile.test_stream_A.mdf from hlt2_test_stream spruce_streaming.tck.json Spruce test_stream_A + 5 true diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt index 1ad9996ff89..42a62830a5a 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt @@ -25,6 +25,7 @@ Runs over hlt2_test_persistreco_fromfile.test_stream_B.mdf from hlt2_test_stream spruce_streaming.tck.json Spruce test_stream_B + 5 true diff --git a/Hlt/Hlt2Conf/tests/qmtest/test_hlt2_check_output_with_reco.qmt b/Hlt/Hlt2Conf/tests/qmtest/test_hlt2_check_output_with_reco.qmt index d09b3822535..2c85b8d32e4 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/test_hlt2_check_output_with_reco.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/test_hlt2_check_output_with_reco.qmt @@ -21,7 +21,7 @@ Make sure HLT2 configures and runs all lines without errors on reconstructed dat $HLT2CONFROOT/options/hlt2_check_output.py hlt2_all_lines_with_reco.dst - hlt2_all_lines_with_reco.tck.json + 11 from Configurables import HiveDataBrokerSvc diff --git a/Hlt/Hlt2Conf/tests/qmtest/test_persistreco_check_flavourtags.qmt b/Hlt/Hlt2Conf/tests/qmtest/test_persistreco_check_flavourtags.qmt index 72982ad1135..a7175f560b4 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/test_persistreco_check_flavourtags.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/test_persistreco_check_flavourtags.qmt @@ -31,9 +31,9 @@ from Moore.qmtest.exclusions import remove_known_warnings countErrorLines({"FATAL": 0, "WARNING": 0, "ERROR": 0}, stdout=remove_known_warnings(stdout)) -from Moore.qmtest.exclusions import skip_initialize, skip_scheduler, counter_preprocessor +from Moore.qmtest.exclusions import skip_initialize, LineSkipper, counter_preprocessor from RecConf.QMTest.exclusions import preprocessor as RecPreprocessor -validateWithReference(preproc = skip_initialize + RecPreprocessor + skip_scheduler, counter_preproc = counter_preprocessor) +validateWithReference(preproc = skip_initialize + RecPreprocessor + LineSkipper(strings=["HLTControlFlowMgr"]), counter_preproc = counter_preprocessor) diff --git a/Hlt/Hlt2Conf/tests/qmtest/test_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt b/Hlt/Hlt2Conf/tests/qmtest/test_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt index ffd5069ff4d..d18d08c6d76 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/test_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/test_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt @@ -21,7 +21,7 @@ Check that the output of the file contains the candidates corresponding to the d $HLT2CONFROOT/options/hlt2_check_output.py turbo_hlt2_all_lines_with_reco_with_streams_mdf.mdf - hlt2_all_lines_with_reco_with_streams_mdf.tck.json + 16 from Configurables import HiveDataBrokerSvc diff --git a/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_monitoring_rb_check.ref b/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_monitoring_rb_check.ref new file mode 100644 index 00000000000..95a140ea685 --- /dev/null +++ b/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_monitoring_rb_check.ref @@ -0,0 +1,297 @@ +# setting LC_ALL to "C" +input pass_turcal_lines_production.monitoring_raw.dst +manifest pass_turcal_lines_production.tck.json +job_type pass_turcal +stream monitoring_raw +rb_to_check [16, 73, 64, 9, 13, 84, 77] +rb_to_check_not None +/***** User ApplicationOptions/ApplicationOptions ************************************************** +|-append_decoding_keys_to_output_manifest = True (default: True) +|-auditors = [] (default: []) +|-conddb_tag = '' (default: '') +|-conditions_version = 'master' (default: '') +|-control_flow_file = '' (default: '') +|-data_flow_file = '' (default: '') +|-data_type = 'Upgrade' (default: 'Upgrade') +|-dddb_tag = '' (default: '') +|-event_store = 'HiveWhiteBoard' (default: 'HiveWhiteBoard') +|-evt_max = -1 (default: -1) +|-first_evt = 0 (default: 0) +|-gaudipython_mode = True (default: False) +|-geometry_version = 'run3/trunk' (default: '') +|-histo_file = '' (default: '') +|-input_files = ['pass_turcal_lines_production.monitoring_raw.dst'] (default: []) +|-input_manifest_file = 'pass_turcal_lines_production.tck.json' (default: '') +|-input_process = '' (default: '') +|-input_raw_format = 0.5 (default: 0.5) +|-input_type = 'ROOT' (default: '') +|-ioalg_buffer_nb_events = 40 (default: 40) +|-lines_maker = None +|-mdf_ioalg_name = 'IOAlgFileRead' (default: 'IOAlgFileRead') +|-memory_pool_size = 10485760 (default: 10485760) +|-monitoring_file = '' (default: '') +|-msg_svc_format = '% F%35W%S %7W%R%T %0W%M' (default: '% F%35W%S %7W%R%T %0W%M') +|-msg_svc_time_format = '%Y-%m-%d %H:%M:%S UTC' (default: '%Y-%m-%d %H:%M:%S UTC') +|-n_event_slots = 1 (default: -1) +|-n_threads = 1 (default: 1) +|-ntuple_file = '' (default: '') +|-output_file = '' (default: '') +|-output_level = 3 (default: 3) +|-output_manifest_file = '' (default: '') +|-output_type = '' (default: '') +|-persistreco_version = 1.0 (default: 1.0) +|-phoenix_filename = '' (default: '') +|-preamble_algs = [] (default: []) +|-print_freq = 10000 (default: 10000) +|-python_logging_level = 20 (default: 20) +|-require_specific_decoding_keys = [] (default: []) +|-root_ioalg_name = 'RootIOAlg' (default: 'RootIOAlg') +|-root_ioalg_opts = {} (default: {}) +|-scheduler_legacy_mode = True (default: True) +|-simulation = False (default: None) +|-write_decoding_keys_to_git = True (default: True) +\----- (End of User ApplicationOptions/ApplicationOptions) ----------------------------------------- +ApplicationMgr SUCCESS +==================================================================================================================================== + Welcome to ApplicationMgr (GaudiCoreSvc v38r0) + running on lblhcbpr20.cern.ch on Thu Jan 25 16:37:03 2024 +==================================================================================================================================== +ApplicationMgr INFO Application Manager Configured successfully +HLTControlFlowMgr INFO Start initialization +HLTControlFlowMgr INFO Will not use an EventSelector. +HLTControlFlowMgr INFO Concurrency level information: +ApplicationMgr INFO Application Manager Initialized successfully +JobOptionsSvc INFO Properties are dumped into "sprucing.test_turcal_spruce_2022_data_monitoring_rb_check.joboptsdump" +ApplicationMgr INFO Application Manager Started successfully +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Hlt1PassThroughDecision', 'Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +regdecs : ['Hlt2Monitoring.*Decision'] +pos_lines_match ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +Hlt2 Fired ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particles has size 1 +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particle2VertexRelations has size 7 +proto: { Track 0x7f222131ac80 CaloHypos [] RichPID 0x7f22213086e0 MuonPID 0x7f2221317880 NeutralPID 0 ExtraInfo [ RichDLLe=-5.42089 RichDLLmu=-7.80538 RichDLLpi=0 RichDLLk=-1.73569 RichDLLp=-1.73569 RichPIDStatus=5059 RichDLLbt=-1.73569 RichDLLd=-1.73569 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 CaloTrMatch=0.534919 CaloElectronMatch=99.7216 CaloChargedEcal=1530.27 CaloChargedID=39219 CaloEcalE=955.164 CaloHcalE=5594.65 CaloClusChi2=0.534919 CaloEoverP=0.135481 EcalPIDe=-4.2216 HcalPIDe=-0.776087 HcalPIDmu=-0.59725 EcalPIDmu=0.346233 TrackChi2PerDof=1.29172 TrackNumDof=12 TrackType=3 TrackHistory=32 TrackP=7050.17 TrackPt=166.961 CombDLLe=-5.94058 CombDLLmu=-6.66018 CombDLLpi=0 CombDLLk=-1.73569 CombDLLp=-1.73569 CombDLLd=-1.73569 ProbNNe=0.866044 ProbNNpi=0.315874 ProbNNk=0.00570571 ProbNNp=0.00338157 ProbNNghost=0.871369 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passmonitoring_rawDecision': True} +check ['Passmonitoring_rawDecision'] +spruce Fired ['Passmonitoring_rawDecision'] +/Event +/Event/monitoring_raw +/Event/monitoring_raw/RawEvent +/Event/RootIOAlg +/Event/RootIOAlg/EventBufferLocation +/Event/DAQ +/Event/DAQ/RawBanks +/Event/DAQ/RawBanks/DstData +/Event/DAQ/RawBanks/HltDecReports +/Event/DAQ/RawBanks/HltRoutingBits +/Event/Hlt2 +/Event/Hlt2/DecReports +/Event/Spruce +/Event/Spruce/DecReports +/Event/HltPackedBufferDecoder_c2691b9b +/Event/HltPackedBufferDecoder_c2691b9b/OutputBuffers +/Event/HLT2 +/Event/HLT2/Rec +/Event/HLT2/Rec/Summary +/Event/HLT2/Rec/Calo +/Event/HLT2/Rec/Calo/SplitPhotons +/Event/HLT2/Rec/Calo/MergedPi0s +/Event/HLT2/Rec/Calo/Photons +/Event/HLT2/Rec/Calo/Electrons +/Event/HLT2/Rec/Track +/Event/HLT2/Rec/Track/Best +/Event/HLT2/Rec/Rich +/Event/HLT2/Rec/Rich/PIDs +/Event/HLT2/Rec/Muon +/Event/HLT2/Rec/Muon/MuonTracks +/Event/HLT2/Rec/Muon/MuonPID +/Event/HLT2/Rec/ProtoP +/Event/HLT2/Rec/ProtoP/Charged +/Event/HLT2/Rec/ProtoP/Neutrals +/Event/HLT2/Rec/Vertex +/Event/HLT2/Rec/Vertex/Primary +/Event/HLT2/FunctionalParticleMaker#4 +/Event/HLT2/FunctionalParticleMaker#4/Particles +/Event/HLT2/Hlt2Commissioning_KsToPimPip_LL +/Event/HLT2/Hlt2Commissioning_KsToPimPip_LL/decayVertices +/Event/HLT2/Hlt2Commissioning_KsToPimPip_LL/Particles +/Event/HLT2/Hlt2Commissioning_KsToPimPip_LL/Particle2VertexRelations +/Event/HLT2/FunctionalParticleMaker#7 +/Event/HLT2/FunctionalParticleMaker#7/Particles +/Event/HLT2/Hlt2Commissioning_L0ToPpPim_LL +/Event/HLT2/Hlt2Commissioning_L0ToPpPim_LL/decayVertices +/Event/HLT2/Hlt2Commissioning_L0ToPpPim_LL/Particles +/Event/HLT2/Hlt2Commissioning_L0ToPpPim_LL/Particle2VertexRelations +/Event/HLT2/Monitoring_Hlt1KsLine_Ks_for_InclKsKs +/Event/HLT2/Monitoring_Hlt1KsLine_Ks_for_InclKsKs/OutputVertices +/Event/HLT2/Monitoring_Hlt1KsLine_Ks_for_InclKsKs/OutputParticles +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/decayVertices +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particles +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particle2VertexRelations +/Event/Rec +/Event/Rec/NeutralPIDs +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Commissioning_KsToPimPip_LLDecision', 'Hlt2Commissioning_L0ToPpPim_LLDecision', 'Hlt2Hlt1PassThroughDecision', 'Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +regdecs : ['Hlt2Monitoring.*Decision'] +pos_lines_match ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +Hlt2 Fired ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particles has size 3 +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particle2VertexRelations has size 12 +proto: { Track 0x7f222131a520 CaloHypos [] RichPID 0x7f22213119d0 MuonPID 0x7f2221319650 NeutralPID 0 ExtraInfo [ RichDLLe=-14.5097 RichDLLmu=-2.61452 RichDLLpi=0 RichDLLk=6.45847 RichDLLp=17.4944 RichPIDStatus=6117 RichDLLbt=17.4944 RichDLLd=17.4944 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 InAccBrem=1 CaloTrMatch=32.4954 CaloElectronMatch=648.478 CaloBremMatch=-1 CaloChargedEcal=53292.3 CaloChargedID=42602 CaloBremTBEnergy=0 CaloBremHypoDeltaX=0 CaloBremBendingCorr=1 CaloEcalE=3155.18 CaloHcalE=92268.8 CaloClusChi2=32.4954 CaloEoverP=0.253741 CaloBremEnergy=0 CaloHasBrem=0 CaloBremHypoEnergy=-1 CaloBremHypoID=0 EcalPIDe=-3.91904 BremPIDe=-0.836268 HcalPIDe=-0.742248 HcalPIDmu=-0.891023 EcalPIDmu=-1.43462 TrackChi2PerDof=1.18203 TrackNumDof=23 TrackType=3 TrackHistory=32 TrackP=12434.7 TrackPt=388.234 CombDLLe=-7.93094 CombDLLmu=-5.68521 CombDLLpi=0 CombDLLk=6.45847 CombDLLp=17.4944 CombDLLd=17.4944 ProbNNe=0.00111882 ProbNNpi=0.221849 ProbNNk=0.00121681 ProbNNp=0.622002 ProbNNghost=0.716036 ] } +mothers: 3 firstdaughters: 2 +Spruce requested reports are {'Passmonitoring_rawDecision': True} +check ['Passmonitoring_rawDecision'] +spruce Fired ['Passmonitoring_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 239 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2LumiDecision', 'Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +regdecs : ['Hlt2Monitoring.*Decision'] +pos_lines_match ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +Hlt2 Fired ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particles has size 1 +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particle2VertexRelations has size 7 +proto: { Track 0x7f2220f119b0 CaloHypos [] RichPID 0x7f2220f13300 MuonPID 0x7f2221315630 NeutralPID 0 ExtraInfo [ RichDLLe=-4.08093 RichDLLmu=3.21426 RichDLLpi=0 RichDLLk=-44.9307 RichDLLp=-30.8411 RichPIDStatus=6082 RichDLLbt=-30.8411 RichDLLd=-30.8411 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 CaloTrMatch=-1 CaloElectronMatch=-1 CaloChargedEcal=-1 CaloChargedID=0 CaloEcalE=0 CaloHcalE=13777 CaloClusChi2=-1 CaloEoverP=0 EcalPIDe=-4.25653 HcalPIDe=-0.860269 HcalPIDmu=-1.2597 EcalPIDmu=1.19395 TrackChi2PerDof=1.59337 TrackNumDof=12 TrackType=3 TrackHistory=32 TrackP=21514.9 TrackPt=297.023 CombDLLe=-5.82849 CombDLLmu=3.90211 CombDLLpi=0 CombDLLk=-44.9307 CombDLLp=-30.8411 CombDLLd=-30.8411 ProbNNe=0.0254305 ProbNNpi=0.928309 ProbNNk=0.000353171 ProbNNp=0.00303171 ProbNNghost=0.217981 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passmonitoring_rawDecision': True} +check ['Passmonitoring_rawDecision'] +spruce Fired ['Passmonitoring_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +Check ERROR Expected raw bank 77 +RawBank 77 has size 0 +Lines that fired : ['Hlt2LumiDecision', 'Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +regdecs : ['Hlt2Monitoring.*Decision'] +pos_lines_match ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +Hlt2 Fired ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particles has size 2 +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particle2VertexRelations has size 10 +proto: { Track 0x7f2220e50b90 CaloHypos [] RichPID 0x7f222131a480 MuonPID 0x7f2220ebb4f0 NeutralPID 0 ExtraInfo [ RichDLLe=-1.96831 RichDLLmu=2.24422 RichDLLpi=0 RichDLLk=-32.7924 RichDLLp=-32.7924 RichPIDStatus=5026 RichDLLbt=-32.7924 RichDLLd=-32.7924 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 InAccBrem=1 CaloTrMatch=-1 CaloElectronMatch=-1 CaloBremMatch=-1 CaloChargedEcal=-1 CaloChargedID=0 CaloBremTBEnergy=0 CaloBremHypoDeltaX=0 CaloBremBendingCorr=1 CaloEcalE=0 CaloHcalE=0 CaloClusChi2=-1 CaloEoverP=0 CaloBremEnergy=0 CaloHasBrem=0 CaloBremHypoEnergy=-1 CaloBremHypoID=0 EcalPIDe=-4.35018 BremPIDe=-0.828353 HcalPIDe=0.658559 HcalPIDmu=-1.25297 EcalPIDmu=0.694352 TrackChi2PerDof=0.84211 TrackNumDof=20 TrackType=3 TrackHistory=32 TrackP=7968.78 TrackPt=362.539 CombDLLe=-4.86415 CombDLLmu=2.38802 CombDLLpi=0 CombDLLk=-32.7924 CombDLLp=-32.7924 CombDLLd=-32.7924 ProbNNe=0.73731 ProbNNpi=0.0716899 ProbNNk=0.0251855 ProbNNp=0.0440582 ProbNNghost=0.948573 ] } +mothers: 2 firstdaughters: 2 +Spruce requested reports are {'Passmonitoring_rawDecision': True} +check ['Passmonitoring_rawDecision'] +spruce Fired ['Passmonitoring_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Hlt1PassThroughDecision', 'Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +regdecs : ['Hlt2Monitoring.*Decision'] +pos_lines_match ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +Hlt2 Fired ['Hlt2Monitoring_InclKsKs_PR_Hlt1MonitoringDecision'] +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particles has size 10 +/Event/HLT2/Hlt2Monitoring_InclKsKs_PR_Hlt1Monitoring/Particle2VertexRelations has size 25 +proto: { Track 0x7f2220f2d7e0 CaloHypos [] RichPID 0x7f2220ef5130 MuonPID 0x7f2220f34fd0 NeutralPID 0 ExtraInfo [ RichDLLe=-9.65745 RichDLLmu=-0.698368 RichDLLpi=0 RichDLLk=3.66517 RichDLLp=3.66517 RichPIDStatus=5028 RichDLLbt=3.66517 RichDLLd=3.66517 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 InAccBrem=1 CaloTrMatch=-1 CaloElectronMatch=-1 CaloBremMatch=19.1026 CaloChargedEcal=-1 CaloChargedID=0 CaloBremTBEnergy=3037.18 CaloBremHypoDeltaX=-2.07455 CaloBremBendingCorr=0.98074 CaloEcalE=2886.33 CaloHcalE=0 CaloClusChi2=-1 CaloEoverP=0.810845 CaloBremEnergy=0 CaloHasBrem=0 CaloBremHypoEnergy=13905 CaloBremHypoID=42401 EcalPIDe=0.685429 BremPIDe=-0.881532 HcalPIDe=0.467674 HcalPIDmu=-1.65783 EcalPIDmu=-1.96237 TrackChi2PerDof=1.87049 TrackNumDof=19 TrackType=3 TrackHistory=32 TrackP=3559.65 TrackPt=104.98 CombDLLe=-1.38639 CombDLLmu=-4.5916 CombDLLpi=0 CombDLLk=3.66517 CombDLLp=3.66517 CombDLLd=3.66517 ProbNNe=0.989468 ProbNNpi=0.0141878 ProbNNk=0.251743 ProbNNp=0.292568 ProbNNghost=0.988955 ] } +mothers: 10 firstdaughters: 2 +Spruce requested reports are {'Passmonitoring_rawDecision': True} +check ['Passmonitoring_rawDecision'] +spruce Fired ['Passmonitoring_rawDecision'] +HLTControlFlowMgr INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "Processed events" | 5 | +UnpackDstDataBank_8bf08535 INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "# Linked BufferData" | 90 | 252872 | 2809.7 | +ApplicationMgr INFO Application Manager Stopped successfully +HLTControlFlowMgr INFO Memory pool: used 0.000244141 +/- 0 MiB (min: 0, max: 0) in 1 +/- 0 blocks (allocated >once in 0 +/- 0% events). Allocated capacity was 10 +/- 0 MiB (min: 10, max: 10) and 4 +/- 0 (min: 4, max: 4) requests were served +HLTControlFlowMgr INFO Timing table: +HLTControlFlowMgr INFO + | Name of Algorithm | Execution Count | Total Time / s | Avg. Time / us | + | Sum of all Algorithms | 5 | 0.225 | 44902.200 | + | "UnpackDstDataBank_8bf08535" | 5 | 0.166 | 33177.093 | + | "Hlt2DecReportsDecoder" | 5 | 0.035 | 6963.216 | + | "RootIOAlg" | 5 | 0.015 | 2971.716 | + | "HltPackedBufferDecoder_c2691b9b" | 5 | 0.008 | 1589.016 | + | "LHCb__UnpackRawEvent_f7a6ca5b" | 5 | 0.001 | 143.381 | + | "SpruceDecReportsDecoder" | 5 | 0.000 | 58.206 | +HLTControlFlowMgr INFO StateTree: CFNode #executed #passed +NONLAZY_OR: checking #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + LHCb::UnpackRawEvent/LHCb__UnpackRawEvent_f7a6ca5b #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltDecReportsDecoder/Hlt2DecReportsDecoder #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltDecReportsDecoder/SpruceDecReportsDecoder #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltPackedBufferDecoder/HltPackedBufferDecoder_c2691b9b #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + UnpackDstDataBank/UnpackDstDataBank_8bf08535 #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| +HLTControlFlowMgr INFO Histograms converted successfully according to request. +ApplicationMgr INFO Application Manager Finalized successfully +ApplicationMgr INFO Application Manager Terminated successfully +HLTControlFlowMgr INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "Processed events" | 5 | +UnpackDstDataBank_8bf08535 INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "# Linked BufferData" | 90 | 252872 | 2809.7 | diff --git a/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_pid_rb_check.ref b/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_pid_rb_check.ref new file mode 100644 index 00000000000..8c77c817621 --- /dev/null +++ b/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_pid_rb_check.ref @@ -0,0 +1,294 @@ +# setting LC_ALL to "C" +input pass_turcal_lines_production.pid_raw.dst +manifest pass_turcal_lines_production.tck.json +job_type pass_turcal +stream pid_raw +rb_to_check [16, 73, 64, 9, 13, 84, 77] +rb_to_check_not None +/***** User ApplicationOptions/ApplicationOptions ************************************************** +|-append_decoding_keys_to_output_manifest = True (default: True) +|-auditors = [] (default: []) +|-conddb_tag = '' (default: '') +|-conditions_version = 'master' (default: '') +|-control_flow_file = '' (default: '') +|-data_flow_file = '' (default: '') +|-data_type = 'Upgrade' (default: 'Upgrade') +|-dddb_tag = '' (default: '') +|-event_store = 'HiveWhiteBoard' (default: 'HiveWhiteBoard') +|-evt_max = -1 (default: -1) +|-first_evt = 0 (default: 0) +|-gaudipython_mode = True (default: False) +|-geometry_version = 'run3/trunk' (default: '') +|-histo_file = '' (default: '') +|-input_files = ['pass_turcal_lines_production.pid_raw.dst'] (default: []) +|-input_manifest_file = 'pass_turcal_lines_production.tck.json' (default: '') +|-input_process = '' (default: '') +|-input_raw_format = 0.5 (default: 0.5) +|-input_type = 'ROOT' (default: '') +|-ioalg_buffer_nb_events = 40 (default: 40) +|-lines_maker = None +|-mdf_ioalg_name = 'IOAlgFileRead' (default: 'IOAlgFileRead') +|-memory_pool_size = 10485760 (default: 10485760) +|-monitoring_file = '' (default: '') +|-msg_svc_format = '% F%35W%S %7W%R%T %0W%M' (default: '% F%35W%S %7W%R%T %0W%M') +|-msg_svc_time_format = '%Y-%m-%d %H:%M:%S UTC' (default: '%Y-%m-%d %H:%M:%S UTC') +|-n_event_slots = 1 (default: -1) +|-n_threads = 1 (default: 1) +|-ntuple_file = '' (default: '') +|-output_file = '' (default: '') +|-output_level = 3 (default: 3) +|-output_manifest_file = '' (default: '') +|-output_type = '' (default: '') +|-persistreco_version = 1.0 (default: 1.0) +|-phoenix_filename = '' (default: '') +|-preamble_algs = [] (default: []) +|-print_freq = 10000 (default: 10000) +|-python_logging_level = 20 (default: 20) +|-require_specific_decoding_keys = [] (default: []) +|-root_ioalg_name = 'RootIOAlg' (default: 'RootIOAlg') +|-root_ioalg_opts = {} (default: {}) +|-scheduler_legacy_mode = True (default: True) +|-simulation = False (default: None) +|-write_decoding_keys_to_git = True (default: True) +\----- (End of User ApplicationOptions/ApplicationOptions) ----------------------------------------- +ApplicationMgr SUCCESS +==================================================================================================================================== + Welcome to ApplicationMgr (GaudiCoreSvc v38r0) + running on lblhcbpr20.cern.ch on Thu Jan 25 16:37:04 2024 +==================================================================================================================================== +ApplicationMgr INFO Application Manager Configured successfully +HLTControlFlowMgr INFO Start initialization +HLTControlFlowMgr INFO Will not use an EventSelector. +HLTControlFlowMgr INFO Concurrency level information: +ApplicationMgr INFO Application Manager Initialized successfully +JobOptionsSvc INFO Properties are dumped into "sprucing.test_turcal_spruce_2022_data_pid_rb_check.joboptsdump" +ApplicationMgr INFO Application Manager Started successfully +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Commissioning_L0ToPpPim_LLDecision', 'Hlt2Hlt1PassThroughDecision', 'Hlt2PID_L0ToPPi_LLDecision'] +regdecs : ['Hlt2PID.*Decision'] +pos_lines_match ['Hlt2PID_L0ToPPi_LLDecision'] +Hlt2 Fired ['Hlt2PID_L0ToPPi_LLDecision'] +/Event/HLT2/Hlt2PID_L0ToPPi_LL/Particles has size 1 +/Event/HLT2/Hlt2PID_L0ToPPi_LL/Particle2VertexRelations has size 3 +proto: { Track 0x7fb13cf58e20 CaloHypos [] RichPID 0x7fb13cb2eaa0 MuonPID 0x7fb13cb34690 NeutralPID 0 ExtraInfo [ RichDLLe=-17.052 RichDLLmu=-6.80718 RichDLLpi=0 RichDLLk=0.127137 RichDLLp=0.127137 RichPIDStatus=5028 RichDLLbt=0.127137 RichDLLd=0.127137 MuonPIDStatus=0 InAccBrem=1 CaloBremMatch=16.8231 CaloBremTBEnergy=112.282 CaloBremHypoDeltaX=-2.23074 CaloBremBendingCorr=0.978998 CaloBremEnergy=0 CaloHasBrem=0 CaloBremHypoEnergy=1603.37 CaloBremHypoID=39969 BremPIDe=-0.631782 TrackChi2PerDof=1.93022 TrackNumDof=22 TrackType=3 TrackHistory=32 TrackP=2602.44 TrackPt=190.676 CombDLLe=-3.44735 CombDLLmu=-6.13708 CombDLLpi=0 CombDLLk=0.127137 CombDLLp=0.127137 CombDLLd=0.127137 ProbNNe=0.00372359 ProbNNpi=0.0813272 ProbNNk=0.0448901 ProbNNp=0.0930852 ProbNNghost=0.951439 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passpid_rawDecision': True} +check ['Passpid_rawDecision'] +spruce Fired ['Passpid_rawDecision'] +/Event +/Event/pid_raw +/Event/pid_raw/RawEvent +/Event/RootIOAlg +/Event/RootIOAlg/EventBufferLocation +/Event/DAQ +/Event/DAQ/RawBanks +/Event/DAQ/RawBanks/DstData +/Event/DAQ/RawBanks/HltDecReports +/Event/DAQ/RawBanks/HltRoutingBits +/Event/Hlt2 +/Event/Hlt2/DecReports +/Event/Spruce +/Event/Spruce/DecReports +/Event/HltPackedBufferDecoder_c2691b9b +/Event/HltPackedBufferDecoder_c2691b9b/OutputBuffers +/Event/HLT2 +/Event/HLT2/Rec +/Event/HLT2/Rec/Track +/Event/HLT2/Rec/Track/Best +/Event/HLT2/Rec/Rich +/Event/HLT2/Rec/Rich/PIDs +/Event/HLT2/Rec/Muon +/Event/HLT2/Rec/Muon/MuonTracks +/Event/HLT2/Rec/Muon/MuonPID +/Event/HLT2/Rec/ProtoP +/Event/HLT2/Rec/ProtoP/Charged +/Event/HLT2/Rec/ProtoP/Neutrals +/Event/HLT2/Rec/Vertex +/Event/HLT2/Rec/Vertex/Primary +/Event/HLT2/Rec/Calo +/Event/HLT2/Rec/Calo/SplitPhotons +/Event/HLT2/Rec/Calo/MergedPi0s +/Event/HLT2/Rec/Calo/Photons +/Event/HLT2/Rec/Calo/Electrons +/Event/HLT2/Rec/Summary +/Event/HLT2/FunctionalParticleMaker +/Event/HLT2/FunctionalParticleMaker/Particles +/Event/HLT2/FunctionalParticleMaker#5 +/Event/HLT2/FunctionalParticleMaker#5/Particles +/Event/HLT2/PID_BdToKstG_Kst +/Event/HLT2/PID_BdToKstG_Kst/OutputVertices +/Event/HLT2/PID_BdToKstG_Kst/OutputParticles +/Event/HLT2/LHCb__Phys__ParticleMakers__PhotonMaker +/Event/HLT2/LHCb__Phys__ParticleMakers__PhotonMaker/Particles +/Event/HLT2/Hlt2PID_BdToKstG +/Event/HLT2/Hlt2PID_BdToKstG/decayVertices +/Event/HLT2/Hlt2PID_BdToKstG/Particles +/Event/HLT2/Hlt2PID_BdToKstG/Particle2VertexRelations +/Event/HLT2/Hlt2Commissioning_DiPhoton +/Event/HLT2/Hlt2Commissioning_DiPhoton/decayVertices +/Event/HLT2/Hlt2Commissioning_DiPhoton/Particles +/Event/HLT2/Hlt2Commissioning_DiPhoton/Particle2VertexRelations +/Event/Rec +/Event/Rec/NeutralPIDs +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Commissioning_DiPhotonDecision', 'Hlt2Hlt1PassThroughDecision', 'Hlt2PID_BdToKstGDecision'] +regdecs : ['Hlt2PID.*Decision'] +pos_lines_match ['Hlt2PID_BdToKstGDecision'] +Hlt2 Fired ['Hlt2PID_BdToKstGDecision'] +/Event/HLT2/Hlt2PID_BdToKstG/Particles has size 1 +/Event/HLT2/Hlt2PID_BdToKstG/Particle2VertexRelations has size 5 +proto: { Track 0 CaloHypos [0x7fb13cb3adb0] RichPID 0 MuonPID 0 NeutralPID 0x7fb13cb44910 ExtraInfo [ ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passpid_rawDecision': True} +check ['Passpid_rawDecision'] +spruce Fired ['Passpid_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Hlt1PassThroughDecision', 'Hlt2PID_JpsiToMuMupTagged_DetachedDecision'] +regdecs : ['Hlt2PID.*Decision'] +pos_lines_match ['Hlt2PID_JpsiToMuMupTagged_DetachedDecision'] +Hlt2 Fired ['Hlt2PID_JpsiToMuMupTagged_DetachedDecision'] +/Event/HLT2/Hlt2PID_JpsiToMuMupTagged_Detached/Particles has size 1 +/Event/HLT2/Hlt2PID_JpsiToMuMupTagged_Detached/Particle2VertexRelations has size 3 +proto: { Track 0x7fb13cb1b420 CaloHypos [] RichPID 0x7fb13cf4cfa0 MuonPID 0x7fb13cf528c0 NeutralPID 0 ExtraInfo [ RichDLLe=2.68287 RichDLLmu=2.15129 RichDLLpi=0 RichDLLk=-44.113 RichDLLp=-50.0714 RichPIDStatus=8161 RichDLLbt=-28.1214 RichDLLd=-28.1214 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 InAccBrem=1 CaloTrMatch=1.17257 CaloElectronMatch=32.2713 CaloBremMatch=-1 CaloChargedEcal=22231.2 CaloChargedID=43622 CaloBremTBEnergy=2336.95 CaloBremHypoDeltaX=0 CaloBremBendingCorr=1 CaloEcalE=16216.4 CaloHcalE=9554.16 CaloClusChi2=1.17257 CaloEoverP=0.547231 CaloBremEnergy=0 CaloHasBrem=0 CaloBremHypoEnergy=-1 CaloBremHypoID=0 EcalPIDe=-3.90082 BremPIDe=-0.766627 HcalPIDe=-0.280071 HcalPIDmu=-0.0432099 EcalPIDmu=-3.25397 TrackChi2PerDof=2.07014 TrackNumDof=15 TrackType=3 TrackHistory=32 TrackP=29633.5 TrackPt=1596.54 CombDLLe=-4.47872 CombDLLmu=-0.458427 CombDLLpi=0 CombDLLk=-44.113 CombDLLp=-50.0714 CombDLLd=-28.1214 ProbNNe=0.999998 ProbNNpi=0.18954 ProbNNk=0.00126462 ProbNNp=0.0805817 ProbNNghost=0.861925 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passpid_rawDecision': True} +check ['Passpid_rawDecision'] +spruce Fired ['Passpid_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Commissioning_L0ToPpPim_LLDecision', 'Hlt2DiMuonNoIP_massRange3Decision', 'Hlt2Hlt1PassThroughDecision', 'Hlt2L0ToPPiLLMonitoringDecision', 'Hlt2PID_L0ToPPi_LLDecision'] +regdecs : ['Hlt2PID.*Decision'] +pos_lines_match ['Hlt2PID_L0ToPPi_LLDecision'] +Hlt2 Fired ['Hlt2PID_L0ToPPi_LLDecision'] +/Event/HLT2/Hlt2PID_L0ToPPi_LL/Particles has size 1 +/Event/HLT2/Hlt2PID_L0ToPPi_LL/Particle2VertexRelations has size 3 +proto: { Track 0x7fb13cb5fff0 CaloHypos [] RichPID 0x7fb13cb0c390 MuonPID 0x7fb13cb0f280 NeutralPID 0 ExtraInfo [ RichDLLe=-10.5931 RichDLLmu=0.597733 RichDLLpi=0 RichDLLk=0.713835 RichDLLp=0.713835 RichPIDStatus=5060 RichDLLbt=0.713835 RichDLLd=0.713835 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 CaloTrMatch=-1 CaloElectronMatch=-1 CaloChargedEcal=-1 CaloChargedID=0 CaloEcalE=2254.44 CaloHcalE=1479.54 CaloClusChi2=-1 CaloEoverP=0.26999 EcalPIDe=-3.94639 HcalPIDe=0.0487619 HcalPIDmu=0.682765 EcalPIDmu=-1.24609 TrackChi2PerDof=2.26033 TrackNumDof=9 TrackType=3 TrackHistory=32 TrackP=8350.11 TrackPt=142.144 CombDLLe=-5.70927 CombDLLmu=0.269537 CombDLLpi=0 CombDLLk=0.713835 CombDLLp=0.713835 CombDLLd=0.713835 ProbNNe=0.662086 ProbNNpi=0.039643 ProbNNk=0.0128932 ProbNNp=0.0048224 ProbNNghost=0.905485 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passpid_rawDecision': True} +check ['Passpid_rawDecision'] +spruce Fired ['Passpid_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 239 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Hlt1PassThroughDecision', 'Hlt2PID_Bs2PhiGDecision'] +regdecs : ['Hlt2PID.*Decision'] +pos_lines_match ['Hlt2PID_Bs2PhiGDecision'] +Hlt2 Fired ['Hlt2PID_Bs2PhiGDecision'] +/Event/HLT2/Hlt2PID_Bs2PhiG/Particles has size 1 +/Event/HLT2/Hlt2PID_Bs2PhiG/Particle2VertexRelations has size 5 +proto: { Track 0 CaloHypos [0x7fb13caf0c40] RichPID 0 MuonPID 0 NeutralPID 0x7fb13cf37b60 ExtraInfo [ ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passpid_rawDecision': True} +check ['Passpid_rawDecision'] +spruce Fired ['Passpid_rawDecision'] +HLTControlFlowMgr INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "Processed events" | 5 | +UnpackDstDataBank_8bf08535 INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "# Linked BufferData" | 106 | 510956 | 4820.3 | +ApplicationMgr INFO Application Manager Stopped successfully +HLTControlFlowMgr INFO Memory pool: used 0.000244141 +/- 0 MiB (min: 0, max: 0) in 1 +/- 0 blocks (allocated >once in 0 +/- 0% events). Allocated capacity was 10 +/- 0 MiB (min: 10, max: 10) and 4 +/- 0 (min: 4, max: 4) requests were served +HLTControlFlowMgr INFO Timing table: +HLTControlFlowMgr INFO + | Name of Algorithm | Execution Count | Total Time / s | Avg. Time / us | + | Sum of all Algorithms | 5 | 0.239 | 47724.800 | + | "UnpackDstDataBank_8bf08535" | 5 | 0.175 | 34982.743 | + | "Hlt2DecReportsDecoder" | 5 | 0.052 | 10364.872 | + | "HltPackedBufferDecoder_c2691b9b" | 5 | 0.009 | 1836.162 | + | "RootIOAlg" | 5 | 0.002 | 303.239 | + | "LHCb__UnpackRawEvent_496f8e41" | 5 | 0.001 | 158.212 | + | "SpruceDecReportsDecoder" | 5 | 0.000 | 80.102 | +HLTControlFlowMgr INFO StateTree: CFNode #executed #passed +NONLAZY_OR: checking #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + LHCb::UnpackRawEvent/LHCb__UnpackRawEvent_496f8e41 #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltDecReportsDecoder/Hlt2DecReportsDecoder #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltDecReportsDecoder/SpruceDecReportsDecoder #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltPackedBufferDecoder/HltPackedBufferDecoder_c2691b9b #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + UnpackDstDataBank/UnpackDstDataBank_8bf08535 #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| +HLTControlFlowMgr INFO Histograms converted successfully according to request. +ApplicationMgr INFO Application Manager Finalized successfully +ApplicationMgr INFO Application Manager Terminated successfully +HLTControlFlowMgr INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "Processed events" | 5 | +UnpackDstDataBank_8bf08535 INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "# Linked BufferData" | 106 | 510956 | 4820.3 | diff --git a/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_trackeff_rb_check.ref b/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_trackeff_rb_check.ref new file mode 100644 index 00000000000..03413af587a --- /dev/null +++ b/Hlt/Hlt2Conf/tests/refs/test_turcal_spruce_2022_data_trackeff_rb_check.ref @@ -0,0 +1,306 @@ +# setting LC_ALL to "C" +input pass_turcal_lines_production.trackeff_raw.dst +manifest pass_turcal_lines_production.tck.json +job_type pass_turcal +stream trackeff_raw +rb_to_check [16, 73, 64, 9, 13, 84, 77] +rb_to_check_not None +/***** User ApplicationOptions/ApplicationOptions ************************************************** +|-append_decoding_keys_to_output_manifest = True (default: True) +|-auditors = [] (default: []) +|-conddb_tag = '' (default: '') +|-conditions_version = 'master' (default: '') +|-control_flow_file = '' (default: '') +|-data_flow_file = '' (default: '') +|-data_type = 'Upgrade' (default: 'Upgrade') +|-dddb_tag = '' (default: '') +|-event_store = 'HiveWhiteBoard' (default: 'HiveWhiteBoard') +|-evt_max = -1 (default: -1) +|-first_evt = 0 (default: 0) +|-gaudipython_mode = True (default: False) +|-geometry_version = 'run3/trunk' (default: '') +|-histo_file = '' (default: '') +|-input_files = ['pass_turcal_lines_production.trackeff_raw.dst'] (default: []) +|-input_manifest_file = 'pass_turcal_lines_production.tck.json' (default: '') +|-input_process = '' (default: '') +|-input_raw_format = 0.5 (default: 0.5) +|-input_type = 'ROOT' (default: '') +|-ioalg_buffer_nb_events = 40 (default: 40) +|-lines_maker = None +|-mdf_ioalg_name = 'IOAlgFileRead' (default: 'IOAlgFileRead') +|-memory_pool_size = 10485760 (default: 10485760) +|-monitoring_file = '' (default: '') +|-msg_svc_format = '% F%35W%S %7W%R%T %0W%M' (default: '% F%35W%S %7W%R%T %0W%M') +|-msg_svc_time_format = '%Y-%m-%d %H:%M:%S UTC' (default: '%Y-%m-%d %H:%M:%S UTC') +|-n_event_slots = 1 (default: -1) +|-n_threads = 1 (default: 1) +|-ntuple_file = '' (default: '') +|-output_file = '' (default: '') +|-output_level = 3 (default: 3) +|-output_manifest_file = '' (default: '') +|-output_type = '' (default: '') +|-persistreco_version = 1.0 (default: 1.0) +|-phoenix_filename = '' (default: '') +|-preamble_algs = [] (default: []) +|-print_freq = 10000 (default: 10000) +|-python_logging_level = 20 (default: 20) +|-require_specific_decoding_keys = [] (default: []) +|-root_ioalg_name = 'RootIOAlg' (default: 'RootIOAlg') +|-root_ioalg_opts = {} (default: {}) +|-scheduler_legacy_mode = True (default: True) +|-simulation = False (default: None) +|-write_decoding_keys_to_git = True (default: True) +\----- (End of User ApplicationOptions/ApplicationOptions) ----------------------------------------- +ApplicationMgr SUCCESS +==================================================================================================================================== + Welcome to ApplicationMgr (GaudiCoreSvc v38r0) + running on lblhcbpr20.cern.ch on Thu Jan 25 16:37:05 2024 +==================================================================================================================================== +ApplicationMgr INFO Application Manager Configured successfully +HLTControlFlowMgr INFO Start initialization +HLTControlFlowMgr INFO Will not use an EventSelector. +HLTControlFlowMgr INFO Concurrency level information: +ApplicationMgr INFO Application Manager Initialized successfully +JobOptionsSvc INFO Properties are dumped into "sprucing.test_turcal_spruce_2022_data_trackeff_rb_check.joboptsdump" +ApplicationMgr INFO Application Manager Started successfully +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +Check ERROR Expected raw bank 77 +RawBank 77 has size 0 +Lines that fired : ['Hlt2Charm_D0ToKmPip_XSecDecision', 'Hlt2HadInt_D0ToKmPipDecision', 'Hlt2Hlt1PassThroughDecision', 'Hlt2PID_DstToD0Pi_D0ToKPiDecision'] +regdecs : ['Hlt2TrackEff.*Decision', 'Hlt2HadInt.*Decision'] +pos_lines_match ['Hlt2HadInt_D0ToKmPipDecision'] +Hlt2 Fired ['Hlt2HadInt_D0ToKmPipDecision'] +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particles has size 1 +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particle2VertexRelations has size 3 +proto: { Track 0x7efdd8f3fc00 CaloHypos [] RichPID 0x7efdd8f2a940 MuonPID 0x7efdd8f2d3d0 NeutralPID 0 ExtraInfo [ RichDLLe=0.139099 RichDLLmu=0.216599 RichDLLpi=0 RichDLLk=-11.5518 RichDLLp=-19.7708 RichPIDStatus=139239 RichDLLbt=5.76327 RichDLLd=-14.486 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 InAccBrem=1 CaloTrMatch=-1 CaloElectronMatch=-1 CaloBremMatch=-1 CaloChargedEcal=-1 CaloChargedID=0 CaloBremTBEnergy=0 CaloBremHypoDeltaX=0 CaloBremBendingCorr=1 CaloEcalE=0 CaloHcalE=0 CaloClusChi2=-1 CaloEoverP=0 CaloBremEnergy=0 CaloHasBrem=0 CaloBremHypoEnergy=-1 CaloBremHypoID=0 EcalPIDe=-4.08222 BremPIDe=-0.766627 HcalPIDe=2.45457 HcalPIDmu=1.55415 EcalPIDmu=1.34003 TrackChi2PerDof=1.44496 TrackNumDof=20 TrackType=3 TrackHistory=32 TrackP=58643.4 TrackPt=2082.03 CombDLLe=-2.36994 CombDLLmu=3.19723 CombDLLpi=0 CombDLLk=-11.5518 CombDLLp=-19.7708 CombDLLd=-14.486 ProbNNe=0.78317 ProbNNpi=0.369341 ProbNNk=0.00356498 ProbNNp=0.000517062 ProbNNghost=0.641876 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passtrackeff_rawDecision': True} +check ['Passtrackeff_rawDecision'] +spruce Fired ['Passtrackeff_rawDecision'] +/Event +/Event/trackeff_raw +/Event/trackeff_raw/RawEvent +/Event/RootIOAlg +/Event/RootIOAlg/EventBufferLocation +/Event/DAQ +/Event/DAQ/RawBanks +/Event/DAQ/RawBanks/DstData +/Event/DAQ/RawBanks/HltDecReports +/Event/DAQ/RawBanks/HltRoutingBits +/Event/Hlt2 +/Event/Hlt2/DecReports +/Event/Spruce +/Event/Spruce/DecReports +/Event/HltPackedBufferDecoder_c2691b9b +/Event/HltPackedBufferDecoder_c2691b9b/OutputBuffers +/Event/HLT2 +/Event/HLT2/Rec +/Event/HLT2/Rec/Track +/Event/HLT2/Rec/Track/Best +/Event/HLT2/Rec/Rich +/Event/HLT2/Rec/Rich/PIDs +/Event/HLT2/Rec/Muon +/Event/HLT2/Rec/Muon/MuonTracks +/Event/HLT2/Rec/Muon/MuonPID +/Event/HLT2/Rec/ProtoP +/Event/HLT2/Rec/ProtoP/Charged +/Event/HLT2/Rec/ProtoP/Neutrals +/Event/HLT2/Rec/Vertex +/Event/HLT2/Rec/Vertex/Primary +/Event/HLT2/Rec/Calo +/Event/HLT2/Rec/Calo/SplitPhotons +/Event/HLT2/Rec/Calo/MergedPi0s +/Event/HLT2/Rec/Calo/Photons +/Event/HLT2/Rec/Calo/Electrons +/Event/HLT2/Rec/Summary +/Event/HLT2/FunctionalParticleMaker +/Event/HLT2/FunctionalParticleMaker/Particles +/Event/HLT2/FunctionalParticleMaker#5 +/Event/HLT2/FunctionalParticleMaker#5/Particles +/Event/HLT2/Hlt2Charm_D0ToKmPip_LowBias +/Event/HLT2/Hlt2Charm_D0ToKmPip_LowBias/decayVertices +/Event/HLT2/Hlt2Charm_D0ToKmPip_LowBias/Particles +/Event/HLT2/Hlt2Charm_D0ToKmPip_LowBias/Particle2VertexRelations +/Event/HLT2/FunctionalParticleMaker#8 +/Event/HLT2/FunctionalParticleMaker#8/Particles +/Event/HLT2/FunctionalParticleMaker#4 +/Event/HLT2/FunctionalParticleMaker#4/Particles +/Event/HLT2/Hlt2Commissioning_D0ToKmPip +/Event/HLT2/Hlt2Commissioning_D0ToKmPip/decayVertices +/Event/HLT2/Hlt2Commissioning_D0ToKmPip/Particles +/Event/HLT2/Hlt2Commissioning_D0ToKmPip/Particle2VertexRelations +/Event/HLT2/Hlt2HadInt_D0ToKmPip +/Event/HLT2/Hlt2HadInt_D0ToKmPip/decayVertices +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particles +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particle2VertexRelations +/Event/HLT2/Hlt2Charm_D0ToKmPip +/Event/HLT2/Hlt2Charm_D0ToKmPip/decayVertices +/Event/HLT2/Hlt2Charm_D0ToKmPip/Particles +/Event/HLT2/Hlt2Charm_D0ToKmPip/Particle2VertexRelations +/Event/HLT2/Hlt2Charm_D0ToKmPip_XSec +/Event/HLT2/Hlt2Charm_D0ToKmPip_XSec/decayVertices +/Event/HLT2/Hlt2Charm_D0ToKmPip_XSec/Particles +/Event/HLT2/Hlt2Charm_D0ToKmPip_XSec/Particle2VertexRelations +/Event/Rec +/Event/Rec/NeutralPIDs +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Charm_D0ToKmPipDecision', 'Hlt2Charm_D0ToKmPip_LowBiasDecision', 'Hlt2Charm_D0ToKmPip_XSecDecision', 'Hlt2Commissioning_D0ToKmPipDecision', 'Hlt2HadInt_D0ToKmPipDecision', 'Hlt2Hlt1PassThroughDecision'] +regdecs : ['Hlt2TrackEff.*Decision', 'Hlt2HadInt.*Decision'] +pos_lines_match ['Hlt2HadInt_D0ToKmPipDecision'] +Hlt2 Fired ['Hlt2HadInt_D0ToKmPipDecision'] +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particles has size 1 +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particle2VertexRelations has size 3 +proto: { Track 0x7efdd8f338a0 CaloHypos [] RichPID 0x7efdd8af04c0 MuonPID 0x7efdd8f40b80 NeutralPID 0 ExtraInfo [ RichDLLe=2.55342 RichDLLmu=1.30029 RichDLLpi=0 RichDLLk=-25.6617 RichDLLp=-28.6243 RichPIDStatus=139239 RichDLLbt=10.0946 RichDLLd=-4.04478 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccBrem=1 CaloTrMatch=0.374373 CaloElectronMatch=1070.23 CaloBremMatch=-1 CaloChargedEcal=4937.32 CaloChargedID=42459 CaloBremTBEnergy=0 CaloBremHypoDeltaX=0 CaloBremBendingCorr=1 CaloEcalE=4341.54 CaloClusChi2=0.374373 CaloEoverP=0.0762834 CaloBremEnergy=0 CaloHasBrem=0 CaloBremHypoEnergy=-1 CaloBremHypoID=0 EcalPIDe=-4.06472 BremPIDe=-0.766627 EcalPIDmu=-0.137853 TrackChi2PerDof=1.24356 TrackNumDof=16 TrackType=3 TrackHistory=32 TrackP=56913.3 TrackPt=1497.36 CombDLLe=-4.3851 CombDLLmu=1.6426 CombDLLpi=0 CombDLLk=-25.6617 CombDLLp=-28.6243 CombDLLd=-4.04478 ProbNNe=6.07379e-06 ProbNNpi=0.78897 ProbNNk=0.00102173 ProbNNp=0.00264654 ProbNNghost=0.87598 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passtrackeff_rawDecision': True} +check ['Passtrackeff_rawDecision'] +spruce Fired ['Passtrackeff_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2Charm_D0ToKmPipDecision', 'Hlt2Charm_D0ToKmPip_LowBiasDecision', 'Hlt2Charm_D0ToKmPip_XSecDecision', 'Hlt2Commissioning_DiPhotonDecision', 'Hlt2HadInt_D0ToKmPipDecision', 'Hlt2Hlt1PassThroughDecision'] +regdecs : ['Hlt2TrackEff.*Decision', 'Hlt2HadInt.*Decision'] +pos_lines_match ['Hlt2HadInt_D0ToKmPipDecision'] +Hlt2 Fired ['Hlt2HadInt_D0ToKmPipDecision'] +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particles has size 1 +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particle2VertexRelations has size 3 +proto: { Track 0x7efdd8b27bc0 CaloHypos [] RichPID 0x7efdd8af0870 MuonPID 0x7efdd8b293c0 NeutralPID 0 ExtraInfo [ RichDLLe=0.210098 RichDLLmu=0.326318 RichDLLpi=0 RichDLLk=-2.80825 RichDLLp=-18.5057 RichPIDStatus=139234 RichDLLbt=-1.15493 RichDLLd=-19.0116 MuonPIDStatus=4 TrackChi2PerDof=1.28381 TrackNumDof=25 TrackType=3 TrackHistory=32 TrackP=93445.8 TrackPt=2559.23 CombDLLe=0.0367668 CombDLLmu=0.456197 CombDLLpi=0 CombDLLk=-2.80825 CombDLLp=-18.5057 CombDLLd=-19.0116 ProbNNe=0.381968 ProbNNpi=0.161484 ProbNNk=0.0530164 ProbNNp=6.8861e-05 ProbNNghost=0.787337 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passtrackeff_rawDecision': True} +check ['Passtrackeff_rawDecision'] +spruce Fired ['Passtrackeff_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +HLTControlFlowMgr INFO Will measure time between events 0 and 0 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events +Lines that fired : ['Hlt2Charm_D0ToKmPipDecision', 'Hlt2Charm_D0ToKmPip_LowBiasDecision', 'Hlt2Charm_D0ToKmPip_XSecDecision', 'Hlt2Commissioning_D0ToKmPipDecision', 'Hlt2HadInt_D0ToKmPipDecision', 'Hlt2Hlt1PassThroughDecision', 'Hlt2SLB_B0ToD0TauNu_D0ToKPi_FakeElectronDecision', 'Hlt2SLB_B0ToD0TauNu_D0ToKPi_TauToENuNuDecision', 'Hlt2SLB_BpToDzTauNu_DzToKPi_TauToENuNuDecision'] +regdecs : ['Hlt2TrackEff.*Decision', 'Hlt2HadInt.*Decision'] +pos_lines_match ['Hlt2HadInt_D0ToKmPipDecision'] +Hlt2 Fired ['Hlt2HadInt_D0ToKmPipDecision'] +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particles has size 1 +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particle2VertexRelations has size 3 +proto: { Track 0x7efdd8f361c0 CaloHypos [] RichPID 0x7efdd8f3cfa0 MuonPID 0x7efdd8f2b0b0 NeutralPID 0 ExtraInfo [ RichDLLe=2.92447 RichDLLmu=2.07499 RichDLLpi=0 RichDLLk=-74.938 RichDLLp=-53.1887 RichPIDStatus=139233 RichDLLbt=-36.0106 RichDLLd=-36.2341 MuonPIDStatus=6 InAccMuon=1 TrackChi2PerDof=1.20401 TrackNumDof=18 TrackType=3 TrackHistory=32 TrackP=34994.2 TrackPt=1182.57 CombDLLe=0.510872 CombDLLmu=2.74896 CombDLLpi=0 CombDLLk=-74.938 CombDLLp=-53.1887 CombDLLd=-36.2341 ProbNNe=0.627145 ProbNNpi=0.661084 ProbNNk=3.76747e-05 ProbNNp=2.54324e-05 ProbNNghost=0.284803 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passtrackeff_rawDecision': True} +check ['Passtrackeff_rawDecision'] +spruce Fired ['Passtrackeff_rawDecision'] +Checking next event. +bank 16 +RawBank 16 has size 1 +bank 73 +RawBank 73 has size 102 +bank 64 +RawBank 64 has size 240 +bank 9 +RawBank 9 has size 143 +bank 13 +RawBank 13 has size 44 +bank 84 +RawBank 84 has size 3 +bank 77 +RawBank 77 has size 91 +Lines that fired : ['Hlt2BandQ_DoubleCharmOppositeSignDecision', 'Hlt2Charm_D0ToKmPipDecision', 'Hlt2Charm_D0ToKmPip_LowBiasDecision', 'Hlt2Charm_D0ToKmPip_XSecDecision', 'Hlt2Charm_DoubleOpenCharmOS_PR_XSecDecision', 'Hlt2Charm_DpDspToKmPipPipDecision', 'Hlt2Charm_DpToKmPipPip_XSecDecision', 'Hlt2Commissioning_D0ToKmPipDecision', 'Hlt2Commissioning_DpToKmPipPipDecision', 'Hlt2Commissioning_LcpToPpKmPipDecision', 'Hlt2HadInt_D0ToKmPipDecision', 'Hlt2Hlt1PassThroughDecision'] +regdecs : ['Hlt2TrackEff.*Decision', 'Hlt2HadInt.*Decision'] +pos_lines_match ['Hlt2HadInt_D0ToKmPipDecision'] +Hlt2 Fired ['Hlt2HadInt_D0ToKmPipDecision'] +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particles has size 1 +/Event/HLT2/Hlt2HadInt_D0ToKmPip/Particle2VertexRelations has size 3 +proto: { Track 0x7efdd8b1ced0 CaloHypos [] RichPID 0x7efdd8b28d50 MuonPID 0x7efdd8b340f0 NeutralPID 0 ExtraInfo [ RichDLLe=-22.8988 RichDLLmu=-0.513148 RichDLLpi=0 RichDLLk=-93.5878 RichDLLp=-66.1293 RichPIDStatus=8163 RichDLLbt=-68.4321 RichDLLd=-68.4321 MuonPIDStatus=6 InAccMuon=1 InAccEcal=1 InAccHcal=1 InAccBrem=1 CaloTrMatch=3.18093 CaloElectronMatch=314.976 CaloBremMatch=-1 CaloChargedEcal=6912.53 CaloChargedID=39245 CaloBremTBEnergy=0 CaloBremHypoDeltaX=0 CaloBremBendingCorr=1 CaloEcalE=6242.34 CaloHcalE=14161.3 CaloClusChi2=3.18093 CaloEoverP=0.333202 CaloBremEnergy=0 CaloHasBrem=0 CaloBremHypoEnergy=-1 CaloBremHypoID=0 EcalPIDe=-4.02776 BremPIDe=-0.836268 HcalPIDe=-0.982889 HcalPIDmu=-1.56834 EcalPIDmu=-2.36204 TrackChi2PerDof=1.32708 TrackNumDof=16 TrackType=3 TrackHistory=32 TrackP=18734.4 TrackPt=1078.17 CombDLLe=-9.46712 CombDLLmu=-4.64627 CombDLLpi=0 CombDLLk=-93.5878 CombDLLp=-66.1293 CombDLLd=-68.4321 ProbNNe=0.723539 ProbNNpi=0.997193 ProbNNk=8.64931e-05 ProbNNp=0.119051 ProbNNghost=0.159571 ] } +mothers: 1 firstdaughters: 2 +Spruce requested reports are {'Passtrackeff_rawDecision': True} +check ['Passtrackeff_rawDecision'] +spruce Fired ['Passtrackeff_rawDecision'] +HLTControlFlowMgr INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "Processed events" | 5 | +UnpackDstDataBank_8bf08535 INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "# Linked BufferData" | 183 | 324046 | 1770.7 | +ApplicationMgr INFO Application Manager Stopped successfully +HLTControlFlowMgr INFO Memory pool: used 0.000244141 +/- 0 MiB (min: 0, max: 0) in 1 +/- 0 blocks (allocated >once in 0 +/- 0% events). Allocated capacity was 10 +/- 0 MiB (min: 10, max: 10) and 4 +/- 0 (min: 4, max: 4) requests were served +HLTControlFlowMgr INFO Timing table: +HLTControlFlowMgr INFO + | Name of Algorithm | Execution Count | Total Time / s | Avg. Time / us | + | Sum of all Algorithms | 5 | 0.314 | 62888.600 | + | "UnpackDstDataBank_8bf08535" | 5 | 0.251 | 50289.958 | + | "Hlt2DecReportsDecoder" | 5 | 0.054 | 10865.974 | + | "HltPackedBufferDecoder_c2691b9b" | 5 | 0.006 | 1150.726 | + | "RootIOAlg" | 5 | 0.002 | 301.086 | + | "LHCb__UnpackRawEvent_1750d9f1" | 5 | 0.001 | 184.692 | + | "SpruceDecReportsDecoder" | 5 | 0.000 | 96.955 | +HLTControlFlowMgr INFO StateTree: CFNode #executed #passed +NONLAZY_OR: checking #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + LHCb::UnpackRawEvent/LHCb__UnpackRawEvent_1750d9f1 #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltDecReportsDecoder/Hlt2DecReportsDecoder #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltDecReportsDecoder/SpruceDecReportsDecoder #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + HltPackedBufferDecoder/HltPackedBufferDecoder_c2691b9b #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| + UnpackDstDataBank/UnpackDstDataBank_8bf08535 #=5 Sum=5 Eff=|( 100.0000 +- 0.00000 )%| +HLTControlFlowMgr INFO Histograms converted successfully according to request. +ApplicationMgr INFO Application Manager Finalized successfully +ApplicationMgr INFO Application Manager Terminated successfully +HLTControlFlowMgr INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "Processed events" | 5 | +UnpackDstDataBank_8bf08535 INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "# Linked BufferData" | 183 | 324046 | 1770.7 | diff --git a/Hlt/Moore/python/Moore/config.py b/Hlt/Moore/python/Moore/config.py index 51808ddc9b0..86fa8219d54 100644 --- a/Hlt/Moore/python/Moore/config.py +++ b/Hlt/Moore/python/Moore/config.py @@ -20,7 +20,6 @@ from PyConf.Algorithms import (HltDecReportsFilter, HltDecReportsMonitor, from PyConf.components import Algorithm from PyConf.control_flow import (CompositeNode, NodeLogic, traverse_node_and_children) - from PyConf.application import (ROOT_KEY, make_odin, default_raw_banks, all_nodes_and_algs, configure_input, configure) from .persistence import persist_line_outputs @@ -165,6 +164,7 @@ def moore_control_flow(options, streams, process, analytics=False): (line_output_cf, extra_locations_to_persist, packed_data) = persist_line_outputs( + options=options, streams=streams, dec_reports=dec_reports.DecReportsLocation, associate_mc=process == "hlt2" and options.simulation diff --git a/Hlt/Moore/python/Moore/lines.py b/Hlt/Moore/python/Moore/lines.py index d6927492571..9de24c63e33 100644 --- a/Hlt/Moore/python/Moore/lines.py +++ b/Hlt/Moore/python/Moore/lines.py @@ -442,7 +442,7 @@ class Hlt2Line(DecisionLine): @property def produces_output(self): """Return True if this line produces output OR requests reconstruction OR requests extra_outputs.""" - return self.output_producer is not None or self.persistreco or self.tagging_particles or self.extra_outputs is not None + return self.output_producer is not None or self.persistreco or self.tagging_particles or self.extra_outputs @staticmethod def _output_node(decision_node, output_producer, extra_outputs, diff --git a/Hlt/Moore/python/Moore/persistence/__init__.py b/Hlt/Moore/python/Moore/persistence/__init__.py index e70ae9ba93e..ee7fcc9e4cf 100644 --- a/Hlt/Moore/python/Moore/persistence/__init__.py +++ b/Hlt/Moore/python/Moore/persistence/__init__.py @@ -119,6 +119,7 @@ def get_packed_locations(lines, inputs, output_prefix): @configurable def persist_line_outputs( + options, streams, dec_reports, associate_mc, @@ -142,7 +143,11 @@ def persist_line_outputs( persisted when writing to a ROOT file. """ - reco_objs = reconstruction() + if (options.input_type != 'ROOT'): + log.warning("persist_line_outputs disabled as input_type is not ROOT") + reco_objs = {} + else: + reco_objs = reconstruction() cf = [] protoparticle_relations = [] diff --git a/Hlt/Moore/python/Moore/persistence/truth_matching.py b/Hlt/Moore/python/Moore/persistence/truth_matching.py index 9b195c968fe..ec1d8780f08 100644 --- a/Hlt/Moore/python/Moore/persistence/truth_matching.py +++ b/Hlt/Moore/python/Moore/persistence/truth_matching.py @@ -31,7 +31,7 @@ from PyConf.Algorithms import ( from PyConf.components import force_location from PyConf.control_flow import CompositeNode, NodeLogic -from RecoConf.data_from_file import brunel_links, mc_unpackers +from RecoConf.data_from_file import brunel_links, mc_unpacker from RecoConf import mc_checking from RecoConf.data_from_file import boole_links_digits_mcparticles @@ -162,13 +162,13 @@ def _find_protoparticles(candidates): def _match_charged(charged, charged_brunel, mc_particles): - brunel_links_from_file = brunel_links() relations = [] # Track association from file - track_links_brunel = brunel_links_from_file["Tracks"] - assoc_tracks_brunel = MergeLinksByKeysToVector( - InputLinksByKeys=[track_links_brunel]) + if charged_brunel: + track_links_brunel = brunel_links("Tracks") + assoc_tracks_brunel = MergeLinksByKeysToVector( + InputLinksByKeys=[track_links_brunel]) # Need these links for performing track association from raw links_to_lhcbids = mc_checking.make_links_lhcbids_mcparticles_tracking_and_muon_system( @@ -209,7 +209,6 @@ def _match_charged(charged, charged_brunel, mc_particles): def _match_neutral(neutral, neutral_brunel, mc_particles): - brunel_links_from_file = brunel_links() relations = [] # CaloHypo association from raw @@ -278,13 +277,13 @@ def _match_neutral(neutral, neutral_brunel, mc_particles): tableMCCaloDigits = CaloFutureDigit2MCLinks2Table( CaloDigits=ecalDigits_v2, MCParticles=mc_particles, - Link=boole_links_digits_mcparticles()["EcalDigitsV1"], + Link=boole_links_digits_mcparticles("EcalDigitsV1"), ).Output # get Clusterv22MC table tableMCCaloClusters = CaloClusterMCTruth( InputRelations=tableMCCaloDigits, - Input=boole_links_digits_mcparticles()['EcalDigits'], + Input=boole_links_digits_mcparticles('EcalDigits'), MCParticleLocation=mc_particles, Clusters=clusters_v2).Output @@ -337,9 +336,7 @@ def _match_neutral(neutral, neutral_brunel, mc_particles): hypo_types_brunel = [ "CaloMergedPi0s", "CaloPhotons", "CaloSplitPhotons" ] - hypo_links_brunel = [ - brunel_links_from_file[t] for t in hypo_types_brunel - ] + hypo_links_brunel = [brunel_links(t) for t in hypo_types_brunel] assoc_hypos_brunel = MergeLinksByKeysToVector( InputLinksByKeys=hypo_links_brunel) assoc_neutral_brunel = NeutralProtoParticleAssociator( @@ -386,9 +383,8 @@ def truth_match_candidates(candidates): (charged, neutral), (charged_brunel, neutral_brunel) = _find_protoparticles(candidates) - mc_objs = mc_unpackers() - mc_particles = mc_objs["MCParticles"] - mc_vertices = mc_objs["MCVertices"] + mc_particles = mc_unpacker("MCParticles") + mc_vertices = mc_unpacker("MCVertices") # TODO factor out configuration common to RecoConf.mc_checking and use that # rather than duplicate it here diff --git a/Hlt/Moore/python/Moore/qmtest/exclusions.py b/Hlt/Moore/python/Moore/qmtest/exclusions.py index e76d09687bd..2604f5ca900 100644 --- a/Hlt/Moore/python/Moore/qmtest/exclusions.py +++ b/Hlt/Moore/python/Moore/qmtest/exclusions.py @@ -146,9 +146,8 @@ only_finalize = BlockSkipper("# --> Including file", # In case you do not want to check what is printed before the first event. # NB: Always put before RecPreprocessor as it filters the '# ...' lines -skip_initialize = BlockSkipper( - "# --> Including file", - " Reading Event record 1. Record number within stream 1: 1") +skip_initialize = BlockSkipper("# --> Including file", + "Application Manager Initialized successfully") # In case you do not want to check counters. remove_finalize = BlockSkipper( diff --git a/Hlt/Moore/python/Moore/stream_writers.py b/Hlt/Moore/python/Moore/stream_writers.py index 8f9a37b2037..674d8f8c155 100644 --- a/Hlt/Moore/python/Moore/stream_writers.py +++ b/Hlt/Moore/python/Moore/stream_writers.py @@ -12,9 +12,9 @@ from shutil import copy import logging from PyConf import configurable -from PyConf.Algorithms import ( - Gaudi__Hive__FetchLeavesFromFile, SelectiveCombineRawBankViewsToRawEvent, - CombineRawBankViewsToRawEvent, RawEventSimpleMover, AddressKillerAlg) +from PyConf.Algorithms import (SelectiveCombineRawBankViewsToRawEvent, + CombineRawBankViewsToRawEvent, + RawEventSimpleMover, AddressKillerAlg) from PyConf.components import force_location from PyConf.application import (MDF_KEY, ROOT_KEY, mdf_writer, online_writer, root_copy_input_writer, default_raw_banks, @@ -128,18 +128,14 @@ def stream_writer(options, # This part is only meant for simulation # always false for data and by default true for simulation if write_all_input_leaves and propagate_mc: - # Copy the locations from the input when the output is ROOT - input_leaves = Gaudi__Hive__FetchLeavesFromFile() - writers.append(input_leaves) - # Make the entire datastore anonymous. All persistent info of all addresses is entirely removed. # otherwise, root_writer saves a link to the input event/file writers.append(AddressKillerAlg()) writers.append( root_copy_input_writer( - full_fname, - input_leaves, [output_location] + extra_locations, + options, + full_fname, [output_location] + extra_locations, tes_veto_locations=veto_list)) else: # Make the entire datastore anonymous. All persistent info of all addresses is entirely removed. diff --git a/Hlt/Moore/python/Moore/tests/test_lines.py b/Hlt/Moore/python/Moore/tests/test_lines.py index e7b47e14b43..99df83de64e 100644 --- a/Hlt/Moore/python/Moore/tests/test_lines.py +++ b/Hlt/Moore/python/Moore/tests/test_lines.py @@ -10,8 +10,9 @@ ############################################################################### """Test the construction of DecisionLine objects.""" from PyConf.Algorithms import Gaudi__Examples__IntDataProducer as IntDataProducer -from PyConf.application import default_raw_event +from PyConf.application import configure_input +from Moore import options from Moore.lines import Hlt2Line from Moore.persistence.particle_moving import particle_output # A little gross to reach into Hlt2Conf from Moore, but it's useful to be able @@ -21,6 +22,15 @@ from Hlt2Conf.standard_particles import make_long_pions, make_dimuon_base from PyConf.packing import persistreco_version persistreco_version.global_bind(version=0.0) +# minimum config to be able to configure +options.simulation = True +options.input_type = "Root" +options.input_files = ["fake"] +options.geometry_version = "v1" +options.conditions_version = "v1" +options.dddb_tag = "v1" +options.conddb_tag = "v1" + def test_unknown_producer(caplog): """Hlt2Line construction with an unknown output type should produce a warning. @@ -29,8 +39,8 @@ def test_unknown_producer(caplog): This is so that line authors do not request algorithm outputs which are silently ignored by the cloners/packers. """ - with default_raw_event.bind(raw_event_format=4.3): - Hlt2Line("Hlt2IntDataProducer", algs=[IntDataProducer()]) + configure_input(options) + Hlt2Line("Hlt2IntDataProducer", algs=[IntDataProducer()]) # A warning should be emitted about the unknown output type assert len(caplog.records) == 1 @@ -45,8 +55,8 @@ def test_particle_producer(caplog): This is currently on LHCb::Particle producers. As more producers are supported, additional tests should be added. """ - with default_raw_event.bind(raw_event_format=4.3): - Hlt2Line("Hlt2ParticleProducer", algs=[make_dimuon_base()]) + configure_input(options) + Hlt2Line("Hlt2ParticleProducer", algs=[make_dimuon_base()]) # Should see no warnings as the output type of the producer is supported assert len(caplog.records) == 0 @@ -54,6 +64,7 @@ def test_particle_producer(caplog): def test_particle_output(): """Particle outputs should be deducible.""" + configure_input(options) # We happen to know that this algorithm is functional, so its Particle # output should be detected cleanly particles = make_long_pions() diff --git a/Hlt/Hlt2Conf/options/hlt2_ganga_input.py b/Hlt/Moore/tests/options/default_conds_hlt1.py similarity index 60% rename from Hlt/Hlt2Conf/options/hlt2_ganga_input.py rename to Hlt/Moore/tests/options/default_conds_hlt1.py index 2f96c4b6630..40cec19be10 100644 --- a/Hlt/Hlt2Conf/options/hlt2_ganga_input.py +++ b/Hlt/Moore/tests/options/default_conds_hlt1.py @@ -8,17 +8,6 @@ # granted to it by virtue of its status as an Intergovernmental Organization # # or submit itself to any jurisdiction. # ############################################################################### -"""Options for defining input data in a similar manner to how Ganga does it. +from Moore import options -Requires a separate file that configures Moore. -""" -from GaudiConf import IOExtension - -# Same input data as the hlt2_example test -input_files = [ - # D*-tagged D0 to KK, 27163002 - # sim+std://MC/Upgrade/Beam7000GeV-Upgrade-MagDown-Nu7.6-25ns-Pythia8/Sim09c-Up02/Reco-Up01/27163002/LDST - 'root://eoslhcb.cern.ch//eos/lhcb/grid/prod/lhcb/MC/Upgrade/LDST/00070317/0000/00070317_00000033_2.ldst' -] - -IOExtension().inputFiles(input_files, clear=True) +options.set_conds_from_testfiledb('MiniBrunel_2018_MinBias_FTv4_DIGI') diff --git a/Hlt/Moore/tests/options/digi_input_and_conds_for_ut_v4r2_decoding_retinacluster.py b/Hlt/Moore/tests/options/digi_input_and_conds_for_ut_v4r2_decoding_retinacluster.py index 9a579bb477b..bc4ebd30412 100644 --- a/Hlt/Moore/tests/options/digi_input_and_conds_for_ut_v4r2_decoding_retinacluster.py +++ b/Hlt/Moore/tests/options/digi_input_and_conds_for_ut_v4r2_decoding_retinacluster.py @@ -12,6 +12,7 @@ from Moore import options from RecoConf.decoders import default_ft_decoding_version options.set_input_and_conds_from_testfiledb( 'upgrade-TELL40-UT-miniBias_retinacluster') +options.evt_max = 100 default_ft_decoding_version.global_bind(value=6) # overwrite options for dd4hep diff --git a/Hlt/Moore/tests/options/input_add_retina_clusters.py b/Hlt/Moore/tests/options/input_add_retina_clusters.py index fd5be44e20d..8b4ecdcaa0c 100755 --- a/Hlt/Moore/tests/options/input_add_retina_clusters.py +++ b/Hlt/Moore/tests/options/input_add_retina_clusters.py @@ -14,10 +14,11 @@ options.input_files = [ 'root://eoslhcb.cern.ch//eos/lhcb/wg/IonPhysics/Simulations/SMOG2jpsi/digi/SMOG2jpsi_0-Extended.digi' ] options.input_type = "ROOT" -options.evt_max = -1 +options.evt_max = 500 options.dddb_tag = 'dddb-20190223' options.conddb_tag = 'sim-20180530-vc-mu100' options.simulation = True +options.ioalg_buffer_nb_events = 2 options.output_file = 'test.digi' options.output_type = 'ROOT' diff --git a/Hlt/Moore/tests/options/lead_lead_input_and_conds_hlt2_mdf.py b/Hlt/Moore/tests/options/lead_lead_input_and_conds_hlt2_mdf.py index c8a70502361..5a08f5c6299 100644 --- a/Hlt/Moore/tests/options/lead_lead_input_and_conds_hlt2_mdf.py +++ b/Hlt/Moore/tests/options/lead_lead_input_and_conds_hlt2_mdf.py @@ -18,6 +18,4 @@ make_digits.global_bind(calo_raw_bank=False) options.set_input_and_conds_from_testfiledb( 'upgrade-202004-PbPb-EPOS-b-6_14fm-mdf') options.evt_max = 20 - -options.use_iosvc = True options.event_store = 'EvtStoreSvc' diff --git a/Hlt/Moore/tests/options/mdf_input_and_conds.py b/Hlt/Moore/tests/options/mdf_input_and_conds.py index 76978619cc0..265bc888d95 100644 --- a/Hlt/Moore/tests/options/mdf_input_and_conds.py +++ b/Hlt/Moore/tests/options/mdf_input_and_conds.py @@ -15,6 +15,4 @@ make_digits.global_bind(calo_raw_bank=False) options.set_input_and_conds_from_testfiledb('MiniBrunel_2018_MinBias_FTv4_MDF') options.input_files = list(set(options.input_files)) # remove dups options.evt_max = 1000 - -options.use_iosvc = True options.event_store = 'EvtStoreSvc' diff --git a/Hlt/Moore/tests/options/mdf_input_and_conds_hlt2.py b/Hlt/Moore/tests/options/mdf_input_and_conds_hlt2.py index a515bca25a0..ce8cd10e139 100644 --- a/Hlt/Moore/tests/options/mdf_input_and_conds_hlt2.py +++ b/Hlt/Moore/tests/options/mdf_input_and_conds_hlt2.py @@ -36,6 +36,4 @@ if UseDD4Hep: options.input_files = list(set(options.input_files)) # remove dups options.persistreco_version = 0.0 options.evt_max = 300 - -options.use_iosvc = True options.event_store = 'EvtStoreSvc' diff --git a/Hlt/Moore/tests/options/minimal_options.py b/Hlt/Moore/tests/options/minimal_options.py index 31ff7c0b9e0..26d6df7ec38 100644 --- a/Hlt/Moore/tests/options/minimal_options.py +++ b/Hlt/Moore/tests/options/minimal_options.py @@ -29,10 +29,7 @@ def lines(): ] -options.input_type = 'ROOT' -options.simulation = True -options.data_type = 'Upgrade' -options.dddb_tag = 'dddb-20171126' -options.conddb_tag = 'sim-20171127-vc-md100' - +options.set_input_and_conds_from_testfiledb( + 'upgrade_Sept2022_minbias_0fb_md_mdf') +options.evt_max = 0 run_moore(options, lines) diff --git a/Hlt/Moore/tests/qmtest/test_ioextension_input.qmt b/Hlt/Moore/tests/qmtest/test_ioextension_input.qmt deleted file mode 100644 index 0d66b3d6b3f..00000000000 --- a/Hlt/Moore/tests/qmtest/test_ioextension_input.qmt +++ /dev/null @@ -1,30 +0,0 @@ - - - - -gaudirun.py - - $HLT2CONFROOT/options/hlt2_ganga.py - $HLT2CONFROOT/options/hlt2_ganga_input.py - -true -600 - - -from Moore.qmtest.exclusions import remove_known_warnings -countErrorLines({"FATAL": 0, "ERROR": 0, "WARNING": 0}, - stdout=remove_known_warnings(stdout)) - - - diff --git a/Hlt/Moore/tests/qmtest/test_lbexec_hlt2_pp_2022_reprocessing_data_check.qmt b/Hlt/Moore/tests/qmtest/test_lbexec_hlt2_pp_2022_reprocessing_data_check.qmt index c310de03cd3..1115cb65b98 100644 --- a/Hlt/Moore/tests/qmtest/test_lbexec_hlt2_pp_2022_reprocessing_data_check.qmt +++ b/Hlt/Moore/tests/qmtest/test_lbexec_hlt2_pp_2022_reprocessing_data_check.qmt @@ -20,30 +20,37 @@ test_lbexec_hlt2_pp_2022_reprocessing_dataPASS -from Configurables import LHCbApp, IODataManager -from Configurables import LHCb__UnpackRawEvent, createODIN, PrintHeader -from Configurables import RawEventDump, RawBankSizeMonitor, ApplicationMgr +from PyConf.Algorithms import LHCb__UnpackRawEvent, createODIN, PrintHeader, RawEventDump, RawBankSizeMonitor +from PyConf.control_flow import CompositeNode, NodeLogic +from PyConf.application import configure_input, configure +from Moore import options -from GaudiConf import IOExtension -IOExtension().inputFiles([ +options.data_type = "Upgrade" +options.simulation = False +options.dddb_tag = "dddb-20171126" +options.conddb_tag = "sim-20171127-vc-md100" +options.input_files = [ "hlt2_pp_2022_reprocessing_data_output_full.mdf", "hlt2_pp_2022_reprocessing_data_output_turboraw.mdf", "hlt2_pp_2022_reprocessing_data_output_turcal.mdf", "hlt2_pp_2022_reprocessing_data_output_lumi.mdf", - ]) -LHCbApp().DataType = "Upgrade" -IODataManager().DisablePFNWarning = True -ApplicationMgr().TopAlg += [ - LHCb__UnpackRawEvent(BankTypes=['ODIN'], RawBankLocations=["DAQ/RawBanks/ODIN"]), - createODIN(RawBanks="DAQ/RawBanks/ODIN"), - PrintHeader(), - RawEventDump("RawEventDump", DumpData=False, - RawBanks=["Rich", "Muon", "DAQ", "ODIN", "HltDecReports", "HltRoutingBits", - "HltSelReports", "HltLumiSummary", "FTCluster", "VPRetinaCluster", "Calo", "Plume"]), - # FIXME DstData's size and content is not reproducible so we must exclude it... - RawBankSizeMonitor("RawBankSizeMon"), ] +options.input_type = 'MDF' +config = configure_input(options) +cf_node = CompositeNode( + 'reprocessing', + combine_logic=NodeLogic.NONLAZY_OR, + children=[ + PrintHeader(), + RawEventDump("RawEventDump", DumpData=False, + RawBanks=["Rich", "Muon", "DAQ", "ODIN", "HltDecReports", "HltRoutingBits", + "HltSelReports", "HltLumiSummary", "FTCluster", "VPRetinaCluster", "Calo", "Plume"]), + # FIXME DstData's size and content is not reproducible so we must exclude it... + RawBankSizeMonitor("RawBankSizeMon"), + ], + force_order=True) +config.update(configure(options, cf_node)) ../refs/empty.ref diff --git a/Hlt/RecoConf/options/add_retina_clusters_to_digi.py b/Hlt/RecoConf/options/add_retina_clusters_to_digi.py index 28a47c44747..4f8a0512445 100755 --- a/Hlt/RecoConf/options/add_retina_clusters_to_digi.py +++ b/Hlt/RecoConf/options/add_retina_clusters_to_digi.py @@ -11,9 +11,8 @@ from Moore import options, run_reconstruction from Moore.config import Reconstruction -from PyConf.Algorithms import bankKiller, Gaudi__Hive__FetchLeavesFromFile, BackwardsCompatibleMergeViewIntoRawEvent, VPRetinaClusterCreator, VPRetinaSPmixer -from PyConf.application import default_raw_banks, root_copy_input_writer -from PyConf.components import force_location +from PyConf.Algorithms import bankKiller, BackwardsCompatibleMergeViewIntoRawEvent, VPRetinaClusterCreator, VPRetinaSPmixer +from PyConf.application import default_raw_banks, default_raw_event, root_writer def combiner_digi(): @@ -24,18 +23,18 @@ def combiner_digi(): vpclus = VPRetinaClusterCreator(RawBanks=spmix.MixedRawBanks) # remove VELO SP bank spkiller = bankKiller(BankTypes=["VP"]) + # get original raw Event + rawEventLocation = default_raw_event("VP") # put mixed SPs and clusters together with rest of event raw_event_combiner = BackwardsCompatibleMergeViewIntoRawEvent( RawBankViews=[spmix.MixedRawBanks, vpclus.RetinaRawBanks], - RawEvent=force_location('/Event/DAQ/RawEvent')) + RawEvent=rawEventLocation) - input_leaves = Gaudi__Hive__FetchLeavesFromFile() # spkiller can not opt-in to automated dataflow (as it modifies the TES contents) # so need to set up a control flow node instead to explicitly decide when to run it... data = [ spkiller, raw_event_combiner, - root_copy_input_writer(options.output_file, input_leaves, - ['/Event/DAQ/RawEvent']) + root_writer(options.output_file, [rawEventLocation.location]) ] return Reconstruction('write_digi', data) diff --git a/Hlt/RecoConf/options/compare_hlt1_hlt2_ut_hits_with_mcchecking.py b/Hlt/RecoConf/options/compare_hlt1_hlt2_ut_hits_with_mcchecking.py index 4b2c14830ea..c56ee825de9 100644 --- a/Hlt/RecoConf/options/compare_hlt1_hlt2_ut_hits_with_mcchecking.py +++ b/Hlt/RecoConf/options/compare_hlt1_hlt2_ut_hits_with_mcchecking.py @@ -13,7 +13,7 @@ from PyConf.application import configure_input, configure from PyConf.control_flow import CompositeNode, NodeLogic from Allen.config import setup_allen_non_event_data_service from AllenConf.ut_reconstruction import decode_ut -from RecoConf.data_from_file import mc_unpackers +from RecoConf.data_from_file import mc_unpacker from RecoConf.legacy_rec_hlt1_tracking import make_PrStorePrUTHits_hits from Moore import options @@ -27,7 +27,7 @@ with make_PrStorePrUTHits_hits.bind(isCluster=False): test_hits = CompareRecAllenUTHitsMCCheck( ut_hit_offsets=allen_decoded_ut["dev_ut_hit_offsets"], ut_hits=allen_decoded_ut["dev_ut_hits"], - UnpackedUTHits=mc_unpackers()['MCUTHits'], + UnpackedUTHits=mc_unpacker('MCUTHits'), UTHitsLocation=rec_ut_hits) cf_node = CompositeNode( diff --git a/Hlt/RecoConf/options/examples/mc_matching_example.py b/Hlt/RecoConf/options/examples/mc_matching_example.py index 4557a4d0a83..8333891a0d5 100644 --- a/Hlt/RecoConf/options/examples/mc_matching_example.py +++ b/Hlt/RecoConf/options/examples/mc_matching_example.py @@ -26,7 +26,7 @@ from RecoConf.hlt2_tracking import ( from RecoConf.mc_checking import ( check_tracking_efficiency, make_links_lhcbids_mcparticles_tracking_system, make_links_tracks_mcparticles, make_default_IdealStateCreator) -from RecoConf.data_from_file import mc_unpackers +from RecoConf.data_from_file import mc_unpacker from RecoConf.mc_checking_categories import (get_mc_categories, get_hit_type_mask) @@ -52,21 +52,21 @@ def mc_matching(): links_to_velo_tracks = PrTrackAssociator( SingleContainer=hlt1_tracks["Velo"]["v1"], LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation links_to_seed_tracks = PrTrackAssociator( SingleContainer=seed_tracks["v1"], LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation with PrTrackAssociator.bind(FractionOK=0.5): loose_links_to_long_tracks = PrTrackAssociator( SingleContainer=seed_tracks["v1"], LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation match_debug = PrMatchNN( VeloInput=hlt1_tracks["Velo"]["Pr"], @@ -77,7 +77,7 @@ def mc_matching(): VeloTrackLinks=links_to_velo_tracks, SeedTrackLinks=links_to_seed_tracks, TrackInfo=get_mc_track_info(), - MCParticles=mc_unpackers()["MCParticles"]), + MCParticles=mc_unpacker("MCParticles")), AddUTHitsToolName=get_global_ut_hits_tool(enable=True), ).MatchOutput @@ -88,7 +88,7 @@ def mc_matching(): DebugTool=PrMCDebugForwardTool( InputTracks=hlt1_tracks["Velo"]["v1"], InputTrackLinks=links_to_velo_tracks, - MCParticles=mc_unpackers()["MCParticles"], + MCParticles=mc_unpacker("MCParticles"), SciFiHitLinks=links_to_hits, SciFiHits=make_PrStoreSciFiHits_hits(), TrackInfo=get_mc_track_info(), @@ -101,9 +101,9 @@ def mc_matching(): DebugTool=PrDebugTrackingTool()) param_data = PrParameterisationData( - MCParticles=mc_unpackers()["MCParticles"], - MCVPHits=mc_unpackers()["MCVPHits"], - MCFTHits=mc_unpackers()["MCFTHits"], + MCParticles=mc_unpacker("MCParticles"), + MCVPHits=mc_unpacker("MCVPHits"), + MCFTHits=mc_unpacker("MCFTHits"), TrackInfo=get_mc_track_info(), ) @@ -113,18 +113,18 @@ def mc_matching(): links_to_fitted_tracks = PrTrackAssociator( SingleContainer=fitted_seed_tracks, LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation tracking_losses = PrDebugTrackingLosses( TrackType="Ttrack", RecAs="fromB", StudyTracks=seed_tracks["v1"], VeloTracks=hlt1_tracks["Velo"]["v1"], - MCParticles=mc_unpackers()["MCParticles"], - MCVPHits=mc_unpackers()["MCVPHits"], - MCUTHits=mc_unpackers()["MCUTHits"], - MCFTHits=mc_unpackers()["MCFTHits"], + MCParticles=mc_unpacker("MCParticles"), + MCVPHits=mc_unpacker("MCVPHits"), + MCUTHits=mc_unpacker("MCUTHits"), + MCFTHits=mc_unpacker("MCFTHits"), VeloTrackLinks=links_to_velo_tracks, TrackLinks=links_to_seed_tracks, LooseTrackLinks=loose_links_to_long_tracks, diff --git a/Hlt/RecoConf/options/examples/run_pr_tracking_losses.py b/Hlt/RecoConf/options/examples/run_pr_tracking_losses.py index 38cc6bfad26..2c1f7f242fa 100644 --- a/Hlt/RecoConf/options/examples/run_pr_tracking_losses.py +++ b/Hlt/RecoConf/options/examples/run_pr_tracking_losses.py @@ -10,7 +10,7 @@ ############################################################################### from Moore import options, run_reconstruction from Moore.config import Reconstruction -from RecoConf.data_from_file import mc_unpackers +from RecoConf.data_from_file import mc_unpacker from RecoConf.legacy_rec_hlt1_tracking import make_VeloClusterTrackingSIMD_hits from RecoConf.hlt2_tracking import ( make_hlt2_tracks, make_PrKalmanFilter_tracks, make_PrStorePrUTHits_hits, @@ -59,37 +59,37 @@ def run_tracking_losses(): links_to_velo_tracks = PrTrackAssociator( SingleContainer=hlt2_tracks["Velo"]["v1"], LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation links_to_long_tracks = PrTrackAssociator( SingleContainer=hlt2_tracks["Forward"]["v1"], LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation with PrTrackAssociator.bind(FractionOK=0.5): loose_links_to_long_tracks = PrTrackAssociator( SingleContainer=hlt2_tracks["Forward"]["v1"], LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation links_to_fitted_tracks = PrTrackAssociator( SingleContainer=fitted_forward_tracks, LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation tracking_losses = PrDebugTrackingLosses( name="PrDebugTrackingLosses", TrackType="Long", StudyTracks=hlt2_tracks["Forward"]["v1"], VeloTracks=hlt2_tracks["Velo"]["v1"], - MCParticles=mc_unpackers()["MCParticles"], - MCVPHits=mc_unpackers()["MCVPHits"], - MCUTHits=mc_unpackers()["MCUTHits"], - MCFTHits=mc_unpackers()["MCFTHits"], + MCParticles=mc_unpacker("MCParticles"), + MCVPHits=mc_unpacker("MCVPHits"), + MCUTHits=mc_unpacker("MCUTHits"), + MCFTHits=mc_unpacker("MCFTHits"), VeloTrackLinks=links_to_velo_tracks, TrackLinks=links_to_long_tracks, LooseTrackLinks=loose_links_to_long_tracks, diff --git a/Hlt/RecoConf/options/hlt1_reco_allen_calo_resolution.py b/Hlt/RecoConf/options/hlt1_reco_allen_calo_resolution.py index ee04399556b..b7f3728e405 100644 --- a/Hlt/RecoConf/options/hlt1_reco_allen_calo_resolution.py +++ b/Hlt/RecoConf/options/hlt1_reco_allen_calo_resolution.py @@ -13,7 +13,7 @@ from Moore import options from RecoConf.calorimeter_mc_checking import check_calo_cluster_resolution from RecoConf.calorimeter_reconstruction import make_calo_reduced -from RecoConf.data_from_file import boole_links_digits_mcparticles, mc_unpackers +from RecoConf.data_from_file import boole_links_digits_mcparticles, mc_unpacker from RecoConf.hlt1_allen import make_allen_calo_clusters, allen_gaudi_config from AllenCore.gaudi_allen_generator import allen_runtime_options @@ -32,19 +32,19 @@ def make_reconstruction(): ecal_digits = calo['digitsEcal'] # get MCParticles - mcparts = mc_unpackers()["MCParticles"] + mcparts = mc_unpacker("MCParticles") # get Digit2MC table tableMCCaloDigits = CaloFutureDigit2MCLinks2Table( CaloDigits=ecal_digits, MCParticles=mcparts, - Link=boole_links_digits_mcparticles()["EcalDigitsV1"], + Link=boole_links_digits_mcparticles("EcalDigitsV1"), ).Output # get Clusterv22MC table tableMCCaloClusters = CaloClusterMCTruth( InputRelations=tableMCCaloDigits, - Input=boole_links_digits_mcparticles()['EcalDigits'], + Input=boole_links_digits_mcparticles('EcalDigits'), MCParticleLocation=mcparts, Clusters=ecal_clusters_allen).Output diff --git a/Hlt/RecoConf/options/mdf_for_standalone_Allen.py b/Hlt/RecoConf/options/mdf_for_standalone_Allen.py index abcd2d4f4e1..4e2d9b30c66 100644 --- a/Hlt/RecoConf/options/mdf_for_standalone_Allen.py +++ b/Hlt/RecoConf/options/mdf_for_standalone_Allen.py @@ -30,6 +30,14 @@ mdf_dir = base_dir + "mdf_" + conddb_tag + "/" for idir in [mdf_dir, geom_dir]: if not os.path.exists(idir): os.makedirs(idir) +# cleanup possible remnants of previous runs of the test +# without this, the test may fail for missing counters as +# the dump won't actually be ran +for f in os.listdir(geom_dir): + fullpath = os.path.join(geom_dir, f) + if os.path.isfile(fullpath) and f.endswith('.bin'): + os.remove(fullpath) + mdf_file = mdf_dir + "dumped_file.mdf" options.output_type = 'MDF' diff --git a/Hlt/RecoConf/options/phoenix_event_data_dump.py b/Hlt/RecoConf/options/phoenix_event_data_dump.py index 07b984b632e..c8584e823be 100644 --- a/Hlt/RecoConf/options/phoenix_event_data_dump.py +++ b/Hlt/RecoConf/options/phoenix_event_data_dump.py @@ -11,7 +11,6 @@ from Moore import options, run_reconstruction from RecoConf.decoders import default_VeloCluster_source from RecoConf.standalone import phoenix_data_dump_hlt2 -from Moore.qmtest.context import download_mdf_inputs_locally from Configurables import LHCb__Det__LbDD4hep__DD4hepSvc as DD4hepSvc dd4hepSvc = DD4hepSvc() @@ -21,16 +20,9 @@ dd4hepSvc.DetectorList = [ ] options.evt_max = 20 -options.use_iosvc = True options.event_store = 'EvtStoreSvc' options.phoenix_filename = "LHCb_EventDataset.json" options.set_input_and_conds_from_testfiledb('2023_07_04_run268773') -AVERAGE_EVENT_SIZE = 500 * 1000 # upper limit of average event size -options.input_files = download_mdf_inputs_locally( - options.input_files, - dest_dir='.', - max_size=options.evt_max * AVERAGE_EVENT_SIZE) - with default_VeloCluster_source.bind(bank_type="VPRetinaCluster"): run_reconstruction(options, phoenix_data_dump_hlt2) diff --git a/Hlt/RecoConf/options/tracking_developments/run_cheated_pattern_recognition.py b/Hlt/RecoConf/options/tracking_developments/run_cheated_pattern_recognition.py index 8a0cb10612d..5d353d4d3c6 100644 --- a/Hlt/RecoConf/options/tracking_developments/run_cheated_pattern_recognition.py +++ b/Hlt/RecoConf/options/tracking_developments/run_cheated_pattern_recognition.py @@ -11,7 +11,7 @@ from Moore import options, run_reconstruction from Moore.config import Reconstruction from RecoConf.mc_checking import make_default_IdealStateCreator, get_track_checkers -from RecoConf.data_from_file import mc_unpackers, boole_links_digits_mcparticles +from RecoConf.data_from_file import mc_unpacker, boole_links_digits_mcparticles from RecoConf.legacy_rec_hlt1_tracking import (make_legacy_rec_hlt1_tracks, all_upstream_track_types) from RecoConf.hlt2_tracking import (make_PrStoreSciFiHits_hits, @@ -37,8 +37,8 @@ def run_cheated(): cheated_long_tracking = PrCheatedLongTracking( LHCbIdLinkLocation=links_to_hits, FTHitsLocation=make_PrStoreSciFiHits_hits(), - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesLocation=mc_unpackers()["MCVertices"], + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesLocation=mc_unpacker("MCVertices"), MCPropertyLocation=get_mc_track_info(), IdealStateCreator=make_default_IdealStateCreator(), AddIdealStates=True) @@ -51,10 +51,10 @@ def run_cheated(): cheated_seed_tracking_pr = PrCheatedSciFiTracking( FTHitsLocation=make_PrStoreSciFiHits_hits( ), #from legacy_rec_hlt1_tracking - MCParticleLocation=mc_unpackers()["MCParticles"], + MCParticleLocation=mc_unpacker("MCParticles"), MCPropertyLocation=get_mc_track_info(), - LinkLocation=boole_links_digits_mcparticles() - ["FTLiteClusters"]).OutputName + LinkLocation=boole_links_digits_mcparticles( + "FTLiteClusters")).OutputName cheated_seed_tracking_v1 = fromPrSeedingTracksV1Tracks( InputTracksLocation=cheated_seed_tracking_pr).OutputTracksLocation @@ -86,12 +86,12 @@ def run_cheated(): # Now it's showtime: resolutions from PyConf.Algorithms import TrackResChecker from PyConf.Tools import VisPrimVertTool - mcpart = mc_unpackers()["MCParticles"] + mcpart = mc_unpacker("MCParticles") mchead = get_mc_header() mcprop = get_mc_track_info() res_long_checker = TrackResChecker( TracksInContainer=best_long_tracks, - MCParticleInContainer=mc_unpackers()["MCParticles"], + MCParticleInContainer=mc_unpacker("MCParticles"), LinkerInTable=links_to_long_tracks, StateCreator=make_default_IdealStateCreator(), VisPrimVertTool=VisPrimVertTool( @@ -101,7 +101,7 @@ def run_cheated(): MCProperties=mcprop)) res_seed_checker = TrackResChecker( TracksInContainer=best_seed_tracks, - MCParticleInContainer=mc_unpackers()["MCParticles"], + MCParticleInContainer=mc_unpacker("MCParticles"), LinkerInTable=links_to_seed_tracks, StateCreator=make_default_IdealStateCreator(), VisPrimVertTool=VisPrimVertTool( diff --git a/Hlt/RecoConf/options/tracking_developments/run_pr_parameterisation_data.py b/Hlt/RecoConf/options/tracking_developments/run_pr_parameterisation_data.py index 5967280875f..e0df95bd0b1 100644 --- a/Hlt/RecoConf/options/tracking_developments/run_pr_parameterisation_data.py +++ b/Hlt/RecoConf/options/tracking_developments/run_pr_parameterisation_data.py @@ -12,7 +12,7 @@ from Moore import options, run_reconstruction from Moore.config import Reconstruction from PRConfig.TestFileDB import test_file_db from PyConf.Algorithms import PrParameterisationData -from RecoConf.data_from_file import mc_unpackers +from RecoConf.data_from_file import mc_unpacker from PyConf.reading import get_mc_track_info """This is an example of how to run the data producer for pattern reconstruction parameterisations. @@ -45,11 +45,11 @@ options.input_type = "ROOT" options.set_conds_from_testfiledb(f"upgrade_DC19_01_Dst2D0pi{polarity}") -def run_tracking_param_debug(): +def run_tracking_param_debug(options): param_data = PrParameterisationData( - MCParticles=mc_unpackers()["MCParticles"], - MCVPHits=mc_unpackers()["MCVPHits"], - MCFTHits=mc_unpackers()["MCFTHits"], + MCParticles=mc_unpacker("MCParticles"), + MCVPHits=mc_unpacker("MCVPHits"), + MCFTHits=mc_unpacker("MCFTHits"), zRef=8520.0, TrackInfo=get_mc_track_info(), ) diff --git a/Hlt/RecoConf/options/tracking_developments/run_pr_tracking_debug.py b/Hlt/RecoConf/options/tracking_developments/run_pr_tracking_debug.py index eec4d4ce869..d6ccb21f9f2 100644 --- a/Hlt/RecoConf/options/tracking_developments/run_pr_tracking_debug.py +++ b/Hlt/RecoConf/options/tracking_developments/run_pr_tracking_debug.py @@ -10,7 +10,7 @@ ############################################################################### from Moore import options, run_reconstruction from Moore.config import Reconstruction -from RecoConf.data_from_file import mc_unpackers +from RecoConf.data_from_file import mc_unpacker from RecoConf.legacy_rec_hlt1_tracking import (make_legacy_rec_hlt1_tracks, make_PrStoreSciFiHits_hits) @@ -42,14 +42,14 @@ def run_tracking_debug(): links_to_velo_tracks = PrTrackAssociator( SingleContainer=hlt1_tracks["Velo"]["v1"], LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation links_to_seed_tracks = PrTrackAssociator( SingleContainer=seed_tracks["v1"], LinkerLocationID=links_to_hits, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation match_debug = PrMatchNN( VeloInput=hlt1_tracks["Velo"]["Pr"], @@ -60,7 +60,7 @@ def run_tracking_debug(): VeloTrackLinks=links_to_velo_tracks, SeedTrackLinks=links_to_seed_tracks, TrackInfo=get_mc_track_info(), - MCParticles=mc_unpackers()["MCParticles"]), + MCParticles=mc_unpacker("MCParticles")), AddUTHitsToolName=get_global_ut_hits_tool(enable=True), ).MatchOutput @@ -71,7 +71,7 @@ def run_tracking_debug(): DebugTool=PrMCDebugForwardTool( InputTracks=hlt1_tracks["Velo"]["v1"], InputTrackLinks=links_to_velo_tracks, - MCParticles=mc_unpackers()["MCParticles"], + MCParticles=mc_unpacker("MCParticles"), SciFiHitLinks=links_to_hits, SciFiHits=make_PrStoreSciFiHits_hits(), TrackInfo=get_mc_track_info(), diff --git a/Hlt/RecoConf/python/RecoConf/calorimeter_mc_checking.py b/Hlt/RecoConf/python/RecoConf/calorimeter_mc_checking.py index 4d0e7a05c8f..e1385222af6 100644 --- a/Hlt/RecoConf/python/RecoConf/calorimeter_mc_checking.py +++ b/Hlt/RecoConf/python/RecoConf/calorimeter_mc_checking.py @@ -11,7 +11,7 @@ from PyConf.Algorithms import CaloFutureClusterResolution, CaloFutureHypoResolution from PyConf.Algorithms import CaloFutureDigit2MCLinks2Table, CaloClusterMCTruth from PyConf.Algorithms import CaloClusterEfficiency, CaloHypoEfficiency, CaloChargedPIDsChecker -from .data_from_file import boole_links_digits_mcparticles, mc_unpackers +from .data_from_file import boole_links_digits_mcparticles, mc_unpacker from .mc_checking import make_links_lhcbids_mcparticles_tracking_system, make_links_tracks_mcparticles @@ -21,19 +21,19 @@ def get_mc_info(calo): ecalClusters = calo["ecalClusters"] # get MCParticles - mcparts = mc_unpackers()["MCParticles"] + mcparts = mc_unpacker("MCParticles") # get Digit2MC table tableMCCaloDigits = CaloFutureDigit2MCLinks2Table( CaloDigits=ecalDigits, MCParticles=mcparts, - Link=boole_links_digits_mcparticles()["EcalDigitsV1"], + Link=boole_links_digits_mcparticles("EcalDigitsV1"), ).Output # get Clusterv22MC table tableMCCaloClusters = CaloClusterMCTruth( InputRelations=tableMCCaloDigits, - Input=boole_links_digits_mcparticles()['EcalDigits'], + Input=boole_links_digits_mcparticles("EcalDigits"), MCParticleLocation=mcparts, Clusters=ecalClusters).Output @@ -98,7 +98,7 @@ def check_calo_cluster_efficiency(calo, parentID=511, name="", minET=50.): CaloClusterEfficiency( inputRelationsCluster=tableMCClusters, inputRelationsDigitOld=tableMCDigits, - inputRelationsDigit=boole_links_digits_mcparticles()['EcalDigits'], + inputRelationsDigit=boole_links_digits_mcparticles("EcalDigits"), inputMCParticles=mcparts, recoClusters=calo["ecalClusters"], caloDigits=calo["digitsEcal"], @@ -121,7 +121,7 @@ def check_pi0_cluster_efficiency(calo, fromB=511, name=""): eff_resolved = CaloClusterEfficiency( inputRelationsCluster=tableMCClusters, inputRelationsDigitOld=tableMCDigits, - inputRelationsDigit=boole_links_digits_mcparticles()['EcalDigits'], + inputRelationsDigit=boole_links_digits_mcparticles("EcalDigits"), inputMCParticles=mcparts, recoClusters=calo["ecalClusters"], caloDigits=calo["digitsEcal"], @@ -140,7 +140,7 @@ def check_pi0_cluster_efficiency(calo, fromB=511, name=""): eff_merged = CaloClusterEfficiency( inputRelationsCluster=tableMCClusters, inputRelationsDigitOld=tableMCDigits, - inputRelationsDigit=boole_links_digits_mcparticles()['EcalDigits'], + inputRelationsDigit=boole_links_digits_mcparticles("EcalDigits"), inputMCParticles=mcparts, recoClusters=calo["ecalClusters"], caloDigits=calo["digitsEcal"], @@ -184,7 +184,7 @@ def check_calo_charged_pids(tracks, brems, checktracktype=False, tracktype="Long"): - mcparts = mc_unpackers()["MCParticles"] + mcparts = mc_unpacker("MCParticles") links_to_lhcbids = make_links_lhcbids_mcparticles_tracking_system() links_to_tracks = make_links_tracks_mcparticles( InputTracks=tracks, LinksToLHCbIDs=links_to_lhcbids) diff --git a/Hlt/RecoConf/python/RecoConf/data_from_file.py b/Hlt/RecoConf/python/RecoConf/data_from_file.py index 2b89e6f4472..2443bd9c5b6 100644 --- a/Hlt/RecoConf/python/RecoConf/data_from_file.py +++ b/Hlt/RecoConf/python/RecoConf/data_from_file.py @@ -12,8 +12,7 @@ There are two things we have to deal with: -1. Loading the data from the file in to the TES, done by - Gaudi::Hive::FetchDataFromFile. +1. Loading the data from the file in to the TES, done by PyConf.input_from_root_file 2. Unpacking and preparing packed containers, if the 'reconstruction' is defined as the objects already present in the file. @@ -24,10 +23,7 @@ information to ProtoParticles when they're unpacked. Because we don't have the DataOnDemandSvc here, we have to do this by hand. The interesting 'user-facing' exports of this module are: - -* [reco,mc]_from_file(): Dict of names to locations that can be loaded from a file. -* [reco,mc]_unpackers(): Dict from unpacked object name to Algorithm that produces a - container of those objects. +* [reco,mc]_unpacker(): get Algorithm that produces a container of given unpacked object name. """ import collections @@ -44,7 +40,7 @@ from Configurables import (UnpackMuonPIDs, UnpackRichPIDs, UnpackCaloHypo, MCRichDigitSummaryUnpacker) from PyConf.components import Algorithm, force_location -from PyConf.application import make_data_with_FetchDataFromFile +from PyConf.application import input_from_root_file from PyConf.Tools import ( ChargedProtoParticleAddRichInfo, ChargedProtoParticleAddMuonInfo, ChargedProtoParticleAddCaloHypos, ChargedProtoParticleAddCombineDLLs) @@ -71,12 +67,11 @@ def _unpacker(forced_type, packed_loc, unpacked_loc, **kwargs): _unpack_configurable[forced_type], name=f"Unpack_{unpacked_loc.replace('/','_')}", outputs={'OutputName': force_location(unpacked_loc)}, - InputName=make_data_with_FetchDataFromFile( - packed_loc, force_type=forced_type), + InputName=input_from_root_file(packed_loc, forced_type=forced_type), **kwargs) -def reco_unpackers(): +def _get_reco_unpackers(): # for each key, specify both the location in the TES and the type that is # expected to be made available by reading it from a file _packed_reco_from_file = { @@ -142,7 +137,11 @@ def reco_unpackers(): ]) -def mc_unpackers(): +# precomputed dict of reco unpackers, will be filled on first use +_reco_unpackers = None + + +def _get_mc_unpackers(): # for each key, specify both the location in the TES and the type that is # expected to be made available by reading it from a file _packed_mc_from_file = { @@ -188,7 +187,41 @@ def mc_unpackers(): ]) -def boole_links_digits_mcparticles(): +# precomputed dict of mc unpackers, will be filled on first use +_mc_unpackers = None + + +def reco_unpacker(key): + '''Returns the adequate unpacker for the given key''' + global _reco_unpackers + if _reco_unpackers is None: + _reco_unpackers = _get_reco_unpackers() + return _reco_unpackers[key] + + +def reco_unpackers(): + global _reco_unpackers + if _reco_unpackers is None: + _reco_unpackers = _get_reco_unpackers() + return _reco_unpackers + + +def mc_unpacker(key): + '''Returns the adequate unpacker for the given key''' + global _mc_unpackers + if _mc_unpackers is None: + _mc_unpackers = _get_mc_unpackers() + return _mc_unpackers[key] + + +def mc_unpackers(): + global _mc_unpackers + if _mc_unpackers is None: + _mc_unpackers = _get_mc_unpackers() + return _mc_unpackers + + +def boole_links_digits_mcparticles(key): """Return a dict of locations for MC linker tables (to mcparticles) created by Boole.""" locations = { "EcalDigitsV1": "/Event/Link/Raw/Ecal/Digits", @@ -201,36 +234,24 @@ def boole_links_digits_mcparticles(): "UTDigits": "/Event/Link/Raw/UT/TightDigits", "VPDigits": "/Event/Link/Raw/VP/Digits", } - mc_particles = mc_unpackers()['MCParticles'] - return { - key: make_data_with_FetchDataFromFile( - loc, force_type='LHCb::LinksByKey', ExtraInputs=[mc_particles]) - for key, loc in locations.items() - } + return input_from_root_file(locations[key], forced_type='LHCb::LinksByKey') -def boole_links_digits_mchits(): +def boole_links_digits_mchits(key): """Return a dict of locations for MC linker tables (to mchits) created by Boole. - These locations are only propagated out of Boole for eXtendend DIGI and DST types. + These locations are only propagated out of Boole for extendend DIGI and DST types. """ - locations_and_dep = { - "FTLiteClusters": ("/Event/Link/Raw/FT/LiteClusters2MCHits", - 'MCFTHits'), - "UTClusters": ("/Event/Link/Raw/UT/Clusters2MCHits", 'MCUTHits'), - "UTDigits": ("/Event/Link/Raw/UT/TightDigits2MCHits", 'MCUTHits'), - "VPDigits": ("/Event/Link/Raw/VP/Digits2MCHits", 'MCVPHits') - } - return { - key: make_data_with_FetchDataFromFile( - loc, - force_type='LHCb::LinksByKey', - ExtraInputs=[mc_unpackers()[dep]]) - for key, (loc, dep) in locations_and_dep.items() + locations = { + "FTLiteClusters": "/Event/Link/Raw/FT/LiteClusters2MCHits", + "UTClusters": "/Event/Link/Raw/UT/Clusters2MCHits", + "UTDigits": "/Event/Link/Raw/UT/TightDigits2MCHits", + "VPDigits": "/Event/Link/Raw/VP/Digits2MCHits", } + return input_from_root_file(locations[key], forced_type='LHCb::LinksByKey') -def brunel_links(): +def brunel_links(key): """Return a dict of locations for MC linker tables created by Brunel.""" locations = { "CaloElectrons": "/Event/Link/Rec/Calo/Electrons", @@ -239,8 +260,4 @@ def brunel_links(): "CaloSplitPhotons": "/Event/Link/Rec/Calo/SplitPhotons", "Tracks": "/Event/Link/Rec/Track/Best", } - return { - key: make_data_with_FetchDataFromFile( - loc, force_type='LHCb::LinksByKey') - for key, loc in locations.items() - } + return input_from_root_file(locations[key], forced_type='LHCb::LinksByKey') diff --git a/Hlt/RecoConf/python/RecoConf/hlt1_allen.py b/Hlt/RecoConf/python/RecoConf/hlt1_allen.py index 8cf1b8a5af4..29c4fd64fc8 100644 --- a/Hlt/RecoConf/python/RecoConf/hlt1_allen.py +++ b/Hlt/RecoConf/python/RecoConf/hlt1_allen.py @@ -472,7 +472,7 @@ def combine_raw_banks_with_MC_data_for_standalone_Allen_checkers( algs.append(pvDumper) detector_parts = [ - default_raw_event([bt]) for bt in bank_types_for_detectors() + default_raw_event(bt) for bt in bank_types_for_detectors() ] # get only unique elements while preserving order detector_parts = list(dict.fromkeys(detector_parts).keys()) diff --git a/Hlt/RecoConf/python/RecoConf/hlt2_global_reco.py b/Hlt/RecoConf/python/RecoConf/hlt2_global_reco.py index 8be80e5aefc..800686e8055 100644 --- a/Hlt/RecoConf/python/RecoConf/hlt2_global_reco.py +++ b/Hlt/RecoConf/python/RecoConf/hlt2_global_reco.py @@ -287,9 +287,6 @@ def reconstruction(make_reconstruction=make_light_reco_pr_kf_without_UT): """Hook to allow switching between reconstructions. make_reconstruction (function): which reconstruction to run. - - Note it is advised to use this function if more than one object is needed, - rather than the accessors below as it makes the configuration slower. """ reco_output = make_reconstruction() # Create the summary of the reconstruction @@ -304,7 +301,7 @@ def make_charged_protoparticles(track_type): which produces the full information at this location needs to be scheduled explicitly by including the `upfront_reconstruction` method in the file in the control flow. """ - return reconstruction()[track_type] + return reconstruction(track_type) def upfront_reconstruction(): @@ -317,7 +314,7 @@ def upfront_reconstruction(): by including the `upfront_reconstruction` method in the file in the control flow. """ - return reconstruction()["UpfrontReconstruction"] + return reconstruction("UpfrontReconstruction") def make_neutral_protoparticles(): @@ -327,17 +324,17 @@ def make_neutral_protoparticles(): schedule the upfront reconstruction explicitly. """ - return reconstruction()["NeutralProtos"] + return reconstruction("NeutralProtos") def make_pvs(): """Return a DataHandle to the container of PVs """ - return reconstruction()["PVs"] + return reconstruction("PVs") def make_tracks(track_type="Long"): """Return a DataHandle to the container of certain tracks """ - return reconstruction()[f"{track_type}Tracks"] + return reconstruction(f"{track_type}Tracks") diff --git a/Hlt/RecoConf/python/RecoConf/mc_checking.py b/Hlt/RecoConf/python/RecoConf/mc_checking.py index 73ca0270934..c508a71504a 100644 --- a/Hlt/RecoConf/python/RecoConf/mc_checking.py +++ b/Hlt/RecoConf/python/RecoConf/mc_checking.py @@ -41,7 +41,7 @@ from RecoConf.hlt2_tracking import (make_PrStoreUTHit_hits, make_VPClus_hits, from RecoConf.mc_checking_categories import get_mc_categories, get_hit_type_mask, categories from RecoConf.muonid import make_muon_hits -from .data_from_file import boole_links_digits_mcparticles, boole_links_digits_mchits, mc_unpackers +from .data_from_file import boole_links_digits_mcparticles, boole_links_digits_mchits, mc_unpacker import Functors as F @@ -58,9 +58,9 @@ def get_item(x, key): def make_links_veloclusters_mcparticles(): return VPFullCluster2MCParticleLinker( ClusterLocation=make_velo_full_clusters(), - MCParticlesLocation=mc_unpackers()["MCParticles"], - VPDigit2MCParticleLinksLocation=boole_links_digits_mcparticles() - ["VPDigits"], + MCParticlesLocation=mc_unpacker("MCParticles"), + VPDigit2MCParticleLinksLocation=boole_links_digits_mcparticles( + "VPDigits"), ).OutputLocation @@ -68,15 +68,15 @@ def make_links_veloclusters_mcparticles(): def make_links_veloclusters_mchits(): return VPFullCluster2MCHitLinker( ClusterLocation=make_velo_full_clusters(), - MCHitLocation=mc_unpackers()["MCVPHits"], - VPDigit2MCHitLinksLocation=boole_links_digits_mchits()["VPDigits"], + MCHitLocation=mc_unpacker("MCVPHits"), + VPDigit2MCHitLinksLocation=boole_links_digits_mchits("VPDigits"), ).OutputLocation @configurable def make_links_lhcbids_mcparticles_VP(): return PrLHCbID2MCParticleVP( - MCParticlesLocation=mc_unpackers()["MCParticles"], + MCParticlesLocation=mc_unpacker("MCParticles"), VPFullClustersLocation=make_velo_full_clusters(), VPFullClustersLinkLocation=make_links_veloclusters_mcparticles(), ).TargetName @@ -85,38 +85,37 @@ def make_links_lhcbids_mcparticles_VP(): @configurable def make_links_lhcbids_mcparticles_VP_UT(): return PrLHCbID2MCParticleVPUT( - MCParticlesLocation=mc_unpackers()["MCParticles"], + MCParticlesLocation=mc_unpacker("MCParticles"), VPFullClustersLocation=make_velo_full_clusters(), VPFullClustersLinkLocation=make_links_veloclusters_mcparticles(), UTHitsLocation=make_PrStoreUTHit_hits(), - UTHitsLinkLocation=boole_links_digits_mcparticles()["UTClusters"], + UTHitsLinkLocation=boole_links_digits_mcparticles("UTClusters"), ).TargetName @configurable def make_links_lhcbids_mcparticles_VP_FT(): return PrLHCbID2MCParticleVPFT( - MCParticlesLocation=mc_unpackers()["MCParticles"], + MCParticlesLocation=mc_unpacker("MCParticles"), VPFullClustersLocation=make_velo_full_clusters(), VPFullClustersLinkLocation=make_links_veloclusters_mcparticles(), FTLiteClustersLocation=make_FTRawBankDecoder_clusters(), - FTLiteClustersLinkLocation=boole_links_digits_mcparticles() - ["FTLiteClusters"], + FTLiteClustersLinkLocation=boole_links_digits_mcparticles( + "FTLiteClusters"), ).TargetName @configurable def make_links_lhcbids_mcparticles_tracking_system(): return PrLHCbID2MCParticle( - MCParticlesLocation=mc_unpackers()["MCParticles"], + MCParticlesLocation=mc_unpacker("MCParticles"), VPFullClustersLocation=make_velo_full_clusters(), VPFullClustersLinkLocation=make_links_veloclusters_mcparticles(), UTHitsLocation=make_PrStoreUTHit_hits(), - UTHitsLinkLocation=boole_links_digits_mcparticles()["UTClusters"], - #UTHitsLinkLocation=boole_links_digits_mcparticles()["UTDigits"], + UTHitsLinkLocation=boole_links_digits_mcparticles("UTClusters"), FTLiteClustersLocation=make_FTRawBankDecoder_clusters(), - FTLiteClustersLinkLocation=boole_links_digits_mcparticles() - ["FTLiteClusters"], + FTLiteClustersLinkLocation=boole_links_digits_mcparticles( + "FTLiteClusters"), ).TargetName @@ -127,29 +126,27 @@ def make_links_lhcbids_mcparticles_tracking_and_muon_system( """ if with_ut: return PrLHCbID2MCParticleVPUTFTMU( - MCParticlesLocation=mc_unpackers()["MCParticles"], + MCParticlesLocation=mc_unpacker("MCParticles"), VPFullClustersLocation=make_velo_full_clusters(), VPFullClustersLinkLocation=make_links_veloclusters_mcparticles(), UTHitsLocation=make_PrStoreUTHit_hits(), - UTHitsLinkLocation=boole_links_digits_mcparticles()["UTClusters"], + UTHitsLinkLocation=boole_links_digits_mcparticles("UTClusters"), FTLiteClustersLocation=make_FTRawBankDecoder_clusters(), - FTLiteClustersLinkLocation=boole_links_digits_mcparticles() - ["FTLiteClusters"], + FTLiteClustersLinkLocation=boole_links_digits_mcparticles( + "FTLiteClusters"), MuonHitsLocation=make_muon_hits(), - MuonHitsLinkLocation=boole_links_digits_mcparticles() - ["MuonDigits"], + MuonHitsLinkLocation=boole_links_digits_mcparticles("MuonDigits"), ).TargetName else: return PrLHCbID2MCParticleVPFTMU( - MCParticlesLocation=mc_unpackers()["MCParticles"], + MCParticlesLocation=mc_unpacker("MCParticles"), VPFullClustersLocation=make_velo_full_clusters(), VPFullClustersLinkLocation=make_links_veloclusters_mcparticles(), FTLiteClustersLocation=make_FTRawBankDecoder_clusters(), - FTLiteClustersLinkLocation=boole_links_digits_mcparticles() - ["FTLiteClusters"], + FTLiteClustersLinkLocation=boole_links_digits_mcparticles( + "FTLiteClusters"), MuonHitsLocation=make_muon_hits(), - MuonHitsLinkLocation=boole_links_digits_mcparticles() - ["MuonDigits"], + MuonHitsLinkLocation=boole_links_digits_mcparticles("MuonDigits"), ).TargetName @@ -158,8 +155,8 @@ def make_links_tracks_mcparticles(InputTracks, LinksToLHCbIDs): return PrTrackAssociator( SingleContainer=get_item(InputTracks, "v1"), LinkerLocationID=LinksToLHCbIDs, - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation @configurable @@ -182,8 +179,8 @@ def check_tracking_efficiency( "TrackChecker_{hash}", # TODO: replace with name=f"TrackChecker_{TrackType}", Tracks=get_item(InputTracks, "v1"), Links=LinksToTracks, - MCParticleInput=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"], + MCParticleInput=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices"), LinkTableLocation=LinksToLHCbIDs, MCPropertyInput=get_mc_track_info(), LoKiFactory=LoKi__Hybrid__MCTool(Modules=["LoKiMC.decorators"]), @@ -211,8 +208,8 @@ def check_tracking_efficiency_vs_multiplicity( name=TrackType + "MultiplicityChecker_{hash}", Tracks=get_item(InputTracks, "v1"), Links=LinksToTracks, - MCParticleInput=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"], + MCParticleInput=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices"), MCPropertyInput=get_mc_track_info(), Velo_Hits=make_VeloClusterTrackingSIMD_hits(), Velo_Tracks=make_VeloClusterTrackingSIMD_tracks()['Pr'], @@ -245,8 +242,8 @@ def monitor_uthit_efficiency( name=TrackType + "UTHitsChecker_{hash}", Tracks=get_item(InputTracks, "v1"), Links=LinksToTracks, - MCParticleInput=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"], + MCParticleInput=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices"), LinkTableLocation=LinksToLHCbIDs, MCPropertyInput=get_mc_track_info(), LoKiFactory=LoKi__Hybrid__MCTool(Modules=["LoKiMC.decorators"]), @@ -468,8 +465,8 @@ def get_pv_checkers(pvs, tracks, produce_ntuple=False, nTracksToBeRecble=4): nTracksToBeRecble=nTracksToBeRecble, inputVerticesName=pvs, inputTracksName=tracks["v1"], - MCVertexInput=mc_unpackers()["MCVertices"], - MCParticleInput=mc_unpackers()["MCParticles"], + MCVertexInput=mc_unpacker("MCVertices"), + MCParticleInput=mc_unpacker("MCParticles"), MCHeaderLocation=get_mc_header(), MCPropertyInput=get_mc_track_info()) ] @@ -481,11 +478,11 @@ def make_track_filter(InputTracks, code): def make_default_IdealStateCreator(public=False): - mcpart = mc_unpackers()["MCParticles"] - mcvert = mc_unpackers()["MCVertices"] - vphits = mc_unpackers()["MCVPHits"] - uthits = mc_unpackers()["MCUTHits"] - fthits = mc_unpackers()["MCFTHits"] + mcpart = mc_unpacker("MCParticles") + mcvert = mc_unpacker("MCVertices") + vphits = mc_unpacker("MCVPHits") + uthits = mc_unpacker("MCUTHits") + fthits = mc_unpacker("MCFTHits") link_vp_hits = MCParticle2MCHitAlg(MCParticles=mcpart, MCHitPath=vphits) link_ut_hits = MCParticle2MCHitAlg(MCParticles=mcpart, MCHitPath=uthits) @@ -513,7 +510,7 @@ def check_track_resolution( suffix=None, **kwargs): - mcpart = mc_unpackers()["MCParticles"] + mcpart = mc_unpacker("MCParticles") return TrackResChecker( name="TrackResChecker" + (suffix @@ -536,9 +533,9 @@ def check_track_resolution( def vphits_resolution_checker(): return PrVPHitsChecker( - MCParticleLocation=mc_unpackers()["MCParticles"], + MCParticleLocation=mc_unpacker("MCParticles"), VPHitsLocation=make_VeloClusterTrackingSIMD_hits(), - MCHitsLocation=mc_unpackers()["MCVPHits"], + MCHitsLocation=mc_unpacker("MCVPHits"), VPFullClusterLocation=make_velo_full_clusters(), VPHits2MCHitLinksLocation=make_links_veloclusters_mchits(), performStudy=True, @@ -548,10 +545,9 @@ def vphits_resolution_checker(): def uthits_resolution_checker(): return PrUTHitsChecker( UTHitsLocation=make_PrStorePrUTHits_hits(), - MCHitsLocation=mc_unpackers()["MCUTHits"], - UTHits2MCHitLinksLocation=boole_links_digits_mchits() - ["UTClusters"], #["UTDigits"] - MCParticleLocation=mc_unpackers()["MCParticles"], + MCHitsLocation=mc_unpacker("MCUTHits"), + UTHits2MCHitLinksLocation=boole_links_digits_mchits("UTClusters"), + MCParticleLocation=mc_unpacker("MCParticles"), performStudy=True, isGlobal=True) @@ -560,10 +556,9 @@ def fthits_resolution_checker(): return PrFTHitsChecker( FTHitsLocation=make_PrStoreSciFiHits_hits(), FTLiteClusterLocation=make_FTRawBankDecoder_clusters(), - FTHits2MCHitLinksLocation=boole_links_digits_mchits() - ["FTLiteClusters"], - MCHitsLocation=mc_unpackers()["MCFTHits"], - MCParticleLocation=mc_unpackers()["MCParticles"], + FTHits2MCHitLinksLocation=boole_links_digits_mchits("FTLiteClusters"), + MCHitsLocation=mc_unpacker("MCFTHits"), + MCParticleLocation=mc_unpacker("MCParticles"), performStudy=True, isGlobal=True) @@ -590,7 +585,7 @@ def monitor_IPresolution(InputTracks, InputPVs, VeloTracks): InputTracks, LinksToLHCbIDs=links_to_lhcbids) IPres_checker = TrackIPResolutionCheckerNT( TrackContainer=InputTracks, - MCParticleInput=mc_unpackers()["MCParticles"], + MCParticleInput=mc_unpacker("MCParticles"), MCHeaderLocation=get_mc_header(), LinkerLocation=links_to_tracks, PVContainer=InputPVs, @@ -623,7 +618,7 @@ def checker_trigger_objects(InputTracksHLT1, else: links_to_lhcbids = make_links_lhcbids_mcparticles_VP_FT() - mcparticles = mc_unpackers()["MCParticles"] + mcparticles = mc_unpacker("MCParticles") links_to_tracksHLT1 = make_links_tracks_mcparticles( allen_tracks, LinksToLHCbIDs=links_to_lhcbids) @@ -668,7 +663,7 @@ def tracker_dumper(odin_location=make_odin, links_to_lhcbids = make_links_lhcbids_mcparticles_VP_FT() return PrTrackerDumper( - MCParticlesLocation=mc_unpackers()["MCParticles"], + MCParticlesLocation=mc_unpacker("MCParticles"), VPLightClusterLocation=velo_hits(), FTHitsLocation=make_PrStoreSciFiHits_hits(), UTHitsLocation=ut_hits, @@ -681,7 +676,7 @@ def tracker_dumper(odin_location=make_odin, def pv_dumper(odin_location=make_odin, output_dir="dump/MC_info/PVs"): from PyConf.Algorithms import PVDumper return PVDumper( - MCVerticesLocation=mc_unpackers()["MCVertices"], + MCVerticesLocation=mc_unpacker("MCVertices"), MCPropertyLocation=get_mc_track_info()) @@ -694,11 +689,11 @@ def check_velo_heavyflavour_tracking( tracklinks = PrTrackAssociator( SingleContainer=get_tracks('LongTracks'), LinkerLocationID=make_links_lhcbids_mcparticles_tracking_system(), - MCParticleLocation=mc_unpackers()["MCParticles"], - MCVerticesInput=mc_unpackers()["MCVertices"]).OutputLocation + MCParticleLocation=mc_unpacker("MCParticles"), + MCVerticesInput=mc_unpacker("MCVertices")).OutputLocation vplinks = make_links_veloclusters_mchits() - mcparts = mc_unpackers()["MCParticles"] - vphits = mc_unpackers()["MCVPHits"] + mcparts = mc_unpacker("MCParticles") + vphits = mc_unpacker("MCVPHits") return PrVeloHeavyFlavourTrackingChecker( name=name, Composites=composites, diff --git a/Hlt/RecoConf/python/RecoConf/rich_mc_checking.py b/Hlt/RecoConf/python/RecoConf/rich_mc_checking.py index f3cb990d674..d193e1e4e59 100644 --- a/Hlt/RecoConf/python/RecoConf/rich_mc_checking.py +++ b/Hlt/RecoConf/python/RecoConf/rich_mc_checking.py @@ -14,7 +14,7 @@ from GaudiKernel.SystemOfUnits import GeV from PyConf import configurable from PyConf.utilities import ConfigurationError -from .data_from_file import mc_unpackers +from .data_from_file import mc_unpacker from .mc_checking import (make_links_lhcbids_mcparticles_tracking_system, make_links_tracks_mcparticles, @@ -121,7 +121,7 @@ def make_rich_checkers(conf, reco_opts, check_opts, moni_set="Standard"): checkers = default_rich_checkers(moni_set) # MCParticles - mcps = mc_unpackers()["MCParticles"] + mcps = mc_unpacker("MCParticles") # Track linker stuff if check_opts["UseUT"]: @@ -140,7 +140,7 @@ def make_rich_checkers(conf, reco_opts, check_opts, moni_set="Standard"): MCParticlesLocation=mcps) # RICH digit MC summaries - richSummaries = mc_unpackers()["MCRichDigitSummaries"] + richSummaries = mc_unpacker("MCRichDigitSummaries") # Momentum cuts for plotting etc (by radiator) pCuts = { diff --git a/Hlt/RecoConf/python/RecoConf/standalone.py b/Hlt/RecoConf/python/RecoConf/standalone.py index e34a0f03ef8..a8c29ee6124 100644 --- a/Hlt/RecoConf/python/RecoConf/standalone.py +++ b/Hlt/RecoConf/python/RecoConf/standalone.py @@ -66,7 +66,7 @@ from .mass_monitors import make_mass_monitors from GaudiKernel.SystemOfUnits import MeV, mm from Moore.config import Reconstruction -from .data_from_file import boole_links_digits_mcparticles, mc_unpackers +from .data_from_file import boole_links_digits_mcparticles, mc_unpacker from .rich_add_reconstruction_monitoring_checking import add_hlt2_rich from PyConf.Algorithms import ( LHCb__Phoenix__DumpPlanarCaloCellsToJson, LHCb__Phoenix__DumpVPHitEvent, @@ -403,7 +403,7 @@ def monitor_detector_correlations(calo_objects): MonitorECALEnergyRawEventSizeCorrelations( name="MonitorECALEnergyRawEventSizeCorrelations", ECALDigits=calo_objects["digitsEcal"], - RawEvent=default_raw_event(["ALL"])) + RawEvent=default_raw_event("ALL")) ] return data @@ -489,7 +489,7 @@ def standalone_hlt2_reco(do_mc_checking=False, do_data_monitoring=False): # "VP" also has the other banks. The proper fix would be to # have the RawBankSizeMonitor accept multiple RawEvents (or # even RawBank::View's) - RawBankSizeMonitor(RawEventLocation=default_raw_event(["VP"])) + RawBankSizeMonitor(RawEventLocation=default_raw_event("VP")) ] data += [monitor_muon_PID(muon_pids)] @@ -963,8 +963,8 @@ def standalone_hlt2_calo_resolution_gamma(light_reco=False): tableMCCaloDigits = CaloFutureDigit2MCLinks2Table( CaloDigits=calo['digitsEcal'], - MCParticles=mc_unpackers()["MCParticles"], - Link=boole_links_digits_mcparticles()["EcalDigitsV1"], + MCParticles=mc_unpacker("MCParticles"), + Link=boole_links_digits_mcparticles("EcalDigitsV1"), ).Output # produce one table with relations (CellID,MCparticle) which can be used for all clusters @@ -972,8 +972,8 @@ def standalone_hlt2_calo_resolution_gamma(light_reco=False): # eventually could switch to using clusters after shower overlap at this stage tableMCCaloClusters = CaloClusterMCTruth( InputRelations=tableMCCaloDigits, - Input=boole_links_digits_mcparticles()["EcalDigits"], - MCParticleLocation=mc_unpackers()["MCParticles"], + Input=boole_links_digits_mcparticles("EcalDigits"), + MCParticleLocation=mc_unpacker("MCParticles"), Clusters=calo["clusters"]["ecalClustersNoOverlap"]).Output data = [] @@ -1006,8 +1006,8 @@ def standalone_hlt2_calo_cluster_shapes(light_reco=False): # produce Digit-MCParticle relations that can be used for all clusters tableMCCaloDigits = CaloFutureDigit2MCLinks2Table( CaloDigits=calo['digitsEcal'], - MCParticles=mc_unpackers()["MCParticles"], - Link=boole_links_digits_mcparticles()["EcalDigitsV1"], + MCParticles=mc_unpacker("MCParticles"), + Link=boole_links_digits_mcparticles("EcalDigitsV1"), ).Output data = [] @@ -1017,8 +1017,8 @@ def standalone_hlt2_calo_cluster_shapes(light_reco=False): for shape, clusters in calo["clusters"].items(): tableMCCaloClusters[shape] = CaloClusterMCTruth( InputRelations=tableMCCaloDigits, - Input=boole_links_digits_mcparticles()["EcalDigits"], - MCParticleLocation=mc_unpackers()["MCParticles"], + Input=boole_links_digits_mcparticles("EcalDigits"), + MCParticleLocation=mc_unpacker("MCParticles"), Clusters=clusters["ecalClustersOverlapWithCovar"]).Output # clusters resolution @@ -1040,16 +1040,16 @@ def standalone_hlt2_calo_resolution_pi0(): calo = make_calo_resolution_pi0(pvs) tableMCCaloDigits = CaloFutureDigit2MCLinks2Table( CaloDigits=calo['digitsEcal'], - MCParticles=mc_unpackers()["MCParticles"], - Link=boole_links_digits_mcparticles()["EcalDigitsV1"], + MCParticles=mc_unpacker("MCParticles"), + Link=boole_links_digits_mcparticles("EcalDigitsV1"), ).Output # produce one table with relations (CellID,MCparticle) which can be used for all clusters # NB use clusters BEFORE overlap as now these are "future" clusters # eventually could switch to using clusters after shower overlap at this stage tableMCCaloClusters = CaloClusterMCTruth( InputRelations=tableMCCaloDigits, - Input=boole_links_digits_mcparticles()["EcalDigits"], - MCParticleLocation=mc_unpackers()["MCParticles"], + Input=boole_links_digits_mcparticles("EcalDigits"), + MCParticleLocation=mc_unpacker("MCParticles"), Clusters=calo["clusters"]["ecalClustersNoOverlap"]).Output data = [] diff --git a/Hlt/RecoConf/python/RecoConf/velo_cluster_data_monitoring.py b/Hlt/RecoConf/python/RecoConf/velo_cluster_data_monitoring.py index 579f4716ee1..e35756fed58 100644 --- a/Hlt/RecoConf/python/RecoConf/velo_cluster_data_monitoring.py +++ b/Hlt/RecoConf/python/RecoConf/velo_cluster_data_monitoring.py @@ -11,7 +11,7 @@ from PyConf.application import default_raw_banks from PyConf.Algorithms import VPClusterEfficiency from PyConf.reading import get_mc_track_info -from .data_from_file import boole_links_digits_mchits, mc_unpackers +from .data_from_file import boole_links_digits_mchits, mc_unpacker from .legacy_rec_hlt1_tracking import make_velo_full_clusters @@ -19,7 +19,7 @@ def monitor_velo_clusters(make_raw=default_raw_banks): return VPClusterEfficiency( RawBanks=make_raw("VP"), VPClusterLocation=make_velo_full_clusters(), - MCHitLocation=mc_unpackers()["MCVPHits"], - MCParticleLocation=mc_unpackers()["MCParticles"], - VPDigit2MCHitLinksLocation=boole_links_digits_mchits()["VPDigits"], + MCHitLocation=mc_unpacker("MCVPHits"), + MCParticleLocation=mc_unpacker("MCParticles"), + VPDigit2MCHitLinksLocation=boole_links_digits_mchits("VPDigits"), MCProperty=get_mc_track_info()) diff --git a/Hlt/RecoConf/tests/refs/VP_tracking_monitors.ref.detdesc b/Hlt/RecoConf/tests/refs/VP_tracking_monitors.ref.detdesc index 4b1468499ac..2177682dd9a 100644 --- a/Hlt/RecoConf/tests/refs/VP_tracking_monitors.ref.detdesc +++ b/Hlt/RecoConf/tests/refs/VP_tracking_monitors.ref.detdesc @@ -7,6 +7,9 @@ ApplicationMgr INFO Application Manager Terminated succe HLTControlFlowMgr INFO Number of counters : 1 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | | "Processed events" | 500 | +MDFIOAlg INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "#banks in raw event" | 500 | 309500 | 619.00 | 0.0000 | 619.00 | 619.00 | TrackBestTrackCreator_5b9491d1 INFO Number of counters : 3 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | |*"BadInput" | 34139 | 0 |( 0.000000 +- 0.000000)% | diff --git a/Hlt/RecoConf/tests/refs/hlt1_reco_velo_only.ref.detdesc b/Hlt/RecoConf/tests/refs/hlt1_reco_velo_only.ref.detdesc index c62d8446647..091d9a77a52 100644 --- a/Hlt/RecoConf/tests/refs/hlt1_reco_velo_only.ref.detdesc +++ b/Hlt/RecoConf/tests/refs/hlt1_reco_velo_only.ref.detdesc @@ -7,7 +7,7 @@ DefaultGECFilter INFO Number of counters : 2 HLTControlFlowMgr INFO Number of counters : 1 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | | "Processed events" | 1000 | -LHCb__MDF__IOAlg_b77750eb INFO Number of counters : 1 +MDFIOAlg INFO Number of counters : 1 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | | "#banks in raw event" | 1000 | 1025000 | 1025.0 | 0.0000 | 1025.0 | 1025.0 | VeloClusterTrackingSIMD_87c18651 INFO Number of counters : 2 diff --git a/Hlt/RecoConf/tests/refs/hlt2_reco_data_2023.ref b/Hlt/RecoConf/tests/refs/hlt2_reco_data_2023.ref index 05aa61a000e..6d12388f002 100644 --- a/Hlt/RecoConf/tests/refs/hlt2_reco_data_2023.ref +++ b/Hlt/RecoConf/tests/refs/hlt2_reco_data_2023.ref @@ -134,6 +134,9 @@ LHCb__Converters__Track__SOA__fr... INFO Number of counters : 2 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | | "Nb of Events without Tracks" | 23 | 0 | 0.0000 | | "Nb of Produced Tracks" | 477 | 22830 | 47.862 | +MDFIOAlg INFO Number of counters : 1 + | Counter | # | sum | mean/eff^* | rms/err^* | min | max | + | "#banks in raw event" | 500 | 314537 | 629.07 | 0.26177 | 629.00 | 630.00 | MuonIDHlt2AlgLong_97306397 INFO Number of counters : 7 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | | "BgLL" | 779 | -507.6915 | -0.65172 | 1.1329 | -7.7469 | 0.0000 | diff --git a/Hlt/RecoConf/tests/refs/hlt2_ttracks_mva_filter.ref b/Hlt/RecoConf/tests/refs/hlt2_ttracks_mva_filter.ref index b4604cf4aa7..9541b384073 100644 --- a/Hlt/RecoConf/tests/refs/hlt2_ttracks_mva_filter.ref +++ b/Hlt/RecoConf/tests/refs/hlt2_ttracks_mva_filter.ref @@ -1,3 +1,6 @@ +ApplicationMgr INFO Application Manager Started successfully +HLTControlFlowMgr INFO Will measure time between events 0 and 4 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events DeMagnetConditionCall INFO Loading mag field from DBASE/FieldMap/vXrYpZ/cdf MagneticFieldExtension INFO Scale factor: 1.000000 FTRawBankDecoder INFO Conditions DB is compatible with FT bank version 7 and 8. diff --git a/Hlt/RecoConf/tests/refs/hlt2_ttracks_mva_filter.ref.detdesc b/Hlt/RecoConf/tests/refs/hlt2_ttracks_mva_filter.ref.detdesc index 7c191ceaf66..b42286f53bf 100644 --- a/Hlt/RecoConf/tests/refs/hlt2_ttracks_mva_filter.ref.detdesc +++ b/Hlt/RecoConf/tests/refs/hlt2_ttracks_mva_filter.ref.detdesc @@ -1,3 +1,6 @@ +ApplicationMgr INFO Application Manager Started successfully +HLTControlFlowMgr INFO Will measure time between events 0 and 4 (stop might be some events later) +HLTControlFlowMgr INFO Starting loop on events FTRawBankDecoder INFO Conditions DB is compatible with FT bank version 7 and 8. CloneKillerMatch_2ee65964 INFO Number of counters : 2 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | diff --git a/Hlt/RecoConf/tests/refs/legacy_rec_hlt1_reco_velo_only.ref b/Hlt/RecoConf/tests/refs/legacy_rec_hlt1_reco_velo_only.ref index 2770ab752f9..ad375b4289c 100644 --- a/Hlt/RecoConf/tests/refs/legacy_rec_hlt1_reco_velo_only.ref +++ b/Hlt/RecoConf/tests/refs/legacy_rec_hlt1_reco_velo_only.ref @@ -7,7 +7,7 @@ DefaultGECFilter INFO Number of counters : 2 HLTControlFlowMgr INFO Number of counters : 1 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | | "Processed events" | 1000 | -LHCb__MDF__IOAlg_b77750eb INFO Number of counters : 1 +MDFIOAlg INFO Number of counters : 1 | Counter | # | sum | mean/eff^* | rms/err^* | min | max | | "#banks in raw event" | 1000 | 1025000 | 1025.0 | 0.0000 | 1025.0 | 1025.0 | VeloClusterTrackingSIMD_87c18651 INFO Number of counters : 2 diff --git a/doc/recoconf/recoconf.rst b/doc/recoconf/recoconf.rst index 5b18414766a..481ba91c45e 100644 --- a/doc/recoconf/recoconf.rst +++ b/doc/recoconf/recoconf.rst @@ -45,10 +45,7 @@ As an example the SciFi decoding is shown:: @configurable def make_ft_hits(make_raw_event = default_raw_event): - ft_clusters = FTRawBankDecoder(RawEventLocations=make_raw(["FTCluster"])).OutputLocation - return PrStoreSciFiHits( - HitsLocation=ft_clusters(), - LayerMasks=tuple(my_disabled_layers)).Output + ft_clusters = FTRawBankDecoder(RawEventLocations=make_raw("FTCluster")).OutputLocation The function ``default_raw_event`` takes care of providing the raw event given the input file type and by making it a default argument, the configuration is simplified. If in this example, the clusters would be needed by a different algorithm, consider putting their creation in a dedicated function. diff --git a/doc/tutorials/different_samples.rst b/doc/tutorials/different_samples.rst index 448243100c3..a8ef97ec2a8 100644 --- a/doc/tutorials/different_samples.rst +++ b/doc/tutorials/different_samples.rst @@ -50,7 +50,7 @@ It is mostly similar to the `DIGI` case, but here ``input_type`` must be set to IO optimizations for MDF ------------------------ -For ``MDF`` inputs, IO may be optimized by setting ``options.use_iosvc = True`` and ``options.event_store = 'EvtStoreSvc'``. +IO may be optimized by setting ``options.event_store = 'EvtStoreSvc'``. However, this requires that the input files are already in memory or at least on the local disk. It won't work on mounted storage such as EOS. One possibility is to use the `xrdcp` function, as explained in the `Downloading a file from the grid `_ Starterkit lesson. @@ -61,13 +61,12 @@ After downloading them with `xrdcp`, you may enable the optimizations:: options.set_input_and_conds_from_testfiledb('MiniBrunel_2018_MinBias_FTv4_MDF') options.input_files=[paths_to_downloaded_files] - options.use_iosvc = True options.event_store = 'EvtStoreSvc' .. note:: - If `LHCb__MDF__IOSvcMM` errors arise, try reverting to the default options: ``options.use_iosvc = False`` and ``options.event_store = '"HiveWhiteBoard"'``. + If `LHCb__MDF__IOSvcMM` errors arise, try reverting to the default option : ``options.event_store = '"HiveWhiteBoard"'``. Running on (L)DST diff --git a/doc/tutorials/running.rst b/doc/tutorials/running.rst index 02d917ad047..73c9fcb0656 100644 --- a/doc/tutorials/running.rst +++ b/doc/tutorials/running.rst @@ -90,7 +90,6 @@ by printing it:: >>> print(options) /***** User ApplicationOptions/ApplicationOptions ************************************************** - |-use_iosvc = False (default: False) |-histo_file = '' (default: '') |-data_type = 'Upgrade' (default: 'Upgrade') |-input_type = '' (default: '') -- GitLab From 8ce47a0156e6cd04eb1e383380bde05173787173 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Tue, 13 Feb 2024 15:57:35 +0100 Subject: [PATCH 05/11] Do not check /Event/DAQ in hlt2_lumi_events_check test --- Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py b/Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py index 0ef0db3dc00..be1e0381944 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_lumi_events_check.py @@ -133,10 +133,6 @@ for TES in events(): # TODO also check the bank versions - test_equals( - raw_event.banks(LHCb.RawBank.DAQ).size(), 1, - "Every raw event must have exactly one DAQ (MDF header) bank") - test_equals( raw_event.banks(LHCb.RawBank.ODIN).size(), 1, "Every raw event must have exactly one ODIN bank") -- GitLab From c9a73e6f12c865e31293a5c5e3994a63fe15b433 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Tue, 13 Feb 2024 17:30:41 +0100 Subject: [PATCH 06/11] Prefer using -1 as evt_max rather than explicit number of events in the input file --- Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml | 1 - Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py | 1 - Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py | 1 - Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py | 1 - Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py | 1 - Hlt/Hlt2Conf/options/hlt2_check_output.py | 4 ---- .../options/hlt2_pp_commissioning_production_options.yaml | 1 - Hlt/Hlt2Conf/options/hlt2_production_options.yaml | 1 - .../options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml | 1 - .../options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml | 1 - .../spruce_all_lines_realtime_test_old_json.yaml | 1 - .../sprucing/lbexec_yamls/spruce_example_realtime.yaml | 1 - .../lbexec_yamls/spruce_example_realtime_dstinput.yaml | 1 - .../lbexec_yamls/spruce_example_realtime_extraoutputs.yaml | 1 - .../lbexec_yamls/spruce_example_realtime_persistreco.yaml | 1 - .../options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml | 1 - .../options/sprucing/lbexec_yamls/spruce_passthrough.yaml | 1 - .../sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml | 1 - .../sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml | 1 - Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py | 1 - .../options/sprucing/spruce_example_realtime_dstinput.py | 1 - .../options/sprucing/spruce_example_realtime_extraoutputs.py | 1 - .../options/sprucing/spruce_example_realtime_persistreco.py | 1 - Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py | 1 - Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py | 1 - Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py | 1 - Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py | 1 - Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml | 1 - Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py | 1 - Hlt/Hlt2Conf/tests/options/streaming/stream_check.py | 5 +---- .../qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt | 1 - .../qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt | 1 - ...sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt | 1 - .../qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt | 1 - .../qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt | 1 - .../tests/qmtest/test_hlt2_check_output_with_reco.qmt | 1 - ...st_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt | 1 - Hlt/Moore/tests/options/input_add_retina_clusters.py | 2 -- 38 files changed, 1 insertion(+), 45 deletions(-) diff --git a/Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml b/Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml index 04da2b57610..74846cb78e2 100644 --- a/Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml +++ b/Hlt/Hlt1Conf/options/allen_hlt1_production_options.yaml @@ -8,7 +8,6 @@ input_files: - LFN:/lhcb/MC/Upgrade/XDIGI/00172009/0000/00172009_00003403_1_evt_20_39.xdigi input_type: "ROOT" input_raw_format: 0.5 -evt_max: 30 xml_summary_file: "hlt1_summary.xml" xml_file_catalog: "hlt1_pool_xml_catalog.xml" diff --git a/Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py b/Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py index e540f306404..08816ec2330 100644 --- a/Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py +++ b/Hlt/Hlt1Conf/tests/options/allen_hlt1_mdf_input.py @@ -15,4 +15,3 @@ options.input_files = ['test_allen_hlt1_persistence_mdf_write.mdf'] options.input_type = 'MDF' options.mdf_ioalg_name = 'IOAlgMemoryMap' options.set_conds_from_testfiledb('upgrade_Sept2022_BsPhiPhi_0fb_md_xdigi') -options.evt_max = 190 diff --git a/Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py b/Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py index 223b2f0fbac..3c4440be6e8 100644 --- a/Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py +++ b/Hlt/Hlt1Conf/tests/options/hlt1_dst_input.py @@ -13,4 +13,3 @@ from Moore import options options.input_files = ['test_hlt1_persistence_dst_write.dst'] options.input_type = 'ROOT' -options.evt_max = 39 diff --git a/Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py b/Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py index f715c58d982..77609da293f 100644 --- a/Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py +++ b/Hlt/Hlt1Conf/tests/options/hlt1_filtered_mdf_input.py @@ -14,5 +14,4 @@ options.dddb_tag = "dddb-20180815" options.conddb_tag = "sim-20180530-vc-md100" options.input_files = ['test_allen_hlt1_persistence_mdf_write.mdf'] options.input_type = "MDF" -options.evt_max = 195 options.simulation = True diff --git a/Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py b/Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py index a0c0fe86cc6..93e09ad6d89 100644 --- a/Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py +++ b/Hlt/Hlt1Conf/tests/options/hlt1_mdf_input.py @@ -13,4 +13,3 @@ from Moore import options options.input_files = ['test_hlt1_persistence_mdf_write.mdf'] options.input_type = 'MDF' -options.evt_max = 39 diff --git a/Hlt/Hlt2Conf/options/hlt2_check_output.py b/Hlt/Hlt2Conf/options/hlt2_check_output.py index 034b1e636ef..eadb64a3653 100644 --- a/Hlt/Hlt2Conf/options/hlt2_check_output.py +++ b/Hlt/Hlt2Conf/options/hlt2_check_output.py @@ -48,7 +48,6 @@ options.conddb_tag = "sim-20171127-vc-md100" options.input_files = [input_file] options.input_type = "ROOT" if input_file.find(".dst") != -1 else "MDF" options.gaudipython_mode = True -options.evt_max = int(sys.argv[2]) config = configure_input(options) algs = do_unpacking( @@ -90,7 +89,6 @@ cppyy.gbl.DataSvcHelpers.RegistryEntry.__bool__ = lambda x: True # The test can't check anything if no event fired found_events = False found_child_relations = False -n = 1 while TES['/Event']: print('Checking next event.') @@ -112,8 +110,6 @@ while TES['/Event']: error("empty Particles container in " + prefix + "/Particles") found_events = True - n += 1 - if n == options.evt_max: break # avoid EndOfinput warning appMgr.run(1) if not found_events: diff --git a/Hlt/Hlt2Conf/options/hlt2_pp_commissioning_production_options.yaml b/Hlt/Hlt2Conf/options/hlt2_pp_commissioning_production_options.yaml index c7311be1d4f..52b744de78e 100644 --- a/Hlt/Hlt2Conf/options/hlt2_pp_commissioning_production_options.yaml +++ b/Hlt/Hlt2Conf/options/hlt2_pp_commissioning_production_options.yaml @@ -8,7 +8,6 @@ input_files: input_type: "ROOT" root_ioalg_name: 'RootIOAlgExt' input_raw_format: 0.5 -evt_max: 9 xml_summary_file: hlt2_pp_commissioning_summary.xml xml_file_catalog: hlt1_pool_xml_catalog.xml diff --git a/Hlt/Hlt2Conf/options/hlt2_production_options.yaml b/Hlt/Hlt2Conf/options/hlt2_production_options.yaml index c96c57fe6fa..ba6b8ff383b 100644 --- a/Hlt/Hlt2Conf/options/hlt2_production_options.yaml +++ b/Hlt/Hlt2Conf/options/hlt2_production_options.yaml @@ -9,7 +9,6 @@ input_files: input_type: "ROOT" root_ioalg_name: "RootIOAlgExt" input_raw_format: 0.5 -evt_max: 30 xml_summary_file: "hlt2_summary.xml" xml_file_catalog: "hlt2_pool_xml_catalog.xml" diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml index df8d32e62bc..14beb31cfb3 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/excl_spruce_2022_data.yaml @@ -7,7 +7,6 @@ input_files : [ 'mdf:root://eoslhcb.cern.ch//eos/lhcb/wg/dpa/wp1/data/2022_1_FULL_255620_00150001_0005.raw' ] -evt_max : 12795 simulation : False geometry_version: run3/trunk diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml index 1213c2bd389..18c28a4ffa3 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/pass_spruce_2022_data.yaml @@ -5,7 +5,6 @@ input_type : 'RAW' input_files : [ 'mdf:root://eoslhcb.cern.ch//eos/lhcb/wg/dpa/wp1/data/2022_1_TURBO_255620_00150000_0003.raw' ] -evt_max : 53606 simulation : False geometry_version: run3/trunk diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_all_lines_realtime_test_old_json.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_all_lines_realtime_test_old_json.yaml index ccc3d9b7586..bdf595607c9 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_all_lines_realtime_test_old_json.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_all_lines_realtime_test_old_json.yaml @@ -7,7 +7,6 @@ input_files : [ ] input_manifest_file : 'root://eoslhcb.cern.ch//eos/lhcb/wg/rta/samples/mc/Hlt1Hlt2filtered_MinBias_sprucing/hlt2_2or3bodytopo_realtime_newPacking.tck.json' -evt_max : 475 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime.yaml index ecc3794a30e..3e7765b61d3 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime.yaml @@ -4,7 +4,6 @@ input_files : ['hlt2_2or3bodytopo_realtime.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime.tck.json" input_type : 'RAW' -evt_max : 30 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_dstinput.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_dstinput.yaml index 83d37122fb7..33d6b2e9c81 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_dstinput.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_dstinput.yaml @@ -5,7 +5,6 @@ input_manifest_file : "hlt2_2or3bodytopo_realtime_dst.tck.json" input_type : 'ROOT' root_ioalg_name: 'RootIOAlgExt' -evt_max : 31 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_extraoutputs.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_extraoutputs.yaml index bd00fc6ebe4..87fc10d5af5 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_extraoutputs.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_extraoutputs.yaml @@ -4,7 +4,6 @@ input_files : ['hlt2_2or3bodytopo_realtime_with_extras.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime_with_extras.tck.json" input_type : 'RAW' -evt_max : 11 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_persistreco.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_persistreco.yaml index e86e33fc655..66e1b150ad5 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_persistreco.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_example_realtime_persistreco.yaml @@ -4,7 +4,6 @@ input_files : ['hlt2_2or3bodytopo_realtime.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime.tck.json" input_type : 'RAW' -evt_max : 11 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml index 9f5b716d322..2b410fe841a 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_hlt2filter.yaml @@ -4,7 +4,6 @@ input_files : ['hlt2_2or3bodytopo_realtime.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime.tck.json" input_type : 'RAW' -evt_max : 30 simulation : True dddb_tag : 'dddb-20180815' conddb_tag : 'sim-20180530-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough.yaml index a1e2d877e36..ad4ed02d98a 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough.yaml @@ -4,7 +4,6 @@ input_files : ['hlt2_test_persistreco_fromfile.test_stream_B.mdf'] input_type : 'RAW' input_manifest_file : 'hlt2_test_streaming.tck.json' -evt_max : 1000 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml index 392296d3394..4d9ae162329 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/spruce_passthrough_dstinput.yaml @@ -5,7 +5,6 @@ input_type : 'ROOT' root_ioalg_name : 'RootIOAlgExt' input_manifest_file : 'hlt2_2or3bodytopo_realtime_dst.tck.json' -evt_max : 31 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml index bd8a1fb1255..abe9568bb0e 100644 --- a/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml +++ b/Hlt/Hlt2Conf/options/sprucing/lbexec_yamls/turcal_spruce_2022_data.yaml @@ -10,7 +10,6 @@ input_files : [ simulation : False geometry_version: run3/trunk conditions_version: master -evt_max: 116674 output_file : 'pass_turcal_lines_production.{stream}.dst' output_type : 'ROOT' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py index 282d4bd268f..2cbac7422e2 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime.py @@ -23,7 +23,6 @@ options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_dstinput.py b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_dstinput.py index bb380c5fc88..33ce9e59370 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_dstinput.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_dstinput.py @@ -29,7 +29,6 @@ options.input_manifest_file = "hlt2_2or3bodytopo_realtime_dst.tck.json" options.input_type = 'ROOT' options.root_ioalg_name = 'RootIOAlgExt' -options.evt_max = 31 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_extraoutputs.py b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_extraoutputs.py index c266682d12f..04027129416 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_extraoutputs.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_extraoutputs.py @@ -23,7 +23,6 @@ options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_persistreco.py b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_persistreco.py index e51a0365839..bcc82d8e8df 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_persistreco.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_example_realtime_persistreco.py @@ -23,7 +23,6 @@ options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py b/Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py index 9768cdffd09..a969b3af1e2 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_hlt2filter.py @@ -30,7 +30,6 @@ options.input_files = input_files options.input_manifest_file = "hlt2_2or3bodytopo_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20180815' options.conddb_tag = 'sim-20180530-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py index 76af8faa4bc..9842d2c80b0 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py @@ -27,7 +27,6 @@ options.input_files = input_files options.input_type = 'MDF' options.input_manifest_file = 'hlt2_2or3bodytopo_realtime.tck.json' -options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py index 1adeb56d6a2..5e2ff11e2c6 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough_dstinput.py @@ -30,7 +30,6 @@ options.input_type = 'ROOT' options.root_ioalg_name = 'RootIOAlgExt' options.input_manifest_file = 'hlt2_2or3bodytopo_realtime_dst.tck.json' -options.evt_max = 31 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py b/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py index bb8b2bae1f5..602284e3112 100644 --- a/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py +++ b/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.py @@ -29,7 +29,6 @@ options.input_type = 'MDF' # When running from Upgrade MC, must use the post-juggling locations of the raw # event -options.evt_max = 30 options.simulation = True options.dddb_tag = 'dddb-20171126' options.conddb_tag = 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml b/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml index cc99c86fdf1..41138b4d852 100644 --- a/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml +++ b/Hlt/Hlt2Conf/options/streaming/spruce_test_streaming.yaml @@ -4,7 +4,6 @@ input_files : ['hlt2_2or3bodytopo_realtime.mdf'] input_manifest_file : "hlt2_2or3bodytopo_realtime.tck.json" input_type : 'RAW' -evt_max : 11 simulation : True dddb_tag : 'dddb-20171126' conddb_tag : 'sim-20171127-vc-md100' diff --git a/Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py b/Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py index d67a5846854..6e4e231306b 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py +++ b/Hlt/Hlt2Conf/tests/options/hlt_filters_test_sprucepass.py @@ -34,7 +34,6 @@ options.input_files = input_files options.input_manifest_file = "hlt_filterstest_realtime.tck.json" options.input_type = 'MDF' -options.evt_max = 96 options.simulation = True options.data_type = 'Upgrade' options.dddb_tag = 'dddb-20171126' diff --git a/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py b/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py index 871582703ae..48d28e7f365 100644 --- a/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py +++ b/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py @@ -47,7 +47,6 @@ parser.add_argument('input', help='Input filename') parser.add_argument('manifest', help='JSON manifest dump') parser.add_argument('input_process', help='Hlt2 or Spruce') parser.add_argument('stream', help='Stream to test as defined in options') -parser.add_argument('nevents', type=int, help='Number of events to process') args = parser.parse_args() @@ -95,8 +94,7 @@ import cppyy cppyy.gbl.DataSvcHelpers.RegistryEntry.__bool__ = lambda x: True first_event = True -n = 0 -while n < args.nevents: +while True: appMgr.run(1) if not TES['/Event']: break @@ -228,4 +226,3 @@ while n < args.nevents: or (rec_summary.info(rec_summary.nFTClusters, -1) < 1): error("Wrong values in RecSummary for this stream") print(rec_summary) - n += 1 diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt index 28739901dde..604d2b5d23c 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_A.qmt @@ -24,7 +24,6 @@ Test HLT2 streaming. Runs over hlt2_test_persistreco_fromfile.test_stream_A.mdf hlt2_test_streaming.tck.json Hlt2 test_stream_A - 1000 true diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt index 8b039c080e8..2c872d9b57d 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_hlt2_streaming_check_B.qmt @@ -24,7 +24,6 @@ Test HLT2 streaming. Runs over hlt2_test_persistreco_fromfile.test_stream_B.mdf hlt2_test_streaming.tck.json Hlt2 test_stream_B - 1000 true diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt index e858549fe69..88de6de35bd 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_hlt2_check_output_with_reco_with_streams_mdf.qmt @@ -21,7 +21,6 @@ Check that the output of the file contains the candidates corresponding to the d $HLT2CONFROOT/options/hlt2_check_output.py sprucing_hlt2_all_lines_with_reco_with_streams_mdf.mdf - 0 from Configurables import HiveDataBrokerSvc diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt index de111f4c8aa..731d4839614 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_A.qmt @@ -25,7 +25,6 @@ Runs over hlt2_test_persistreco_fromfile.test_stream_A.mdf from hlt2_test_stream spruce_streaming.tck.json Spruce test_stream_A - 5 true diff --git a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt index 42a62830a5a..1ad9996ff89 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/streaming.qms/test_sprucing_streaming_check_B.qmt @@ -25,7 +25,6 @@ Runs over hlt2_test_persistreco_fromfile.test_stream_B.mdf from hlt2_test_stream spruce_streaming.tck.json Spruce test_stream_B - 5 true diff --git a/Hlt/Hlt2Conf/tests/qmtest/test_hlt2_check_output_with_reco.qmt b/Hlt/Hlt2Conf/tests/qmtest/test_hlt2_check_output_with_reco.qmt index 2c85b8d32e4..f4dfd16ee0f 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/test_hlt2_check_output_with_reco.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/test_hlt2_check_output_with_reco.qmt @@ -21,7 +21,6 @@ Make sure HLT2 configures and runs all lines without errors on reconstructed dat $HLT2CONFROOT/options/hlt2_check_output.py hlt2_all_lines_with_reco.dst - 11 from Configurables import HiveDataBrokerSvc diff --git a/Hlt/Hlt2Conf/tests/qmtest/test_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt b/Hlt/Hlt2Conf/tests/qmtest/test_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt index d18d08c6d76..b8707af6593 100644 --- a/Hlt/Hlt2Conf/tests/qmtest/test_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt +++ b/Hlt/Hlt2Conf/tests/qmtest/test_turbo_hlt2_check_output_with_reco_with_streams_mdf.qmt @@ -21,7 +21,6 @@ Check that the output of the file contains the candidates corresponding to the d $HLT2CONFROOT/options/hlt2_check_output.py turbo_hlt2_all_lines_with_reco_with_streams_mdf.mdf - 16 from Configurables import HiveDataBrokerSvc diff --git a/Hlt/Moore/tests/options/input_add_retina_clusters.py b/Hlt/Moore/tests/options/input_add_retina_clusters.py index 8b4ecdcaa0c..9f75b0cf3be 100755 --- a/Hlt/Moore/tests/options/input_add_retina_clusters.py +++ b/Hlt/Moore/tests/options/input_add_retina_clusters.py @@ -14,11 +14,9 @@ options.input_files = [ 'root://eoslhcb.cern.ch//eos/lhcb/wg/IonPhysics/Simulations/SMOG2jpsi/digi/SMOG2jpsi_0-Extended.digi' ] options.input_type = "ROOT" -options.evt_max = 500 options.dddb_tag = 'dddb-20190223' options.conddb_tag = 'sim-20180530-vc-mu100' options.simulation = True -options.ioalg_buffer_nb_events = 2 options.output_file = 'test.digi' options.output_type = 'ROOT' -- GitLab From ba0caa10bd0939a54c3ebead5f1433eb67fe66fb Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Tue, 13 Feb 2024 19:20:38 +0100 Subject: [PATCH 07/11] Simplified hlt2_persistreco_check_flavourtags test by not counting events and letting EndOfInput come --- .../tests/options/hlt2_persistreco_check_flavourtags.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py index cc6336bb263..85704d816a9 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py @@ -60,7 +60,6 @@ locations = [ ] + [f'/Event/HLT2/Hlt2B2JpsiKModified/{ft}' for ft in flavour_tags ] + [f'/Event/HLT2/Hlt2B2JpsiK/{ft}' for ft in flavour_tags] -n = 0 while TES['/Event/HLT2']: dec_rep = TES['/Event/Hlt2/DecReports'] if not dec_rep: print("could not obtain Hlt2 decisions") @@ -126,6 +125,4 @@ while TES['/Event/HLT2']: print("N tag particles", t.taggerParts().size()) else: print("ERROR: no FlavourTags in Hlt2B2JpsiKModified") - n = n + 1 - if n == 28: break # Avoid EndOfInput warning appMgr.run(1) -- GitLab From c5bfd9dfc8a43971b70d6b1c760a16724f7f7732 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Thu, 15 Feb 2024 13:31:09 +0100 Subject: [PATCH 08/11] Made handling of stream compatible with DaVinci. Sadly this means using bind instead of regular passing of function arguments... --- Hlt/Hlt2Conf/options/hlt2_check_output.py | 4 +--- Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py | 4 +--- .../tests/options/hlt2_persistreco_check_flavourtags.py | 2 +- Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py | 6 +++--- .../tests/options/sprucing/spruce_check_2022_data.py | 3 ++- Hlt/Hlt2Conf/tests/options/streaming/stream_check.py | 3 ++- 6 files changed, 10 insertions(+), 12 deletions(-) diff --git a/Hlt/Hlt2Conf/options/hlt2_check_output.py b/Hlt/Hlt2Conf/options/hlt2_check_output.py index eadb64a3653..a10f2956c8a 100644 --- a/Hlt/Hlt2Conf/options/hlt2_check_output.py +++ b/Hlt/Hlt2Conf/options/hlt2_check_output.py @@ -51,9 +51,7 @@ options.gaudipython_mode = True config = configure_input(options) algs = do_unpacking( - input_process='Hlt2', - has_mc_data=(options.input_type == "ROOT"), - stream='') + input_process='Hlt2', has_mc_data=(options.input_type == "ROOT")) decdecoder = None for alg in algs: diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py index a3b10a7c15d..54cda1b769b 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py @@ -64,9 +64,7 @@ options.gaudipython_mode = True config = configure_input(options) algs = do_unpacking( - input_process='Hlt2', - has_mc_data=(options.input_type == "ROOT"), - stream='') + input_process='Hlt2', has_mc_data=(options.input_type == "ROOT")) cf_node = CompositeNode( 'persistereco', diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py index 85704d816a9..36f86e95d71 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py @@ -38,7 +38,7 @@ options.gaudipython_mode = True config = configure_input(options) -algs = do_unpacking(input_process='Hlt2', stream='') +algs = do_unpacking(input_process='Hlt2') cf_node = CompositeNode( 'checking', diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py index 297d8782985..eccdc93247a 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py @@ -67,10 +67,10 @@ options.input_type = 'ROOT' options.root_ioalg_name = 'RootIOAlgExt' options.evt_max = args.n if args.n else -1 options.gaudipython_mode = True +options.input_stream = args.s config = configure_input(options) input_process = args.p -stream = args.s if input_process == "Spruce": RECO_ROOT = "/Event/Spruce/HLT2" @@ -82,7 +82,7 @@ if input_process == "Turbo": algs = do_unpacking( input_process=input_process, - stream=stream, + stream=options.input_stream, has_mc_data=args.usemc, raw_event_format=0.3) @@ -92,7 +92,7 @@ cf_node = CompositeNode( children=algs, force_order=True) -config.update(configure(options, cf_node, stream=stream)) +config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py index 394c2ad1c4c..3109e86d25e 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py @@ -86,6 +86,7 @@ options.input_files = [args.input] options.input_manifest_file = args.manifest options.input_type = 'ROOT' options.gaudipython_mode = True +options.input_stream = args.stream config = configure_input(options) # settings for passthrough data. Only one fired line of first evt is checked in a test. @@ -103,7 +104,7 @@ cf_node = CompositeNode( children=algs, force_order=True) -config.update(configure(options, cf_node, stream=args.stream)) +config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) diff --git a/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py b/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py index 48d28e7f365..3efb5e7c65e 100644 --- a/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py +++ b/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py @@ -70,6 +70,7 @@ if args.input_process == "Hlt2": else: stream = args.stream raweventloc = f'/Event/{args.stream}/RawEvent' +options.input_stream = stream algs = do_unpacking( input_process=args.input_process, stream=stream, has_mc_data=False) @@ -80,7 +81,7 @@ cf_node = CompositeNode( children=algs, force_order=True) -config.update(configure(options, cf_node, stream=stream)) +config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) -- GitLab From 118fe94b75641d98d9340f3de8da7ec6ed03cb04 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Thu, 7 Mar 2024 14:27:11 +0100 Subject: [PATCH 09/11] fixed detection of output in lines --- Hlt/Moore/python/Moore/lines.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Hlt/Moore/python/Moore/lines.py b/Hlt/Moore/python/Moore/lines.py index 9de24c63e33..d6927492571 100644 --- a/Hlt/Moore/python/Moore/lines.py +++ b/Hlt/Moore/python/Moore/lines.py @@ -442,7 +442,7 @@ class Hlt2Line(DecisionLine): @property def produces_output(self): """Return True if this line produces output OR requests reconstruction OR requests extra_outputs.""" - return self.output_producer is not None or self.persistreco or self.tagging_particles or self.extra_outputs + return self.output_producer is not None or self.persistreco or self.tagging_particles or self.extra_outputs is not None @staticmethod def _output_node(decision_node, output_producer, extra_outputs, -- GitLab From ee2f523c22b686c584c1dd1a75ed94c9d30f3389 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Tue, 26 Mar 2024 08:15:03 +0100 Subject: [PATCH 10/11] few simplifications thanks to review comments --- Hlt/Hlt2Conf/options/hlt2_check_output.py | 17 ++--------------- .../options/sprucing/spruce_passthrough.py | 7 ++++--- .../options/streaming/hlt2_test_streaming.py | 7 ------- .../hlt2_passthrough_persistreco_check.py | 9 +-------- .../tests/options/hlt2_persistreco_check.py | 10 +--------- .../hlt2_persistreco_check_flavourtags.py | 9 +-------- .../tests/options/sprucing/spruce_check.py | 9 +-------- .../options/sprucing/spruce_check_2022_data.py | 9 +-------- .../sprucing/spruce_check_extraoutputs.py | 9 +-------- .../sprucing/spruce_check_persistreco.py | 9 +-------- .../tests/options/streaming/stream_check.py | 13 +++---------- Hlt/Moore/python/Moore/config.py | 2 +- Hlt/Moore/python/Moore/persistence/__init__.py | 7 +------ .../python/RecoConf/reco_objects_from_file.py | 5 +++++ 14 files changed, 23 insertions(+), 99 deletions(-) diff --git a/Hlt/Hlt2Conf/options/hlt2_check_output.py b/Hlt/Hlt2Conf/options/hlt2_check_output.py index a10f2956c8a..ca540c1b3f7 100644 --- a/Hlt/Hlt2Conf/options/hlt2_check_output.py +++ b/Hlt/Hlt2Conf/options/hlt2_check_output.py @@ -26,7 +26,6 @@ Takes command-line arguments: import sys import GaudiPython as GP -from PyConf.control_flow import CompositeNode, NodeLogic from PyConf.application import configure_input, configure from Moore import options from GaudiConf.reading import do_unpacking @@ -50,21 +49,9 @@ options.input_type = "ROOT" if input_file.find(".dst") != -1 else "MDF" options.gaudipython_mode = True config = configure_input(options) -algs = do_unpacking( +cf_node = do_unpacking( input_process='Hlt2', has_mc_data=(options.input_type == "ROOT")) -decdecoder = None -for alg in algs: - if "Hlt2DecReportsDecoder" == alg.name: - decdecoder = alg -assert decdecoder - -cf_node = CompositeNode( - 'checking', - combine_logic=NodeLogic.NONLAZY_OR, - children=algs, - force_order=True) - config.update(configure(options, cf_node)) stream = None @@ -91,7 +78,7 @@ while TES['/Event']: print('Checking next event.') #TES.dump() - decRep = TES[decdecoder.OutputHltDecReportsLocation.location].decReports() + decRep = TES["/Event/Hlt2/DecReports"].decReports() for name, report in decRep.items(): # for _these_ tests: Hlt2Topo is in 'Spruce' and the rest in 'Turbo' _if_ (and only if) we could recognize the stream diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py index 9842d2c80b0..3aaad84dc3f 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py @@ -39,9 +39,6 @@ options.output_manifest_file = "spruce_passthrough_gaudirun.tck.json" def pass_through_line(name="Passthrough"): """Return a Sprucing line that performs no selection """ - # As unpackers are expecting the I/O to be setup and nobody does it, - # we need to precreate RootIOAlg here - create_or_reuse_rootIOAlg(options) return PassLine(name=name) @@ -51,4 +48,8 @@ def make_lines(): public_tools = [stateProvider_with_simplified_geom()] +# As unpackers are expecting the I/O to be setup and nobody does it, +# we need to precreate RootIOAlg here +create_or_reuse_rootIOAlg(options) + config = run_moore(options, make_lines, public_tools) diff --git a/Hlt/Hlt2Conf/options/streaming/hlt2_test_streaming.py b/Hlt/Hlt2Conf/options/streaming/hlt2_test_streaming.py index 8f14c105148..33cc2492b18 100644 --- a/Hlt/Hlt2Conf/options/streaming/hlt2_test_streaming.py +++ b/Hlt/Hlt2Conf/options/streaming/hlt2_test_streaming.py @@ -18,7 +18,6 @@ from Moore import options, run_moore from RecoConf.global_tools import stateProvider_with_simplified_geom from Moore.lines import Hlt2Line, Hlt2LuminosityLine from Moore.streams import Stream, Streams -from PyConf.application import input_from_root_file, configure_input options.set_input_and_conds_from_testfiledb('upgrade_minbias_hlt1_filtered') options.input_raw_format = 4.3 @@ -27,12 +26,6 @@ options.output_file = 'hlt2_test_persistreco_fromfile.{stream}.mdf' options.output_type = 'MDF' options.output_manifest_file = "hlt2_test_streaming.tck.json" -# make sure RawEvent is read from input file, as the lines writers are not -# declaring what they write but take anything in the TES -config = configure_input(options) -input_from_root_file( - "/Event/DAQ/RawEvent", forced_type='LHCb::RawEvent', options=options), - from RecoConf.decoders import default_ft_decoding_version ft_decoding_version = 2 #4,6 default_ft_decoding_version.global_bind(value=ft_decoding_version) diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_passthrough_persistreco_check.py b/Hlt/Hlt2Conf/tests/options/hlt2_passthrough_persistreco_check.py index 926115be68e..630cf3bc533 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_passthrough_persistreco_check.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_passthrough_persistreco_check.py @@ -24,7 +24,6 @@ expect. import argparse import GaudiPython as GP -from PyConf.control_flow import CompositeNode, NodeLogic from Configurables import HistogramPersistencySvc from GaudiConf.reading import do_unpacking from PyConf.application import configure_input, configure @@ -48,17 +47,11 @@ options.input_type = "MDF" options.gaudipython_mode = True config = configure_input(options) -algs = do_unpacking(input_process='Hlt2', has_mc_data=False) +cf_node = do_unpacking(input_process='Hlt2', has_mc_data=False) # Disable warning about histogram saving not being required HistogramPersistencySvc(OutputLevel=5) -cf_node = CompositeNode( - 'checking', - combine_logic=NodeLogic.NONLAZY_OR, - children=algs, - force_order=True) - config.update(configure(options, cf_node)) appMgr = GP.AppMgr() diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py index 54cda1b769b..9caa9298d33 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check.py @@ -26,8 +26,6 @@ import sys import GaudiPython as GP from Configurables import HistogramPersistencySvc -from PyConf.control_flow import CompositeNode, NodeLogic - from PyConf.packing import default_persistable_locations from GaudiConf.reading import do_unpacking from Hlt2Conf.check_output import check_persistreco, check_particles @@ -63,15 +61,9 @@ options.input_type = "ROOT" if args.input.find(".dst") != -1 else "MDF" options.gaudipython_mode = True config = configure_input(options) -algs = do_unpacking( +cf_node = do_unpacking( input_process='Hlt2', has_mc_data=(options.input_type == "ROOT")) -cf_node = CompositeNode( - 'persistereco', - combine_logic=NodeLogic.NONLAZY_OR, - children=algs, - force_order=True) - config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required diff --git a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py index 36f86e95d71..54dcb3d0182 100644 --- a/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py +++ b/Hlt/Hlt2Conf/tests/options/hlt2_persistreco_check_flavourtags.py @@ -16,7 +16,6 @@ Runs over the output file passed as the last argument to this script. """ import GaudiPython as GP from GaudiConf.reading import do_unpacking -from PyConf.control_flow import CompositeNode, NodeLogic from PyConf.application import configure_input, configure from Moore import options @@ -38,13 +37,7 @@ options.gaudipython_mode = True config = configure_input(options) -algs = do_unpacking(input_process='Hlt2') - -cf_node = CompositeNode( - 'checking', - combine_logic=NodeLogic.NONLAZY_OR, - children=algs, - force_order=True) +cf_node = do_unpacking(input_process='Hlt2') config.update(configure(options, cf_node)) diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py index eccdc93247a..faf90888e2a 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check.py @@ -20,7 +20,6 @@ import argparse import GaudiPython as GP from Configurables import HistogramPersistencySvc -from PyConf.control_flow import CompositeNode, NodeLogic from PyConf.application import configure_input, configure from Moore import options @@ -80,18 +79,12 @@ if input_process == "Turbo": RECO_ROOT = "/Event/HLT2" dec_to_check = "Passthrough" -algs = do_unpacking( +cf_node = do_unpacking( input_process=input_process, stream=options.input_stream, has_mc_data=args.usemc, raw_event_format=0.3) -cf_node = CompositeNode( - 'checking', - combine_logic=NodeLogic.NONLAZY_OR, - children=algs, - force_order=True) - config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py index 3109e86d25e..371b2873525 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_2022_data.py @@ -22,7 +22,6 @@ from Hlt2Conf.lines.b_to_open_charm import sprucing_lines as spruce_b2oc_lines spruce_b2oc_lines.pop('SpruceB2OC_BdToDsmK_DsmToHHH_FEST') from Hlt2Conf.sprucing_settings.Sprucing_2022_1_production import fulllinedict, turbolinedict, turcallinedict from GaudiConf.reading import do_unpacking -from PyConf.control_flow import CompositeNode, NodeLogic from PyConf.application import configure_input, configure from Moore import options from Configurables import HistogramPersistencySvc @@ -92,18 +91,12 @@ config = configure_input(options) # settings for passthrough data. Only one fired line of first evt is checked in a test. process = "Spruce" if args.job_type == "excl" else "Turbo" -algs = do_unpacking( +cf_node = do_unpacking( input_process=process, stream=args.stream, has_mc_data=False, raw_event_format=0.3) -cf_node = CompositeNode( - 'checking', - combine_logic=NodeLogic.NONLAZY_OR, - children=algs, - force_order=True) - config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_extraoutputs.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_extraoutputs.py index 8bc3f0bcb87..bde3e6b1711 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_extraoutputs.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_extraoutputs.py @@ -15,7 +15,6 @@ import argparse import GaudiPython as GP from Configurables import HistogramPersistencySvc -from PyConf.control_flow import CompositeNode, NodeLogic from PyConf.application import configure_input, configure from Moore import options @@ -53,15 +52,9 @@ input_process = "Spruce" stream = 'default' dec_to_check = "Spruce_Test_line_extraoutputs" -algs = do_unpacking( +cf_node = do_unpacking( input_process=input_process, raw_event_format=0.3, stream=stream) -cf_node = CompositeNode( - 'checking', - combine_logic=NodeLogic.NONLAZY_OR, - children=algs, - force_order=True) - config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required diff --git a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_persistreco.py b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_persistreco.py index 5540c908915..d4c5435f95e 100644 --- a/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_persistreco.py +++ b/Hlt/Hlt2Conf/tests/options/sprucing/spruce_check_persistreco.py @@ -14,7 +14,6 @@ import argparse import GaudiPython as GP from Configurables import HistogramPersistencySvc -from PyConf.control_flow import CompositeNode, NodeLogic from PyConf.application import configure_input, configure from Moore import options @@ -49,15 +48,9 @@ options.input_type = 'ROOT' options.gaudipython_mode = True config = configure_input(options) -algs = do_unpacking( +cf_node = do_unpacking( input_process="Spruce", raw_event_format=0.3, has_mc_data=False) -cf_node = CompositeNode( - 'checking', - combine_logic=NodeLogic.NONLAZY_OR, - children=algs, - force_order=True) - config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required diff --git a/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py b/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py index 3efb5e7c65e..fdf2770c6b4 100644 --- a/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py +++ b/Hlt/Hlt2Conf/tests/options/streaming/stream_check.py @@ -17,7 +17,6 @@ import argparse import GaudiPython as GP LHCb = GP.gbl.LHCb -from PyConf.control_flow import CompositeNode, NodeLogic from Configurables import HistogramPersistencySvc from GaudiConf.reading import do_unpacking @@ -72,15 +71,9 @@ else: raweventloc = f'/Event/{args.stream}/RawEvent' options.input_stream = stream -algs = do_unpacking( +cf_node = do_unpacking( input_process=args.input_process, stream=stream, has_mc_data=False) -cf_node = CompositeNode( - 'checking', - combine_logic=NodeLogic.LAZY_AND, - children=algs, - force_order=True) - config.update(configure(options, cf_node)) # Disable warning about histogram saving not being required @@ -139,7 +132,7 @@ while True: if "A" in args.stream: # RawBank IDs as per LHCb/Event/DAQEvent/include/Event/RawBank.h if args.input_process == 'Hlt2': - saved_banks = {9, 13, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} + saved_banks = {9, 13, 15, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} elif args.input_process == 'Spruce': saved_banks = {9, 13, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} else: @@ -160,7 +153,7 @@ while True: # RawBank IDs as per LHCb/Event/DAQEvent/include/Event/RawBank.h # Rich bank removed if args.input_process == 'Hlt2': - saved_banks = {13, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} + saved_banks = {13, 15, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} elif args.input_process == 'Spruce': saved_banks = {13, 16, 17, 21, 22, 53, 54, 60, 63, 64, 66} else: diff --git a/Hlt/Moore/python/Moore/config.py b/Hlt/Moore/python/Moore/config.py index 86fa8219d54..51808ddc9b0 100644 --- a/Hlt/Moore/python/Moore/config.py +++ b/Hlt/Moore/python/Moore/config.py @@ -20,6 +20,7 @@ from PyConf.Algorithms import (HltDecReportsFilter, HltDecReportsMonitor, from PyConf.components import Algorithm from PyConf.control_flow import (CompositeNode, NodeLogic, traverse_node_and_children) + from PyConf.application import (ROOT_KEY, make_odin, default_raw_banks, all_nodes_and_algs, configure_input, configure) from .persistence import persist_line_outputs @@ -164,7 +165,6 @@ def moore_control_flow(options, streams, process, analytics=False): (line_output_cf, extra_locations_to_persist, packed_data) = persist_line_outputs( - options=options, streams=streams, dec_reports=dec_reports.DecReportsLocation, associate_mc=process == "hlt2" and options.simulation diff --git a/Hlt/Moore/python/Moore/persistence/__init__.py b/Hlt/Moore/python/Moore/persistence/__init__.py index ee7fcc9e4cf..e70ae9ba93e 100644 --- a/Hlt/Moore/python/Moore/persistence/__init__.py +++ b/Hlt/Moore/python/Moore/persistence/__init__.py @@ -119,7 +119,6 @@ def get_packed_locations(lines, inputs, output_prefix): @configurable def persist_line_outputs( - options, streams, dec_reports, associate_mc, @@ -143,11 +142,7 @@ def persist_line_outputs( persisted when writing to a ROOT file. """ - if (options.input_type != 'ROOT'): - log.warning("persist_line_outputs disabled as input_type is not ROOT") - reco_objs = {} - else: - reco_objs = reconstruction() + reco_objs = reconstruction() cf = [] protoparticle_relations = [] diff --git a/Hlt/RecoConf/python/RecoConf/reco_objects_from_file.py b/Hlt/RecoConf/python/RecoConf/reco_objects_from_file.py index 6726da7a222..3107a57593d 100644 --- a/Hlt/RecoConf/python/RecoConf/reco_objects_from_file.py +++ b/Hlt/RecoConf/python/RecoConf/reco_objects_from_file.py @@ -9,6 +9,7 @@ # or submit itself to any jurisdiction. # ############################################################################### from PyConf.reading import postprocess_unpacked_data +from PyConf.application import input_from_root_file from .data_from_file import reco_unpackers @@ -29,6 +30,10 @@ def reconstruction(): ### Temporary: as long as we persist v1, we need to insert a converter for the new PVs data = {k: v.OutputName for k, v in reco_unpackers().items()} + ### Temporary : This to be compatible with data where the RecSummary does not exist. + data["RecSummary"] = input_from_root_file( + '/Event/Rec/Summary', forced_type='LHCb::RecSummary') + # FIXME 'packable' set to true while 'SharedObjectsContainer`s are not persistable postprocess_unpacked_data(data, packable=True) -- GitLab From 74bc27967467a7ba55c9ccd2dde3e2f201eec837 Mon Sep 17 00:00:00 2001 From: Sebastien Ponce Date: Wed, 3 Apr 2024 18:20:37 +0200 Subject: [PATCH 11/11] Adapted to change of input files for more recent data --- Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py | 4 +++- Hlt/Moore/tests/options/default_conds_hlt1.py | 6 +++++- Hlt/Moore/tests/options/mdf_input_and_conds_hlt2_2024.py | 2 -- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py index 3aaad84dc3f..4a3732738a4 100644 --- a/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py +++ b/Hlt/Hlt2Conf/options/sprucing/spruce_passthrough.py @@ -16,7 +16,7 @@ Run like any other options file: """ from Moore import options, run_moore from RecoConf.global_tools import stateProvider_with_simplified_geom -from PyConf.application import create_or_reuse_rootIOAlg +from PyConf.application import create_or_reuse_rootIOAlg, configure_input from Moore.lines import PassLine input_files = ['hlt2_2or3bodytopo_realtime.mdf'] @@ -35,6 +35,8 @@ options.output_file = 'spruce_passthrough_gaudirun.dst' options.output_type = 'ROOT' options.output_manifest_file = "spruce_passthrough_gaudirun.tck.json" +configure_input(options) + def pass_through_line(name="Passthrough"): """Return a Sprucing line that performs no selection diff --git a/Hlt/Moore/tests/options/default_conds_hlt1.py b/Hlt/Moore/tests/options/default_conds_hlt1.py index 40cec19be10..e4730a7c0ac 100644 --- a/Hlt/Moore/tests/options/default_conds_hlt1.py +++ b/Hlt/Moore/tests/options/default_conds_hlt1.py @@ -9,5 +9,9 @@ # or submit itself to any jurisdiction. # ############################################################################### from Moore import options +from RecoConf.decoders import default_VeloCluster_source -options.set_conds_from_testfiledb('MiniBrunel_2018_MinBias_FTv4_DIGI') +# Use velo retina decoding: +default_VeloCluster_source.global_bind(bank_type="VPRetinaCluster") + +options.set_conds_from_testfiledb('expected_2024_minbias_xdigi') diff --git a/Hlt/Moore/tests/options/mdf_input_and_conds_hlt2_2024.py b/Hlt/Moore/tests/options/mdf_input_and_conds_hlt2_2024.py index 9fb74139078..ca48b2a3544 100644 --- a/Hlt/Moore/tests/options/mdf_input_and_conds_hlt2_2024.py +++ b/Hlt/Moore/tests/options/mdf_input_and_conds_hlt2_2024.py @@ -16,10 +16,8 @@ default_VeloCluster_source.global_bind(bank_type="VPRetinaCluster") options.set_conds_from_testfiledb('expected_2024_minbias_xdigi') -options.use_iosvc = True options.event_store = 'EvtStoreSvc' options.input_files = ['allen_mdf_write_for_hlt2.mdf'] options.input_type = 'MDF' options.persistreco_version = 0.0 -options.evt_max = 250 -- GitLab