From 826e536456a59f020c812608ae22961433335bd8 Mon Sep 17 00:00:00 2001
From: xueting <xueting.yang@cern.ch>
Date: Fri, 17 Feb 2023 19:32:48 +0800
Subject: [PATCH 1/4] qmtest_hlt1_hlt2_comparision

---
 .../tests/qmtest/hlt1_hlt2_comparison.qmt     | 35 +++++++++++++++++++
 1 file changed, 35 insertions(+)
 create mode 100644 Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt

diff --git a/Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt b/Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt
new file mode 100644
index 00000000000..24dc72bd674
--- /dev/null
+++ b/Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE extension  PUBLIC '-//QM/2.3/Extension//EN'  'http://www.codesourcery.com/qm/dtds/2.3/-//qm/2.3/extension//en.dtd'>
+<!--
+    (c) Copyright 2000-2023 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.
+-->
+<!--
+qmt test to compare tracks from HLT1 to HLT2.
+-->
+<extension class="GaudiTest.GaudiExeTest" kind="test">
+<argument name="program"><text>gaudirun.py</text></argument>
+<argument name="timeout"><integer>2400</integer></argument> 
+<argument name="args"><set>
+  <text>$MOOREROOT/tests/options/default_input_and_conds_hlt2.py</text>
+  <text>$RECOCONFROOT/options/hlt1_hlt2_comparison.py</text>
+</set></argument>
+<argument name="use_temp_dir"><enumeral>true</enumeral></argument>
+<argument name="reference"><text>../refs/hlt1_hlt2_comparison.ref</text></argument>  
+<argument name="error_reference"><text>../refs/empty.ref</text></argument>  
+<argument name="validator"><text>
+
+from Moore.qmtest.exclusions import ref_preprocessor, counter_preprocessor
+validateWithReference(preproc = ref_preprocessor, counter_preproc = counter_preprocessor)
+
+from Moore.qmtest.exclusions import remove_known_warnings
+countErrorLines({"FATAL": 0, "ERROR": 0, "WARNING": 0},
+                stdout=remove_known_warnings(stdout))
+
+</text></argument>
+</extension>
-- 
GitLab


From bd209bf78abe6195579a22b06c37de3a3c73f1bc Mon Sep 17 00:00:00 2001
From: xueting <xueting.yang@cern.ch>
Date: Fri, 17 Feb 2023 20:17:39 +0800
Subject: [PATCH 2/4] update of hlt1_hlt2_comparison

---
 Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt b/Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt
index 24dc72bd674..6eec421bf8c 100644
--- a/Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt
+++ b/Hlt/RecoConf/tests/qmtest/hlt1_hlt2_comparison.qmt
@@ -16,7 +16,7 @@ qmt test to compare tracks from HLT1 to HLT2.
 <argument name="program"><text>gaudirun.py</text></argument>
 <argument name="timeout"><integer>2400</integer></argument> 
 <argument name="args"><set>
-  <text>$MOOREROOT/tests/options/default_input_and_conds_hlt2.py</text>
+  <text>$MOOREROOT/tests/options/digi_input_and_conds_Sim10aU1.py</text>
   <text>$RECOCONFROOT/options/hlt1_hlt2_comparison.py</text>
 </set></argument>
 <argument name="use_temp_dir"><enumeral>true</enumeral></argument>
-- 
GitLab


From 4a11393b61f4391701fe6a1ce9db0bc9578abcc5 Mon Sep 17 00:00:00 2001
From: xueting <xueting.yang@cern.ch>
Date: Mon, 6 Mar 2023 13:54:39 +0800
Subject: [PATCH 3/4] change hlt1_hlt2_comparison.py script

---
 Hlt/RecoConf/options/hlt1_hlt2_comparison.py | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/Hlt/RecoConf/options/hlt1_hlt2_comparison.py b/Hlt/RecoConf/options/hlt1_hlt2_comparison.py
index e7bb77f4429..4db8f9587f6 100644
--- a/Hlt/RecoConf/options/hlt1_hlt2_comparison.py
+++ b/Hlt/RecoConf/options/hlt1_hlt2_comparison.py
@@ -14,7 +14,7 @@ from Moore.config import Reconstruction
 from RecoConf.hlt1_tracking import all_velo_track_types, make_all_pvs
 from RecoConf.event_filters import require_gec
 from RecoConf.hlt1_allen import make_allen_forward_tracks
-from RecoConf.hlt2_tracking import make_hlt2_tracks
+from RecoConf.hlt2_global_reco import reconstruction
 from RecoConf.mc_checking import checker_trigger_objects
 from AllenConf.hlt1_reconstruction import hlt1_reconstruction
 
@@ -33,12 +33,12 @@ def reco():
 
     pvs = make_all_pvs()["v1"]
 
-    hlt2_tracks = make_hlt2_tracks(
-        light_reco=False, fast_reco=True, use_pr_kf=True)
+    tracks = reconstruction()["Tracks"]
+    Velotracks = reconstruction()["VeloTracks"]
 
     checker = checker_trigger_objects(
-        allen_forward_tracks["v1"], hlt2_tracks["Best"]["v1"], allen_pvs, pvs,
-        allen_velo_tracks["v1"], hlt2_tracks["Velo"]["v1"])
+        allen_forward_tracks["v1"], tracks, allen_pvs, pvs,
+        allen_velo_tracks["v1"], Velotracks)
 
     return Reconstruction('hlt1', checker, [require_gec()])
 
-- 
GitLab


From 3ad9bdd5eb1db52d7cd4e51b1ee880b8f1fb0b14 Mon Sep 17 00:00:00 2001
From: xueting <xueting.yang@cern.ch>
Date: Mon, 6 Mar 2023 14:02:32 +0800
Subject: [PATCH 4/4] change formatting

---
 Hlt/RecoConf/options/hlt1_hlt2_comparison.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/Hlt/RecoConf/options/hlt1_hlt2_comparison.py b/Hlt/RecoConf/options/hlt1_hlt2_comparison.py
index 4db8f9587f6..7f4dc546254 100644
--- a/Hlt/RecoConf/options/hlt1_hlt2_comparison.py
+++ b/Hlt/RecoConf/options/hlt1_hlt2_comparison.py
@@ -36,9 +36,9 @@ def reco():
     tracks = reconstruction()["Tracks"]
     Velotracks = reconstruction()["VeloTracks"]
 
-    checker = checker_trigger_objects(
-        allen_forward_tracks["v1"], tracks, allen_pvs, pvs,
-        allen_velo_tracks["v1"], Velotracks)
+    checker = checker_trigger_objects(allen_forward_tracks["v1"], tracks,
+                                      allen_pvs, pvs, allen_velo_tracks["v1"],
+                                      Velotracks)
 
     return Reconstruction('hlt1', checker, [require_gec()])
 
-- 
GitLab