|
|
|
const reco::PFCandidate & | correspondingDaughterCandidate (const reco::PFCandidate &cand, const reco::PFBlockElement &pfbe) const |
|
void | createBasicCluster (const reco::PFBlockElement &, reco::BasicClusterCollection &basicClusters, std::vector< const reco::PFCluster * > &, const reco::PFCandidate &coCandidate) const |
|
void | createBasicClusterPtrs (const edm::OrphanHandle< reco::BasicClusterCollection > &basicClustersHandle) |
|
void | createOneLegConversions (const edm::OrphanHandle< reco::SuperClusterCollection > &superClustersHandle, reco::ConversionCollection &oneLegConversions) |
|
void | createPhotonCores (const edm::OrphanHandle< reco::SuperClusterCollection > &superClustersHandle, const edm::OrphanHandle< reco::ConversionCollection > &oneLegConversionHandle, reco::PhotonCoreCollection &photonCores) |
|
void | createPhotons (reco::VertexCollection &vertexCollection, edm::Handle< reco::PhotonCollection > &egPhotons, const edm::OrphanHandle< reco::PhotonCoreCollection > &photonCoresHandle, const IsolationValueMaps &isolationValues, reco::PhotonCollection &photons) |
|
void | createPreshowerCluster (const reco::PFBlockElement &PFBE, reco::PreshowerClusterCollection &preshowerClusters, unsigned plane) const |
|
void | createPreshowerClusterPtrs (const edm::OrphanHandle< reco::PreshowerClusterCollection > &preshowerClustersHandle) |
|
void | createSuperClusters (const reco::PFCandidateCollection &, reco::SuperClusterCollection &superClusters) const |
|
bool | fetchCandidateCollection (edm::Handle< reco::PFCandidateCollection > &c, const edm::InputTag &tag, const edm::Event &iEvent) const |
|
Definition at line 34 of file PFPhotonTranslator.cc.
◆ IsolationValueMaps
◆ PFPhotonTranslator()
◆ ~PFPhotonTranslator()
PFPhotonTranslator::~PFPhotonTranslator |
( |
| ) |
|
|
override |
◆ correspondingDaughterCandidate()
◆ createBasicCluster()
Definition at line 597 of file PFPhotonTranslator.cc.
602 if (myPFClusterRef.
isNull())
606 pfClusters.push_back(&myPFCluster);
612 myPFCluster.energy(),
613 myPFCluster.position(),
614 myPFCluster.caloID(),
615 myPFCluster.hitsAndFractions(),
617 myPFCluster.seed()));
References reco::CaloCluster::algo(), reco::CaloCluster::caloID(), reco::PFBlockElement::clusterRef(), reco::PFCluster::energy(), reco::CaloCluster::hitsAndFractions(), edm::Ref< C, T, F >::isNull(), reco::CaloCluster::position(), and reco::CaloCluster::seed().
◆ createBasicClusterPtrs()
Definition at line 628 of file PFPhotonTranslator.cc.
631 unsigned basicClusterCounter = 0;
634 for (
unsigned iphot = 0; iphot <
size; ++iphot)
637 for (
unsigned ibc = 0; ibc < nbc; ++ibc)
642 ++basicClusterCounter;
References findQualityFiles::size.
◆ createOneLegConversions()
Definition at line 753 of file PFPhotonTranslator.cc.
759 for (
unsigned iphot = 0; iphot < nphot; ++iphot) {
766 std::vector<reco::CaloClusterPtr> matchingBC;
774 std::vector<reco::TrackRef> OneLegConvVector;
777 std::vector<reco::TrackRef> tr = OneLegConvVector;
778 std::vector<math::XYZPointF> trackPositionAtEcalVec;
779 std::vector<math::XYZPointF> innPointVec;
780 std::vector<math::XYZVectorF> trackPinVec;
781 std::vector<math::XYZVectorF> trackPoutVec;
796 trackPositionAtEcalVec.push_back(trackPositionAtEcal);
797 innPointVec.push_back(innPoint);
798 trackPinVec.push_back(trackPin);
799 trackPoutVec.push_back(trackPout);
800 std::vector<float> OneLegMvaVector;
803 trackPositionAtEcalVec,
813 myOneLegConversion.setOneLegMVA(OneLegMvaVector);
829 oneLegConversions.push_back(myOneLegConversion);
References relativeConstraints::error, reco::Conversion::pflow, reco::Conversion::setOneLegMVA(), HltBtagValidation_cff::Vertex, X, BeamSpotPI::Y, and BeamSpotPI::Z.
◆ createPhotonCores()
◆ createPhotons()
Definition at line 924 of file PFPhotonTranslator.cc.
933 for (
unsigned iphot = 0; iphot < nphot; ++iphot) {
946 math::XYZVector P3 = direction.unit() * PCref->parentSuperCluster()->energy();
947 LorentzVector P4(P3.x(), P3.y(), P3.z(), PCref->parentSuperCluster()->energy());
949 reco::Photon myPhoton(P4, PCref->parentSuperCluster()->position(), PCref,
vtx);
962 showerShape.maxEnergyXtal =
egPhotonRef_[iphot]->maxEnergyXtal();
963 showerShape.sigmaEtaEta =
egPhotonRef_[iphot]->sigmaEtaEta();
964 showerShape.sigmaIetaIeta =
egPhotonRef_[iphot]->sigmaIetaIeta();
965 showerShape.hcalDepth1OverEcal =
egPhotonRef_[iphot]->hadronicDepth1OverEm();
966 showerShape.hcalDepth2OverEcal =
egPhotonRef_[iphot]->hadronicDepth2OverEm();
967 myPhoton.setShowerShapeVariables(showerShape);
971 myPhoton.setSaturationInfo(saturationInfo);
980 myPhoton.setFiducialVolumeFlags(fiducialFlags);
998 myPhoton.setIsolationVariables(isolationVariables04, isolationVariables03);
1004 myPhoton.setPflowIsolationVariables(myPFIso);
1009 myMustache.MustacheID(
1012 myPhoton.setPflowIDVariables(myPFVariables);
1017 myPhoton.setCorrectedEnergy(
References reco::Photon::PflowIsolationVariables::chargedHadronIso, reco::Photon::IsolationVariables::ecalRecHitSumEt, reco::Photon::PflowIDVariables::etOutsideMustache, reco::Photon::IsolationVariables::hcalDepth1TowerSumEt, reco::Photon::IsolationVariables::hcalDepth2TowerSumEt, reco::Photon::IsolationVariables::hcalTowerSumEt, reco::Photon::FiducialFlags::isEB, reco::Photon::FiducialFlags::isEBEEGap, reco::Photon::FiducialFlags::isEBEtaGap, reco::Photon::FiducialFlags::isEBPhiGap, reco::Photon::FiducialFlags::isEE, reco::Photon::FiducialFlags::isEEDeeGap, reco::Photon::FiducialFlags::isEERingGap, electronProducer_cff::isolationValues, reco::Photon::SaturationInfo::isSeedSaturated, reco::Mustache::MustacheID(), reco::Photon::PflowIDVariables::mva, reco::Photon::PflowIDVariables::nClusterOutsideMustache, reco::Photon::PflowIsolationVariables::neutralHadronIso, reco::Photon::SaturationInfo::nSaturatedXtals, reco::Photon::IsolationVariables::nTrkHollowCone, reco::Photon::IsolationVariables::nTrkSolidCone, reco::Photon::PflowIsolationVariables::photonIso, BPHMonitor_cfi::photons, reco::Photon::regression2, reco::Photon::IsolationVariables::trkSumPtHollowCone, reco::Photon::IsolationVariables::trkSumPtSolidCone, spclusmultinvestigator_cfi::vertexCollection, and extraflags_cff::vtx.
◆ createPreshowerCluster()
◆ createPreshowerClusterPtrs()
◆ createSuperClusters()
Definition at line 666 of file PFPhotonTranslator.cc.
669 for (
unsigned iphot = 0; iphot < nphot; ++iphot) {
673 double sclusterE = 0;
679 for (
unsigned ibc = 0; ibc < nbasics; ++ibc) {
720 for (
unsigned ibc = 0; ibc < nbasics; ++ibc) {
723 const std::vector<std::pair<DetId, float> > &v1 =
basicClusters_[iphot][ibc].hitsAndFractions();
725 for (
std::vector<std::pair<DetId, float> >::const_iterator diIt = v1.begin(); diIt != v1.end(); ++diIt) {
727 mySuperCluster.addHitAndFraction(diIt->first, diIt->second);
732 for (
unsigned ips = 0; ips < nps; ++ips) {
741 mySuperCluster.setEtaWidth(pfwidth.pflowEtaWidth());
742 mySuperCluster.setPhiWidth(pfwidth.pflowPhiWidth());
744 mySuperCluster.rawEnergy();
References reco::SuperCluster::addCluster(), reco::CaloCluster::addHitAndFraction(), reco::SuperCluster::addPreshowerCluster(), MillePedeFileConverter_cfg::e, PFClusterWidthAlgo::pflowEtaWidth(), PFClusterWidthAlgo::pflowPhiWidth(), RecoTauValidation_cfi::posX, RecoTauValidation_cfi::posY, reco::SuperCluster::rawEnergy(), reco::SuperCluster::setEtaWidth(), reco::SuperCluster::setPhiWidth(), reco::SuperCluster::setPreshowerEnergy(), reco::SuperCluster::setSeed(), HLT_FULL_cff::superClusters, and trackerHitRTTI::vector.
◆ fetchCandidateCollection()
◆ produce()
Definition at line 198 of file PFPhotonTranslator.cc.
202 auto basicClusters_p = std::make_unique<reco::BasicClusterCollection>();
204 auto psClusters_p = std::make_unique<reco::PreshowerClusterCollection>();
215 outputSuperClusterCollection.clear();
216 outputOneLegConversionCollection.clear();
217 outputPhotonCoreCollection.clear();
261 unsigned iconv1leg = 0;
262 unsigned iconv2leg = 0;
264 for (
unsigned i = 0;
i < ncand; ++
i) {
269 if (
cand.mva_nothing_gamma() > 0.001)
275 if (!
cand.photonExtraRef()->conversionRef().empty()) {
279 for (
unsigned int iconv = 0; iconv < doubleLegConvColl.
size(); iconv++) {
280 pfConv_[iconv2leg].push_back(doubleLegConvColl[iconv]);
288 const std::vector<reco::TrackRef> &singleLegConvColl =
cand.photonExtraRef()->singleLegConvTrackRef();
289 const std::vector<float> &singleLegConvCollMva =
cand.photonExtraRef()->singleLegConvMva();
293 if (!singleLegConvColl.empty()) {
298 for (
unsigned int itk = 0; itk < singleLegConvColl.size(); itk++) {
317 pfClusters_.push_back(std::vector<const reco::PFCluster *>());
327 for (reco::PhotonCollection::const_iterator gamIter = egPhotons->begin(); gamIter != egPhotons->end(); ++gamIter) {
328 if (
cand.superClusterRef() == gamIter->superCluster()) {
337 for (
unsigned iele = 0; iele <
cand.elementsInBlocks().size(); ++iele) {
341 unsigned elementIndex =
cand.elementsInBlocks()[iele].second;
400 auto superClusters_p = std::make_unique<reco::SuperClusterCollection>(outputSuperClusterCollection);
417 auto SingleLeg_p = std::make_unique<reco::ConversionCollection>(outputOneLegConversionCollection);
442 auto photonCores_p = std::make_unique<reco::PhotonCoreCollection>(outputPhotonCoreCollection);
478 bool validVertex =
true;
481 edm::LogWarning(
"PhotonProducer") <<
"Error! Can't get the product primary Vertex Collection "
References reco::PFBlockElement::ECAL, bookConverter::elements, reco::PFCandidate::gamma, edm::EventSetup::getData(), mps_fire::i, iEvent, edm::Ref< C, T, F >::isNull(), electronProducer_cff::isolationValues, edm::HandleBase::isValid(), dqmiolumiharvest::j, eostools::move(), gedPhotons_cfi::outputPhotonCollection, zmumugammaAnalyzer_cfi::pfCandidates, edm::Handle< T >::product(), reco::PFBlockElement::PS1, reco::PFBlockElement::PS2, edm::RefVector< C, T, F >::size(), mps_update::status, reco::PFBlockElement::type(), and spclusmultinvestigator_cfi::vertexCollection.
◆ barrelEcalHits_
◆ basicClusterPtr_
◆ basicClusters_
◆ CandidatePtr_
◆ conv1legPFCandidateIndex_
std::vector<int> PFPhotonTranslator::conv1legPFCandidateIndex_ |
|
private |
◆ conv2legPFCandidateIndex_
std::vector<int> PFPhotonTranslator::conv2legPFCandidateIndex_ |
|
private |
◆ ecalMustacheSCParametersToken_
◆ EGPhotonCollection_
std::string PFPhotonTranslator::EGPhotonCollection_ |
|
private |
◆ egPhotonRef_
◆ egSCRef_
◆ emptyIsOk_
bool PFPhotonTranslator::emptyIsOk_ |
|
private |
◆ endcapEcalHits_
◆ energyRegression_
std::vector<float> PFPhotonTranslator::energyRegression_ |
|
private |
◆ energyRegressionError_
std::vector<float> PFPhotonTranslator::energyRegressionError_ |
|
private |
◆ hcalTowers_
◆ hOverEConeSize_
double PFPhotonTranslator::hOverEConeSize_ |
|
private |
◆ inputTagIsoVals_
◆ inputTagPFCandidates_
◆ mustacheSCParams_
◆ PFBasicClusterCollection_
std::string PFPhotonTranslator::PFBasicClusterCollection_ |
|
private |
◆ pfClusters_
std::vector<std::vector<const reco::PFCluster *> > PFPhotonTranslator::pfClusters_ |
|
private |
◆ pfConv_
◆ PFConversionCollection_
std::string PFPhotonTranslator::PFConversionCollection_ |
|
private |
◆ PFPhotonCollection_
std::string PFPhotonTranslator::PFPhotonCollection_ |
|
private |
◆ PFPhotonCoreCollection_
std::string PFPhotonTranslator::PFPhotonCoreCollection_ |
|
private |
◆ pfPhotonMva_
std::vector<float> PFPhotonTranslator::pfPhotonMva_ |
|
private |
◆ PFPreshowerClusterCollection_
std::string PFPhotonTranslator::PFPreshowerClusterCollection_ |
|
private |
◆ pfSingleLegConv_
std::vector<std::vector<reco::TrackRef> > PFPhotonTranslator::pfSingleLegConv_ |
|
private |
◆ pfSingleLegConvMva_
std::vector<std::vector<float> > PFPhotonTranslator::pfSingleLegConvMva_ |
|
private |
◆ PFSuperClusterCollection_
std::string PFPhotonTranslator::PFSuperClusterCollection_ |
|
private |
◆ photPFCandidateIndex_
std::vector<int> PFPhotonTranslator::photPFCandidateIndex_ |
|
private |
◆ preshowerClusterPtr_
◆ preshowerClusters_
◆ superClusters_
◆ theCaloGeom_
◆ theCaloTopo_
◆ vertexProducer_
std::string PFPhotonTranslator::vertexProducer_ |
|
private |
std::string PFPreshowerClusterCollection_
std::string EGPhotonCollection_
void setPFlowPhoton(const bool prov)
set the provenance
void setSuperCluster(const reco::SuperClusterRef &r)
set reference to SuperCluster
T const * product() const
std::vector< float > energyRegressionError_
bool isNull() const
Checks for null.
edm::InputTag hcalTowers_
std::vector< Vertex > VertexCollection
collection of Vertex objects
std::string PFConversionCollection_
std::vector< reco::PreshowerClusterCollection > preshowerClusters_
std::vector< reco::SuperClusterCollection > superClusters_
void addConversion(const reco::ConversionRef &r)
add single ConversionRef to the vector of Refs
bool fetchCandidateCollection(edm::Handle< reco::PFCandidateCollection > &c, const edm::InputTag &tag, const edm::Event &iEvent) const
std::vector< std::vector< float > > pfSingleLegConvMva_
std::vector< int > conv2legPFCandidateIndex_
const reco::PFCandidate & correspondingDaughterCandidate(const reco::PFCandidate &cand, const reco::PFBlockElement &pfbe) const
const ElementsInBlocks & elementsInBlocks() const
Log< level::Warning, false > LogWarning
std::string PFPhotonCollection_
std::vector< Conversion > ConversionCollection
collectin of Conversion objects
std::string vertexProducer_
std::vector< SuperCluster > SuperClusterCollection
collection of SuperCluser objectr
void createPreshowerCluster(const reco::PFBlockElement &PFBE, reco::PreshowerClusterCollection &preshowerClusters, unsigned plane) const
edm::InputTag endcapEcalHits_
void setStandardPhoton(const bool prov)
std::vector< int > photPFCandidateIndex_
edm::InputTag barrelEcalHits_
void addElectronPixelSeed(const reco::ElectronSeedRef &r)
set electron pixel seed ref
std::vector< std::vector< reco::TrackRef > > pfSingleLegConv_
std::vector< PreshowerCluster > PreshowerClusterCollection
collection of PreshowerCluster objects
std::vector< reco::BasicClusterCollection > basicClusters_
void addOneLegConversion(const reco::ConversionRef &r)
add single ConversionRef to the vector of Refs
std::vector< std::vector< const reco::PFCluster * > > pfClusters_
std::vector< BasicCluster > BasicClusterCollection
collection of BasicCluster objects
edm::InputTag inputTagPFCandidates_
std::vector< PhotonCore > PhotonCoreCollection
collectin of PhotonCore objects
bool exists(std::string const ¶meterName) const
checks if a parameter exists
XYZPointD XYZPoint
point in space with cartesian internal representation
std::vector< edm::InputTag > inputTagIsoVals_
void createBasicCluster(const reco::PFBlockElement &, reco::BasicClusterCollection &basicClusters, std::vector< const reco::PFCluster * > &, const reco::PFCandidate &coCandidate) const
std::vector< reco::CandidatePtr > CandidatePtr_
XYZVectorD XYZVector
spatial vector with cartesian internal representation
std::vector< reco::CaloClusterPtrVector > basicClusterPtr_
Log< level::Error, false > LogError
void createSuperClusters(const reco::PFCandidateCollection &, reco::SuperClusterCollection &superClusters) const
std::string PFSuperClusterCollection_
const EcalMustacheSCParameters * mustacheSCParams_
Abstract base class for a PFBlock element (track, cluster...)
bool getData(T &iHolder) const
void createPreshowerClusterPtrs(const edm::OrphanHandle< reco::PreshowerClusterCollection > &preshowerClustersHandle)
void createOneLegConversions(const edm::OrphanHandle< reco::SuperClusterCollection > &superClustersHandle, reco::ConversionCollection &oneLegConversions)
void createPhotonCores(const edm::OrphanHandle< reco::SuperClusterCollection > &superClustersHandle, const edm::OrphanHandle< reco::ConversionCollection > &oneLegConversionHandle, reco::PhotonCoreCollection &photonCores)
std::vector< float > pfPhotonMva_
std::vector< reco::SuperClusterRef > egSCRef_
math::XYZTLorentzVector LorentzVector
std::vector< reco::CaloClusterPtrVector > preshowerClusterPtr_
Particle flow cluster, see clustering algorithm in PFClusterAlgo.
int nClusterOutsideMustache
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< float > > XYZVectorF
spatial vector with cartesian internal representation
std::vector< reco::ConversionRefVector > pfConv_
T getParameter(std::string const &) const
void createPhotons(reco::VertexCollection &vertexCollection, edm::Handle< reco::PhotonCollection > &egPhotons, const edm::OrphanHandle< reco::PhotonCoreCollection > &photonCoresHandle, const IsolationValueMaps &isolationValues, reco::PhotonCollection &photons)
Particle reconstructed by the particle flow algorithm.
std::vector< Photon > PhotonCollection
collectin of Photon objects
float hcalDepth1TowerSumEt
void createBasicClusterPtrs(const edm::OrphanHandle< reco::BasicClusterCollection > &basicClustersHandle)
edm::ESGetToken< EcalMustacheSCParameters, EcalMustacheSCParametersRcd > ecalMustacheSCParametersToken_
float hcalDepth2TowerSumEt
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< float > > XYZPointF
point in space with cartesian internal representation
size_type size() const
Size of the RefVector.
std::vector< reco::PhotonRef > egPhotonRef_
void setParentSuperCluster(const reco::SuperClusterRef &r)
set reference to PFlow SuperCluster
std::string PFBasicClusterCollection_
std::vector< float > energyRegression_
std::vector< edm::Handle< edm::ValueMap< double > > > IsolationValueMaps
std::vector< int > conv1legPFCandidateIndex_
virtual const PFClusterRef & clusterRef() const
std::string PFPhotonCoreCollection_