38 if (approxVersionS ==
"ORIGINAL")
40 else if (approxVersionS ==
"FULL_WIDTH")
42 else if (approxVersionS ==
"BARY_RES_0.1")
44 else if (approxVersionS ==
"BARY_CHARGE_RES_0.1")
48 produces<edmNew::DetSetVector<SiStripApproximateCluster>>();
52 auto result = std::make_unique<edmNew::DetSetVector<SiStripApproximateCluster>>();
55 for (
const auto& detClusters : clusterCollection) {
58 for (
const auto& cluster : detClusters) {
59 float barycenter = cluster.barycenter();
60 uint8_t width = cluster.width();
61 float avgCharge = cluster.avgCharge();
65 barycenter = std::round(barycenter);
68 avgCharge = std::round(avgCharge);
71 barycenter = std::round(barycenter);
72 avgCharge = std::round(avgCharge);
75 barycenter = std::round(barycenter * 10) / 10;
78 avgCharge = std::round(avgCharge);
81 barycenter = std::round(barycenter * 10) / 10;
84 avgCharge = std::round(avgCharge * 10) / 10;
100 descriptions.
add(
"SiStripApprox2ApproxClusters", desc);
#define DEFINE_FWK_MODULE(type)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
edm::EDGetTokenT< edmNew::DetSetVector< SiStripApproximateCluster > > clusterToken
std::string approxVersionS
SiStripApprox2ApproxClusters(const edm::ParameterSet &conf)
T getParameter(std::string const &) const
void add(std::string const &label, ParameterSetDescription const &psetDescription)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
void produce(edm::Event &, const edm::EventSetup &) override
edm::InputTag inputApproxClusters