FCCAnalyses
Loading...
Searching...
No Matches
ReconstructedParticleSource.h
Go to the documentation of this file.
1#ifndef ANALYZERS_SOURCE_RECONSTRUCTED_PARTICLE_H
2#define ANALYZERS_SOURCE_RECONSTRUCTED_PARTICLE_H
3
4// ROOT
5#include "ROOT/RVec.hxx"
6
7// EDM4hep
8#include "edm4hep/RecoMCParticleLinkCollection.h"
9#include "edm4hep/ReconstructedParticleCollection.h"
10
11namespace FCCAnalyses ::PodioSource ::ReconstructedParticle {
12// -------------------- Selectors -----------------------------------------
13
18struct selPDG {
19 const int m_pdg;
25 explicit selPDG(const int pdgID);
33 edm4hep::ReconstructedParticleCollection
34 operator()(const edm4hep::RecoMCParticleLinkCollection &inLinkColl);
35};
36
41struct selAbsPDG {
42 const int m_absPdg;
48 explicit selAbsPDG(const int pdgID);
57 edm4hep::ReconstructedParticleCollection
58 operator()(const edm4hep::RecoMCParticleLinkCollection &inLinkColl);
59};
60
65struct selPt {
66 const float m_minPt;
72 explicit selPt(float minPt);
79 edm4hep::ReconstructedParticleCollection
80 operator()(const edm4hep::ReconstructedParticleCollection &inColl);
81};
82
86struct selUpTo {
87 const size_t m_size;
93 explicit selUpTo(const size_t size);
100 edm4hep::ReconstructedParticleCollection
101 operator()(const edm4hep::ReconstructedParticleCollection &inColl);
102};
103
109 const int m_status;
115 explicit selGenStatus(const int status);
122 edm4hep::ReconstructedParticleCollection
123 operator()(const edm4hep::RecoMCParticleLinkCollection &inLinkColl);
124};
125
126// -------------------- Getters -------------------------------------------
127
134ROOT::VecOps::RVec<float>
135getP(const edm4hep::ReconstructedParticleCollection &inColl);
136
143ROOT::VecOps::RVec<float>
144getPt(const edm4hep::ReconstructedParticleCollection &inColl);
145
152ROOT::VecOps::RVec<float>
153getY(const edm4hep::ReconstructedParticleCollection &inColl);
154
161ROOT::VecOps::RVec<float>
162getE(const edm4hep::ReconstructedParticleCollection &inColl);
163
170ROOT::VecOps::RVec<float>
171getMass(const edm4hep::ReconstructedParticleCollection &inColl);
172
179ROOT::VecOps::RVec<float>
180getCharge(const edm4hep::ReconstructedParticleCollection &inColl);
181
182// -------------------- Transformers --------------------------------------
183
190edm4hep::ReconstructedParticleCollection
191sortByPt(const edm4hep::ReconstructedParticleCollection &inColl);
192
206edm4hep::ReconstructedParticleCollection
207remove(const edm4hep::ReconstructedParticleCollection &inColl,
208 const edm4hep::ReconstructedParticle &inPartToBeRemoved,
209 const bool matching = false);
210
225edm4hep::ReconstructedParticleCollection
226remove(const edm4hep::ReconstructedParticleCollection &inColl,
227 const edm4hep::ReconstructedParticleCollection &inPartsToBeRemoved,
228 const bool matching = false);
229
237edm4hep::ReconstructedParticleCollection
238merge(const edm4hep::ReconstructedParticleCollection &inColl1,
239 const edm4hep::ReconstructedParticleCollection &inColl2);
240
247 const float m_resonanceMass;
253 explicit resonanceBuilder(float resonanceMass);
260 edm4hep::ReconstructedParticleCollection
261 operator()(const edm4hep::ReconstructedParticleCollection &inColl);
262};
263
269 const float m_sqrts;
275 explicit recoilBuilder(float sqrts);
282 edm4hep::ReconstructedParticleCollection
283 operator()(const edm4hep::ReconstructedParticleCollection &inColl);
284};
285
286} // namespace FCCAnalyses::PodioSource::ReconstructedParticle
287
288// namespace recoParticle = FCCAnalyses::PodioSource::ReconstructedParticle;
289
290#endif /* ANALYZERS_SOURCE_RECONSTRUCTED_PARTICLE_H */
Definition ReconstructedParticleSource.h:11
edm4hep::ReconstructedParticleCollection merge(const edm4hep::ReconstructedParticleCollection &inColl1, const edm4hep::ReconstructedParticleCollection &inColl2)
Merge two particle collections together.
Definition ReconstructedParticleSource.cc:301
edm4hep::ReconstructedParticleCollection sortByPt(const edm4hep::ReconstructedParticleCollection &inColl)
Sort input particles by pT.
Definition ReconstructedParticleSource.cc:195
ROOT::VecOps::RVec< float > getPt(const edm4hep::ReconstructedParticleCollection &inColl)
Get transverse momenta (pT) of the input particles.
Definition ReconstructedParticleSource.cc:134
ROOT::VecOps::RVec< float > getP(const edm4hep::ReconstructedParticleCollection &inColl)
Get momenta of the input reconstructed particles.
Definition ReconstructedParticleSource.cc:122
ROOT::VecOps::RVec< float > getY(const edm4hep::ReconstructedParticleCollection &inColl)
Get rapidity (y) of the input reconstructed particles.
Definition ReconstructedParticleSource.cc:147
edm4hep::ReconstructedParticleCollection remove(const edm4hep::ReconstructedParticleCollection &inColl, const edm4hep::ReconstructedParticle &inPartToBeRemoved, const bool matching=false)
Remove a particle from a collection.
Definition ReconstructedParticleSource.cc:218
ROOT::VecOps::RVec< float > getE(const edm4hep::ReconstructedParticleCollection &inColl)
Get energy (E) of the input reconstructed particles.
Definition ReconstructedParticleSource.cc:160
ROOT::VecOps::RVec< float > getMass(const edm4hep::ReconstructedParticleCollection &inColl)
Get mass of the input reconstructed particles.
Definition ReconstructedParticleSource.cc:172
ROOT::VecOps::RVec< float > getCharge(const edm4hep::ReconstructedParticleCollection &inColl)
Get charge of the input reconstructed particles.
Definition ReconstructedParticleSource.cc:183
FCC analyzers collection.
Definition Algorithms.h:15
edm4hep::ReconstructedParticleCollection operator()(const edm4hep::ReconstructedParticleCollection &inColl)
Operator over input collection of resonances.
Definition ReconstructedParticleSource.cc:380
const float m_sqrts
Definition ReconstructedParticleSource.h:269
recoilBuilder(float sqrts)
Constructor.
Definition ReconstructedParticleSource.cc:373
edm4hep::ReconstructedParticleCollection operator()(const edm4hep::ReconstructedParticleCollection &inColl)
Operator over input particle collection.
Definition ReconstructedParticleSource.cc:326
resonanceBuilder(float resonanceMass)
Constructor.
Definition ReconstructedParticleSource.cc:318
const float m_resonanceMass
Definition ReconstructedParticleSource.h:247
const int m_absPdg
Definition ReconstructedParticleSource.h:42
edm4hep::ReconstructedParticleCollection operator()(const edm4hep::RecoMCParticleLinkCollection &inLinkColl)
Operator over the input link collection.
Definition ReconstructedParticleSource.cc:47
selAbsPDG(const int pdgID)
Constructor.
Definition ReconstructedParticleSource.cc:39
const int m_status
Definition ReconstructedParticleSource.h:109
selGenStatus(const int status)
Constructor.
Definition ReconstructedParticleSource.cc:102
edm4hep::ReconstructedParticleCollection operator()(const edm4hep::RecoMCParticleLinkCollection &inLinkColl)
Operator over input link collection.
Definition ReconstructedParticleSource.cc:104
const int m_pdg
Definition ReconstructedParticleSource.h:19
selPDG(const int pdgID)
Constructor.
Definition ReconstructedParticleSource.cc:19
edm4hep::ReconstructedParticleCollection operator()(const edm4hep::RecoMCParticleLinkCollection &inLinkColl)
Operator over the input link collection.
Definition ReconstructedParticleSource.cc:22
selPt(float minPt)
Constructor.
Definition ReconstructedParticleSource.cc:62
const float m_minPt
Definition ReconstructedParticleSource.h:66
edm4hep::ReconstructedParticleCollection operator()(const edm4hep::ReconstructedParticleCollection &inColl)
Operator over input link collection.
Definition ReconstructedParticleSource.cc:70
selUpTo(const size_t size)
Constructor.
Definition ReconstructedParticleSource.cc:84
edm4hep::ReconstructedParticleCollection operator()(const edm4hep::ReconstructedParticleCollection &inColl)
Operator over input link collection.
Definition ReconstructedParticleSource.cc:87
const size_t m_size
Definition ReconstructedParticleSource.h:87