src
PhysicsTools
JetMCAlgos
src
Pythia6PartonSelector.cc
Go to the documentation of this file.
1
7
#include "
PhysicsTools/JetMCAlgos/interface/Pythia6PartonSelector.h
"
8
#include "
PhysicsTools/JetMCUtils/interface/CandMCTag.h
"
9
10
Pythia6PartonSelector::Pythia6PartonSelector
() {}
11
12
Pythia6PartonSelector::~Pythia6PartonSelector
() {}
13
14
void
Pythia6PartonSelector::run
(
const
edm::Handle<reco::GenParticleCollection>
&
particles
,
15
std::unique_ptr<reco::GenParticleRefVector>&
partons
) {
16
// loop over particles and select partons
17
for
(reco::GenParticleCollection::const_iterator
it
=
particles
->begin();
it
!=
particles
->end(); ++
it
) {
18
if
(
it
->status() != 2)
19
continue
;
// only accept status==2 particles
20
if
(!
CandMCTagUtils::isParton
(*
it
))
21
continue
;
// skip particle if not a parton
22
23
partons
->push_back(
reco::GenParticleRef
(
particles
,
it
-
particles
->begin()));
24
}
25
26
return
;
27
}
ecalTrigSettings_cff.particles
particles
Definition:
ecalTrigSettings_cff.py:11
edm::Ref< GenParticleCollection >
edm::Handle< reco::GenParticleCollection >
CandMCTag.h
Pythia6PartonSelector.h
Pythia6PartonSelector::~Pythia6PartonSelector
~Pythia6PartonSelector() override
Definition:
Pythia6PartonSelector.cc:12
dqmAnalyzer_cff.partons
partons
Definition:
dqmAnalyzer_cff.py:25
Pythia6PartonSelector::run
void run(const edm::Handle< reco::GenParticleCollection > &particles, std::unique_ptr< reco::GenParticleRefVector > &partons) override
Definition:
Pythia6PartonSelector.cc:14
Pythia6PartonSelector::Pythia6PartonSelector
Pythia6PartonSelector()
Definition:
Pythia6PartonSelector.cc:10
CandMCTagUtils::isParton
bool isParton(const reco::Candidate &c)
Definition:
CandMCTag.cc:46
ALPAKA_ACCELERATOR_NAMESPACE::vertexFinder::it
auto & it
Definition:
splitVertices.h:45
Generated for CMSSW Reference Manual by
1.8.14