13 typedef std::vector<reco::CandidatePtr>
CandPtrs;
21 int translateTypeToAbsPdgId(
int type) {
43 std::vector<CandidatePtr>
flattenPiZeros(
const std::vector<RecoTauPiZero>::const_iterator& piZerosBegin,
44 const std::vector<RecoTauPiZero>::const_iterator& piZerosEnd) {
45 std::vector<CandidatePtr>
output;
47 for (std::vector<RecoTauPiZero>::const_iterator piZero = piZerosBegin; piZero != piZerosEnd; ++piZero) {
48 for (
size_t iDaughter = 0; iDaughter < piZero->numberOfDaughters(); ++iDaughter) {
55 std::vector<CandidatePtr>
flattenPiZeros(
const std::vector<RecoTauPiZero>& piZeros) {
65 pdgIds.reserve(particleIds.size());
66 for (
auto particleId : particleIds)
67 pdgIds.push_back(translateTypeToAbsPdgId(particleId));
74 return selectedPFCands;
78 const std::vector<int>&
pdgIds,
85 output.insert(
output.end(), selectedPFCands.begin(), selectedPFCands.end());
100 output.reserve(mus.size() + es.size() + chs.size());
std::vector< CandidatePtr > pfCandidatesByPdgId(const Jet &jet, int pdgId, bool sort=true)
std::vector< CandidatePtr > pfCandidates(const Jet &jet, int particleId, bool sort=true)
math::XYZPointF atECALEntrance(const reco::Candidate *part, double bField)
Base class for all types of Jets.
const math::XYZPointF & positionAtECALEntrance() const
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< float > > XYZPointF
point in space with cartesian internal representation
std::vector< CandidatePtr > pfChargedCands(const Jet &jet, bool sort=true)
Extract all non-neutral candidates from a PFJet.
double charge() const
get the MEASURED charge
std::vector< CandidatePtr > flattenPiZeros(const std::vector< RecoTauPiZero >::const_iterator &, const std::vector< RecoTauPiZero >::const_iterator &)
Flatten a list of pi zeros into a list of there constituent PFCandidates.
XYZTLorentzVectorD XYZTLorentzVector
Lorentz vector with cylindrical internal representation using pseudorapidity.
std::vector< reco::CandidatePtr > CandPtrs
RawParticle const & particle() const
The particle being propagated.
bool propagateToEcalEntrance(bool first=true)
edm::Ptr< Candidate > CandidatePtr
persistent reference to an object in a collection of Candidate objects
int getSuccess() const
Has propagation been performed and was barrel or endcap reached ?
Particle reconstructed by the particle flow algorithm.
std::vector< CandidatePtr > filterPFCandidates(const Iterator &begin, const Iterator &end, int pdgId, bool sort=true)
CandPtrs::iterator CandIter
std::vector< CandidatePtr > pfGammas(const Jet &jet, bool sort=true)
Extract all pfGammas from a PFJet.
const XYZTLorentzVector & vertex() const
the vertex fourvector