Skip to content
Snippets Groups Projects

Add test for reading a Moore DST

Merged Patrick Koppenburg requested to merge pkoppenb-readMoore into master
All threads resolved!
Files
2
###############################################################################
# (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. #
###############################################################################
"""
Test of a DST produced by HLT2 (Moore).
"""
__author__ = "Patrick Koppenburg"
__date__ = "2021-03-22"
from PyConf.application import configure, configure_input
from PyConf.control_flow import CompositeNode, NodeLogic
from PyConf.Algorithms import PrintDecayTree
from DaVinci import options
from DaVinci.reco_objects import upfront_reconstruction_from_file as upfront_reconstruction
from DaVinci.common_particles import make_std_loose_d2kk
options.evt_max = -1
options.print_freq = 1
options.msg_svc_format = "% F%60W%S%7W%R%T %0W%M"
d0s = make_std_loose_d2kk()
pdt = PrintDecayTree(name="PrintD0s", Input=d0s)
# the "upfront_reconstruction" is what unpacks reconstruction objects, particles and primary vertices
# from file and creates protoparticles.
algs = upfront_reconstruction() + [d0s, pdt]
node = CompositeNode(
"PrintD0Node", children=algs, combine_logic=NodeLogic.NONLAZY_AND)
# File from Moore test
options.set_input_and_conds_from_testfiledb("Moore-Output-DST")
config = configure_input(options)
config.update(configure(options, node))
Loading