11 #include <unordered_map> 25 std::unique_ptr<const PhotonSelectorAlgo>
_selector;
36 _superClustersArePF(conf.getParameter<
bool>(
"superClustersArePF")) {
38 _selectionChoice = _selectionTypes.at(selChoice);
41 const float trackIso_const = selDef.
getParameter<
double>(
"trackIsoConstTerm");
42 const float trackIso_slope = selDef.
getParameter<
double>(
"trackIsoSlopeTerm");
43 const float ecalIso_const = selDef.
getParameter<
double>(
"ecalIsoConstTerm");
44 const float ecalIso_slope = selDef.
getParameter<
double>(
"ecalIsoSlopeTerm");
45 const float hcalIso_const = selDef.
getParameter<
double>(
"hcalIsoConstTerm");
46 const float hcalIso_slope = selDef.
getParameter<
double>(
"hcalIsoSlopeTerm");
48 const float loose_hoe = selDef.
getParameter<
double>(
"LooseHoverE");
49 const float combIso = selDef.
getParameter<
double>(
"combIsoConstTerm");
50 _selector = std::make_unique<PhotonSelectorAlgo>((
float)_selectionChoice,
66 elems.reserve(elems.size() +
photons->size());
68 auto SCs_end = std::partition(
71 auto bphoton =
photons->cbegin();
80 auto sc_elem = std::find_if(elems.begin(), SCs_end, myEqual);
81 if (sc_elem != SCs_end) {
98 SCs_end = elems.insert(SCs_end, ElementType(scbe));
103 elems.shrink_to_fit();
T getParameter(std::string const &) const
const std::unordered_map< std::string, SelectionChoices > _selectionTypes
ParameterSet const & getParameterSet(std::string const &) const
SelectionChoices _selectionChoice
void setFromPhoton(bool val)
set provenance
void setHcalIso(float val)
set the had Iso
void importToBlock(const edm::Event &, ElementList &) const override
EGPhotonImporter(const edm::ParameterSet &, edm::ConsumesCollector &)
Container::value_type value_type
void setTrackIso(float val)
set the track Iso
void setPhotonRef(const PhotonRef &ref)
set photonRef
void setHoE(float val)
set H/E
std::vector< Photon > PhotonCollection
collectin of Photon objects
edm::Ref< PhotonCollection > PhotonRef
reference to an object in a collection of Photon objects
edm::EDGetTokenT< reco::PhotonCollection > _src
#define DEFINE_EDM_PLUGIN(factory, type, name)
std::vector< std::unique_ptr< reco::PFBlockElement > > ElementList
void setEcalIso(float val)
set the ecal Iso
void setFromPFSuperCluster(bool val)
std::unique_ptr< const PhotonSelectorAlgo > _selector