|
|
Go to the documentation of this file.
19 #include <unordered_map>
49 _maxHoverE(conf.getParameter<double>(
"maximumHoverE")),
50 _pTbyPass(conf.getParameter<double>(
"minPTforBypass")),
51 _minSCPt(conf.getParameter<double>(
"minSuperClusterPt")),
52 _superClustersArePF(conf.getParameter<
bool>(
"superClustersArePF")),
58 auto eb_scs =
e.getHandle(
_srcEB);
59 auto ee_scs =
e.getHandle(
_srcEE);
61 elems.reserve(elems.size() + eb_scs->size() + ee_scs->size());
66 auto bsc = eb_scs->cbegin();
67 auto esc = eb_scs->cend();
70 for (
auto sc =
bsc; sc != esc; ++sc) {
73 auto sc_elem = std::find_if(elems.begin(), SCs_end, myEqual);
74 const double scpT =
ptFast(sc->energy(), sc->position(),
_zero);
76 const double H_tower =
78 const double HoverE = H_tower / sc->energy();
82 SCs_end = elems.emplace(SCs_end, scbe);
87 bsc = ee_scs->cbegin();
89 for (
auto sc =
bsc; sc != esc; ++sc) {
92 auto sc_elem = std::find_if(elems.begin(), SCs_end, myEqual);
93 const double scpT =
ptFast(sc->energy(), sc->position(),
_zero);
95 const double H_tower =
97 const double HoverE = H_tower / sc->energy();
101 SCs_end = elems.emplace(SCs_end, scbe);
105 elems.shrink_to_fit();
double depth2HcalESum(std::vector< CaloTowerDetId > const &towers, CaloTowerCollection const &)
std::vector< SuperCluster > SuperClusterCollection
collection of SuperCluser objectr
const edm::ESGetToken< CaloTowerConstituentsMap, CaloGeometryRecord > _ctmapToken
void importToBlock(const edm::Event &, ElementList &) const override
edm::Ref< SuperClusterCollection > SuperClusterRef
reference to an object in a collection of SuperCluster objects
#define DEFINE_EDM_PLUGIN(factory, type, name)
edm::EDGetTokenT< reco::SuperClusterCollection > _srcEB
std::vector< std::unique_ptr< reco::PFBlockElement > > ElementList
void setFromPFSuperCluster(bool val)
std::vector< CaloTowerDetId > towersOf(reco::SuperCluster const &sc, CaloTowerConstituentsMap const &towerMap, HoeMode mode=HoeMode::SingleTower)
XYZPointD XYZPoint
point in space with cartesian internal representation
static int position[264][3]
edm::EDGetTokenT< CaloTowerCollection > _srcTowers
CaloTowerConstituentsMap const * towerMap_
bool getData(T &iHolder) const
edm::EDGetTokenT< reco::SuperClusterCollection > _srcEE
void updateEventSetup(const edm::EventSetup &es) override
double depth1HcalESum(std::vector< CaloTowerDetId > const &towers, CaloTowerCollection const &)
static const math::XYZPoint _zero
double ptFast(const double energy, const math::XYZPoint &position, const math::XYZPoint &origin)
SuperClusterImporter(const edm::ParameterSet &, edm::ConsumesCollector &)