8#ifndef EVENTPROC_DNNECALVETOPROCESSOR_H_
9#define EVENTPROC_DNNECALVETOPROCESSOR_H_
13#include "Ecal/Event/EcalHit.h"
15#include "Framework/Configure/Parameters.h"
17#include "Tools/ONNXRuntime.h"
39 const std::vector<ldmx::EcalHit>& ecalRecHits);
46 constexpr static unsigned int n_coordinate_dim_ = 3;
47 constexpr static unsigned int coordinate_x_offset_ = 0;
48 constexpr static unsigned int coordinate_y_offset_ =
max_num_hits_;
49 constexpr static unsigned int coordinate_z_offset_ = 2 *
max_num_hits_;
51 constexpr static unsigned int n_feature_dim_ = 5;
52 constexpr static unsigned int feature_x_offset_ = 0;
53 constexpr static unsigned int feature_y_offset_ =
max_num_hits_;
54 constexpr static unsigned int feature_z_offset_ = 2 *
max_num_hits_;
55 constexpr static unsigned int feature_layerid_offset_ = 3 *
max_num_hits_;
56 constexpr static unsigned int feature_energy_offset_ = 4 *
max_num_hits_;
58 const static std::vector<std::string> input_names_;
59 const static std::vector<unsigned int> input_sizes_;
61 float disc_cut_ = -99;
62 std::vector<std::vector<float>> data_;
63 std::unique_ptr<ldmx::Ort::ONNXRuntime> rt_;
Class that translates raw positions of ECal module hits into cells in a hexagonal readout.
Class used to encapsulate the results obtained from EcalVetoProcessor.
Base classes for all user event processing components to extend.
Determines if event is vetoable using ECAL hit information w/ a deep neural network.
void produce(framework::Event &event) override
Process the event and put new data products into it.
static constexpr unsigned int max_num_hits_
Maximum number of hits allowed in ECAL.
void make_inputs(const ldmx::EcalGeometry &geom, const std::vector< ldmx::EcalHit > &ecalRecHits)
Make inputs to the DNN from ECAL RecHits.
void configure(framework::config::Parameters ¶meters) override
Callback for the EventProcessor to configure itself from the given set of parameters.
std::string collectionName_
Name of the collection which will containt the results.
Implements an event buffer system for storing event data.
Class which represents the process under execution.
Base class for a module which produces a data product.
Class encapsulating parameters for configuring a processor.
Translation between real-space positions and cell IDs within the ECal.