EICrecon
JANA based reconstruction for the EPIC detector
Loading...
Searching...
No Matches
MC2ReconstructedParticle_factory.h
Go to the documentation of this file.
1// Created by Dmitry Romanov
2// Subject to the terms in the LICENSE file found in the top-level directory.
3//
4
5#pragma once
6
7#include <JANA/JEvent.h>
8#include <edm4eic/ReconstructedParticleCollection.h>
9#include <memory>
10#include <string>
11#include <utility>
12#include <vector>
13
16
17namespace eicrecon {
18
20 : public JOmniFactory<MC2ReconstructedParticle_factory, NoConfig> {
21
22private:
24 std::unique_ptr<AlgoT> m_algo;
25
26 PodioInput<edm4hep::MCParticle> m_mc_particles_input{this};
27 PodioOutput<edm4eic::ReconstructedParticle> m_rc_particles_output{this};
28
29public:
30 void Configure() {
31 m_algo = std::make_unique<AlgoT>(GetPrefix());
32 m_algo->level(static_cast<algorithms::LogLevel>(logger()->level()));
33 m_algo->applyConfig(config());
34 m_algo->init();
35 }
36
37 void Process(int32_t /* run_number */, uint64_t /* event_number */) {
38 m_algo->process({m_mc_particles_input()}, {m_rc_particles_output().get()});
39 }
40};
41
42} // namespace eicrecon
Definition JOmniFactory.h:30
NoConfig & config()
Retrieve reference to embedded config object.
Definition JOmniFactory.h:576
std::shared_ptr< spdlog::logger > & logger()
Retrieve reference to already-configured logger.
Definition JOmniFactory.h:573
std::string GetPrefix()
Definition JOmniFactory.h:570
Definition MC2ReconstructedParticle_factory.h:20
void Configure()
Definition MC2ReconstructedParticle_factory.h:30
void Process(int32_t, uint64_t)
Definition MC2ReconstructedParticle_factory.h:37
Definition MC2ReconstructedParticle.h:24
-client
Definition CalorimeterClusterRecoCoG.cc:37