Commit 8b40146f authored by Rosen Matev's avatar Rosen Matev 🌲
Browse files

Merge branch 'doc_hlt1reports' into 'master'

Analysing HLT1 decision reports after HLT2

See merge request lhcb/Moore!1051
parents c5cadc07 c40c3429
......@@ -103,6 +103,7 @@ familiar to you::
......@@ -124,10 +125,15 @@ familiar to you::
This is a temporary measure until support for Run 3 HLT2 output is added to
an LHCb application.
unpacker = LHCb__UnpackRawEvent(
dec_reports = HltDecReportsDecoder(
SourceID='Hlt2', OutputHltDecReportsLocation="/Event/Hlt2/DecReports")
reading_algs = ([reading.decoder()] + reading.unpackers() + [dec_reports] +
[unpacker, createODIN()])
if is_simulation:
reading_algs = reading.mc_unpackers() + reading_algs
return reading_algs
......@@ -285,4 +291,50 @@ To include tuple tools that use truth information, you need to ensure the
Here, ``dtt`` is the ``DecayTreeTuple`` instance you want to add the truth
tools to.
Analysing HLT1 decision reports after HLT2
If you run your simulation data through HLT1 and then through HLT2 you probably want to access both sets of decision reports.
The HLT1 and HLT2 decision reports are (currently) "decoded" differently (the HLT1 decision reports must use the ``TCKANNSvc``) so there are a couple of steps to this.
First run your simulation through the HLT1 step taking inspriration from the `Hlt/Hlt1Conf/tests/qmtest/persistency.qms/allen_mdf_write.qmt`_ unit test which runs::
./run Hlt/Moore/tests/options/ Hlt/Hlt1Conf/tests/options/ Hlt/Hlt1Conf/options/
(The simulation files you are using should be ``.(x)digi`` files)
You now need to both make and assign a ``tck`` for HLT1 to use::
./run python Hlt/Hlt1Conf/tests/options/
This uses the `get_allen_hlt1_decision_ids`_ method from Moore to collect the int->str decoding relations for the HLT1 lines. After running this you should see a file ``TCKData/config.cdb``.
We now assign this to the ``tck`` ID ``0x11300000``::
./run python ../LHCb/Hlt/HltServices/tests/options/ 0x11300000
The HLT1 decision reports can now by accessed using the following::
ConfigCDBAccessSvc().File = "TCKData/config.cdb"
The HLT2 decision reports will still use the passed ``tck.json`` file and so you will need::
Your HLT1 decision reports will then be located at ``/Event/Hlt1/DecReports`` and you HLT2 decision reports at ``/Event/Hlt2/DecReports``.
.. _analysed Turbo data:
.. _Hlt/Hlt1Conf/tests/qmtest/persistency.qms/allen_mdf_write.qmt:
.. _get_allen_hlt1_decision_ids:
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment