62 HepMC::GenVertex::particles_in_const_iterator,
63 HepMC::GenVertex::particles_in_const_iterator,
64 HepMC::GenVertex::particles_out_const_iterator,
65 HepMC::GenVertex::particles_out_const_iterator
92 std::cout << std::endl <<
"History for vertex #" <<
index <<
" : " << std::endl;
101 for (std::size_t hindex=0; hindex<simParticles.size(); hindex++)
103 std::cout <<
" simParticles [" << hindex <<
"] : "
112 if ( !simVertexes.empty() )
114 for (std::size_t hindex=0; hindex<simVertexes.size(); hindex++)
116 std::cout <<
" simVertex [" << hindex <<
"] : "
118 simVertexes[hindex]->sourceTracks(),
119 simVertexes[hindex]->daughterTracks()
125 std::cout <<
" simVertex no found" << std::endl;
131 for (std::size_t hindex=0; hindex<
genParticles.size(); hindex++)
133 std::cout <<
" genParticles [" << hindex <<
"] : "
142 if ( !genVertexes.empty() )
144 for (std::size_t hindex=0; hindex<genVertexes.size(); hindex++)
146 std::cout <<
" genVertex [" << hindex <<
"] : "
148 genVertexes[hindex]->particles_in_const_begin(),
149 genVertexes[hindex]->particles_in_const_end(),
150 genVertexes[hindex]->particles_out_const_begin(),
151 genVertexes[hindex]->particles_out_const_end()
157 std::cout <<
" genVertex no found" << std::endl;
160 std::cout <<
" fake vertex" << std::endl;
186 std::ostringstream vDescription;
190 if (particleType.isValid())
192 pid =
pdt_->particle(particleType);
194 vDescription << pid->name();
196 vDescription <<
pdgId;
199 vDescription <<
pdgId;
201 return vDescription.str();
212 std::ostringstream vDescription;
214 for (std::size_t
j = 0;
j < in.
size();
j++)
216 if (!
j) vDescription <<
"(";
220 if (particleType.isValid())
222 pid =
pdt_->particle(particleType);
224 vDescription << pid->name();
226 vDescription << in[
j]->pdgId();
229 vDescription << in[
j]->pdgId();
231 if (
j == in.
size() - 1) vDescription <<
")";
232 else vDescription <<
",";
235 vDescription <<
"->";
237 for (std::size_t
j = 0;
j < out.
size();
j++)
239 if (!
j) vDescription <<
"(";
243 if (particleType.isValid())
245 pid =
pdt_->particle(particleType);
247 vDescription << pid->name();
249 vDescription << out[
j]->pdgId();
252 vDescription << out[
j]->pdgId();
254 if (
j == out.
size() - 1) vDescription <<
")";
255 else vDescription <<
",";
258 return vDescription.str();
263 HepMC::GenVertex::particles_in_const_iterator in_begin,
264 HepMC::GenVertex::particles_in_const_iterator in_end,
265 HepMC::GenVertex::particles_out_const_iterator out_begin,
266 HepMC::GenVertex::particles_out_const_iterator out_end
271 std::ostringstream vDescription;
275 HepMC::GenVertex::particles_in_const_iterator
in, itmp;
277 for (in = in_begin; in != in_end; in++, j++)
279 if (!j) vDescription <<
"(";
287 vDescription << pid->name();
289 vDescription << (*in)->pdg_id();
292 vDescription << (*in)->pdg_id();
296 if (++itmp == in_end) vDescription <<
")";
297 else vDescription <<
",";
300 vDescription <<
"->";
303 HepMC::GenVertex::particles_out_const_iterator
out, otmp;
305 for (out = out_begin; out != out_end; out++, j++)
307 if (!j) vDescription <<
"(";
315 vDescription << pid->name();
317 vDescription << (*out)->pdg_id();
320 vDescription << (*out)->pdg_id();
324 if (++otmp == out_end) vDescription <<
")";
325 else vDescription <<
",";
328 return vDescription.str();
This class traces the simulated and generated history of a given track.
T getUntrackedParameter(std::string const &, T const &) const
edm::InputTag vertexProducer_
VertexHistory const & history() const
Returns a reference to the vertex history used in the classification.
#define DEFINE_FWK_MODULE(type)
std::string vertexString(const TrackingParticleRefVector &, const TrackingParticleRefVector &) const
SimVertexTrail const & simVertexTrail() const
Return all the simulated vertices in the history.
Get track history and classify it in function of their .
virtual void beginRun(const edm::Run &, const edm::EventSetup &) override
virtual void analyze(const edm::Event &, const edm::EventSetup &) override
void getData(T &iHolder) const
std::vector< const HepMC::GenParticle * > GenParticleTrail
HepMC::GenParticle trail type.
VertexClassifier classifier_
edm::ESHandle< ParticleDataTable > pdt_
std::string particleString(int) const
bool is(Category category) const
Returns track flag for a given category.
std::vector< const HepMC::GenVertex * > GenVertexTrail
GenVertex trail type.
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
HepPDT::ParticleData ParticleData
VertexHistoryAnalyzer(const edm::ParameterSet &)
SimParticleTrail const & simParticleTrail() const
Return all the simulated particle in the history.
VertexClassifier const & evaluate(reco::VertexBaseRef const &)
Classify the RecoVertex in categories.
size_type size() const
Size of the RefVector.
virtual void newEvent(edm::Event const &, edm::EventSetup const &)
Pre-process event information (for accessing reconstraction information)
GenVertexTrail const & genVertexTrail() const
Return all generated vertex in the history.
std::vector< TrackingVertexRef > SimVertexTrail
SimVertex trail type.
GenParticleTrail const & genParticleTrail() const
Return all generated particle (HepMC::GenParticle) in the history.
std::vector< TrackingParticleRef > SimParticleTrail
SimParticle trail type.
virtual void beginJob() override