EICrecon
JANA based reconstruction for the EPIC detector
Loading...
Searching...
No Matches
ImagingTopoCluster_factory.h
Go to the documentation of this file.
1// SPDX-License-Identifier: LGPL-3.0-or-later
2// Copyright (C) 2023 Wouter Deconinck
3
4#pragma once
5
9
10namespace eicrecon {
11
13 : public JOmniFactory<ImagingTopoCluster_factory, ImagingTopoClusterConfig> {
14
15public:
17
18private:
19 std::unique_ptr<AlgoT> m_algo;
20
21 PodioInput<edm4eic::CalorimeterHit> m_hits_input{this};
22 PodioOutput<edm4eic::ProtoCluster> m_protos_output{this};
23
24 // ParameterRef<std::vector<double>> m_ldxy_same{this, "sameLayerDistXY",
25 // config().sameLayerDistXY};
26 // ParameterRef<std::vector<double>> m_ldxy_diff{this, "diffLayerDistXY",
27 // config().diffLayerDistXY};
28 ParameterRef<std::vector<double>> m_ldep_same{this, "sameLayerDistEtaPhi",
29 config().sameLayerDistEtaPhi};
30 ParameterRef<std::vector<double>> m_ldep_diff{this, "diffLayerDistEtaPhi",
31 config().diffLayerDistEtaPhi};
32 ParameterRef<std::vector<double>> m_ldtz_same{this, "sameLayerDistTZ", config().sameLayerDistTZ};
33 ParameterRef<std::vector<double>> m_ldtz_diff{this, "diffLayerDistTZ", config().diffLayerDistTZ};
34 ParameterRef<eicrecon::ImagingTopoClusterConfig::ELayerMode> m_sameLayerMode{
35 this, "sameLayerMode", config().sameLayerMode};
36 ParameterRef<eicrecon::ImagingTopoClusterConfig::ELayerMode> m_diffLayerMode{
37 this, "diffLayerMode", config().diffLayerMode};
38
39 ParameterRef<int> m_nlr{this, "neighbourLayersRange", config().neighbourLayersRange};
40 ParameterRef<double> m_sd{this, "sectorDist", config().sectorDist};
41 ParameterRef<double> m_mched{this, "minClusterHitEdep", config().minClusterHitEdep};
42 ParameterRef<double> m_mcced{this, "minClusterCenterEdep", config().minClusterCenterEdep};
43 ParameterRef<double> m_mced{this, "minClusterEdep", config().minClusterEdep};
44 ParameterRef<std::size_t> m_mcnh{this, "minClusterNhits", config().minClusterNhits};
45
46 Service<AlgorithmsInit_service> m_algorithmsInit{this};
47
48public:
49 void Configure() {
50 m_algo = std::make_unique<AlgoT>(GetPrefix());
51 m_algo->level(static_cast<algorithms::LogLevel>(logger()->level()));
52 m_algo->applyConfig(config());
53 m_algo->init();
54 }
55
56 void Process(int32_t /* run_number */, uint64_t /* event_number */) {
57 m_algo->process({m_hits_input()}, {m_protos_output().get()});
58 }
59};
60
61} // namespace eicrecon
Definition JOmniFactory.h:30
ImagingTopoClusterConfig & 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
Definition ImagingTopoCluster_factory.h:13
void Process(int32_t, uint64_t)
Definition ImagingTopoCluster_factory.h:56
void Configure()
Definition ImagingTopoCluster_factory.h:49
Definition ImagingTopoCluster.h:44
-client
Definition CalorimeterClusterRecoCoG.cc:37