1 #ifndef __RecoLocalCalo_HGCRecProducers_HGCalLayerClusterProducer_H__ 2 #define __RecoLocalCalo_HGCRecProducers_HGCalLayerClusterProducer_H__ 46 std::unique_ptr<HGCalImagingAlgo>
algo;
61 std::vector<double> vecDeltas = ps.
getParameter<std::vector<double> >(
"deltac");
69 bool dependSensor = ps.
getParameter<
bool>(
"dependSensor");
91 algo = std::make_unique<HGCalImagingAlgo>(vecDeltas,
kappa, ecut,
showerSigma,
algoId, dependSensor,
dEdXweights,
thicknessCorrection,
fcPerMip,
fcPerEle,
nonAgedNoises,
noiseMip,
verbosity);
93 algo = std::make_unique<HGCalImagingAlgo>(vecDeltas,
kappa, ecut,
algoId, dependSensor,
dEdXweights,
thicknessCorrection,
fcPerMip,
fcPerEle,
nonAgedNoises,
noiseMip,
verbosity);
97 produces<std::vector<reco::BasicCluster> >();
98 produces<std::vector<reco::BasicCluster> >(
"sharing");
107 desc.
add<
bool>(
"doSharing",
false);
108 desc.
add<std::vector<double>>(
"deltac", {
113 desc.
add<
bool>(
"dependSensor",
true);
114 desc.
add<
double>(
"ecut", 3.0);
115 desc.
add<
double>(
"kappa", 9.0);
120 desc.
add<std::vector<double>>(
"dEdXweights",{});
121 desc.
add<std::vector<double>>(
"thicknessCorrection",{});
122 desc.
add<std::vector<double>>(
"fcPerMip",{});
123 desc.
add<
double>(
"fcPerEle",0.0);
125 descNestedNoises.
add<std::vector<double> >(
"values", {});
128 descNestedNoiseMIP.
add<
double>(
"value", 0 );
130 descriptions.
add(
"hgcalLayerClusters", desc);
143 std::unique_ptr<std::vector<reco::BasicCluster> >
clusters(
new std::vector<reco::BasicCluster> ),
144 clusters_sharing(
new std::vector<reco::BasicCluster> );
148 algo->getEventSetup(es);
153 algo->populate(*ee_hits);
159 algo->populate(*fh_hits);
160 }
else if ( bh_hits.
isValid() ) {
161 algo->populate(*bh_hits);
166 algo->populate(*ee_hits);
168 algo->populate(*fh_hits);
170 algo->populate(*bh_hits);
175 algo->makeClusters();
178 *clusters_sharing =
algo->getClusters(
true);
181 auto clusterHandleSharing = evt.
put(
std::move(clusters_sharing),
"sharing");
183 for(
unsigned i = 0;
i < clusterHandle->size(); ++
i ) {
189 for(
unsigned i = 0;
i < clusterHandleSharing->size(); ++
i ) {
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
void produce(edm::Event &, const edm::EventSetup &) override
ParameterDescriptionBase * addUntracked(U const &iLabel, T const &value)
reco::CaloCluster::AlgoId algoId
bool getByToken(EDGetToken token, Handle< PROD > &result) const
HGCalImagingAlgo::VerbosityLevel verbosity
#define DEFINE_FWK_MODULE(type)
void push_back(Ptr< T > const &iPtr)
edm::EDGetTokenT< HGCRecHitCollection > hits_bh_token
~HGCalLayerClusterProducer() override
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
edm::EDGetTokenT< HGCRecHitCollection > hits_ee_token
void add(std::string const &label, ParameterSetDescription const &psetDescription)
HGCalLayerClusterProducer(const edm::ParameterSet &)
edm::EDGetTokenT< HGCRecHitCollection > hits_fh_token
static const G4double kappa
std::unique_ptr< HGCalImagingAlgo > algo