#include <FBaseSimEvent.h>
Public Member Functions | |
void | addChargedTrack (int id) |
Add an id in the vector of charged tracks id's. More... | |
void | addParticles (const HepMC::GenEvent &hev) |
Add the particles and their vertices to the list. More... | |
void | addParticles (const reco::GenParticleCollection &myGenParticles) |
int | addSimTrack (const RawParticle *p, int iv, int ig=-1, const HepMC::GenVertex *ev=0) |
Add a new track to the Event and to the various lists. More... | |
int | addSimVertex (const XYZTLorentzVector &decayVertex, int im=-1, FSimVertexType::VertexType type=FSimVertexType::ANY) |
Add a new vertex to the Event and to the various lists. More... | |
int | chargedTrack (int id) const |
return "reconstructed" charged tracks index. More... | |
void | clear () |
clear the FBaseSimEvent content before the next event More... | |
const HepMC::GenParticle * | embdGenpart (int i) const |
return MC track with a given id More... | |
const SimTrack & | embdTrack (int i) const |
return embedded track with given id More... | |
const SimVertex & | embdVertex (int i) const |
return embedded vertex with given id More... | |
const FSimVertexType & | embdVertexType (int i) const |
return embedded vertex type with given id More... | |
FBaseSimEvent (const edm::ParameterSet &kine) | |
Default constructor. More... | |
FBaseSimEvent (const edm::ParameterSet &vtx, const edm::ParameterSet &kine, const RandomEngine *engine) | |
void | fill (const HepMC::GenEvent &hev) |
fill the FBaseSimEvent from the current HepMC::GenEvent More... | |
void | fill (const reco::GenParticleCollection &hev) |
fill the FBaseSimEvent from the current reco::GenParticleCollection More... | |
void | fill (const std::vector< SimTrack > &, const std::vector< SimVertex > &) |
fill the FBaseSimEvent from SimTrack's and SimVert'ices More... | |
const KineParticleFilter & | filter () const |
void | initializePdt (const HepPDT::ParticleDataTable *aPdt) |
Initialize the particle data table. More... | |
unsigned int | nChargedTracks () const |
Number of "reconstructed" charged tracks. More... | |
unsigned int | nGenParts () const |
Number of generator particles. More... | |
unsigned int | nTracks () const |
Number of tracks. More... | |
unsigned int | nVertices () const |
Number of vertices. More... | |
void | print () const |
print the FBaseSimEvent in an intelligible way More... | |
void | printMCTruth (const HepMC::GenEvent &hev) |
print the original MCTruth event More... | |
void | setBeamSpot (const math::XYZPoint &aBeamSpot) |
Set the beam spot position. More... | |
PrimaryVertexGenerator * | thePrimaryVertexGenerator () const |
const HepPDT::ParticleDataTable * | theTable () const |
Get the pointer to the particle data table. More... | |
FSimTrack & | track (int id) const |
Return track with given Id. More... | |
FSimVertex & | vertex (int id) const |
Return vertex with given Id. More... | |
FSimVertexType & | vertexType (int id) const |
Return vertex with given Id. More... | |
~FBaseSimEvent () | |
usual virtual destructor More... | |
Protected Member Functions | |
std::vector < HepMC::GenParticle * > * | genparts () const |
The pointer to the vector of GenParticle's. More... | |
std::vector< FSimTrack > * | tracks () const |
The pointer to the vector of FSimTrack's. More... | |
std::vector< FSimVertex > * | vertices () const |
The pointer to the vector of FSimVertex's. More... | |
Private Attributes | |
unsigned int | initialSize |
double | lateVertexPosition |
KineParticleFilter * | myFilter |
The particle filter. More... | |
unsigned int | nChargedParticleTracks |
unsigned int | nGenParticles |
unsigned int | nSimTracks |
unsigned int | nSimVertices |
const ParticleDataTable * | pdt |
const RandomEngine * | random |
double | sigmaVerteX |
double | sigmaVerteY |
double | sigmaVerteZ |
math::XYZPoint | theBeamSpot |
unsigned int | theChargedSize |
std::vector< unsigned > * | theChargedTracks |
FSimVertexTypeCollection * | theFSimVerticesType |
std::vector < HepMC::GenParticle * > * | theGenParticles |
unsigned int | theGenSize |
std::vector< FSimTrack > * | theSimTracks |
std::vector< FSimVertex > * | theSimVertices |
unsigned int | theTrackSize |
PrimaryVertexGenerator * | theVertexGenerator |
unsigned int | theVertexSize |
Definition at line 45 of file FBaseSimEvent.h.
FBaseSimEvent::FBaseSimEvent | ( | const edm::ParameterSet & | kine | ) |
Default constructor.
Definition at line 34 of file FBaseSimEvent.cc.
References initialSize, theBeamSpot, theChargedSize, theChargedTracks, theFSimVerticesType, theGenParticles, theGenSize, theSimTracks, theSimVertices, theTrackSize, theVertexGenerator, and theVertexSize.
FBaseSimEvent::FBaseSimEvent | ( | const edm::ParameterSet & | vtx, |
const edm::ParameterSet & | kine, | ||
const RandomEngine * | engine | ||
) |
Definition at line 72 of file FBaseSimEvent.cc.
References edm::ParameterSet::getParameter(), initialSize, lateVertexPosition, random, theBeamSpot, theChargedSize, theChargedTracks, theFSimVerticesType, theGenParticles, theGenSize, theSimTracks, theSimVertices, theTrackSize, theVertexGenerator, and theVertexSize.
FBaseSimEvent::~FBaseSimEvent | ( | ) |
usual virtual destructor
Definition at line 128 of file FBaseSimEvent.cc.
References myFilter, theChargedTracks, theFSimVerticesType, theGenParticles, theSimTracks, and theSimVertices.
void FBaseSimEvent::addChargedTrack | ( | int | id | ) |
Add an id in the vector of charged tracks id's.
Definition at line 961 of file FBaseSimEvent.cc.
References nChargedParticleTracks, theChargedSize, and theChargedTracks.
void FBaseSimEvent::addParticles | ( | const HepMC::GenEvent & | hev | ) |
Add the particles and their vertices to the list.
Some internal array to work with.
Definition at line 415 of file FBaseSimEvent.cc.
References abs, addSimTrack(), addSimVertex(), PrimaryVertexGenerator::beamSpot(), FSimVertexType::DECAY_VERTEX, PrimaryVertexGenerator::generate(), configurableAnalysis::GenParticle, lateVertexPosition, nGenParticles, nGenParts(), evf::evtn::offset(), L1TEmulatorMonitor_cff::p, position, FSimVertexType::PRIMARY_VERTEX, theBeamSpot, theGenParticles, theGenSize, theVertexGenerator, and vertex().
Referenced by fill().
void FBaseSimEvent::addParticles | ( | const reco::GenParticleCollection & | myGenParticles | ) |
Some internal array to work with.
Definition at line 628 of file FBaseSimEvent.cc.
References abs, addSimTrack(), addSimVertex(), PrimaryVertexGenerator::beamSpot(), reco::CompositeRefCandidateT< D >::daughter(), FSimVertexType::DECAY_VERTEX, reco::Candidate::end(), reco::LeafCandidate::energy(), PrimaryVertexGenerator::generate(), lateVertexPosition, reco::CompositeRefCandidateT< D >::mother(), nGenParticles, nGenParts(), nParticles, nTracks(), reco::CompositeRefCandidateT< D >::numberOfDaughters(), reco::CompositeRefCandidateT< D >::numberOfMothers(), evf::evtn::offset(), L1TEmulatorMonitor_cff::p, benchmark_cfg::pdgId, reco::Candidate::pdgId(), reco::LeafCandidate::pdgId(), position, FSimVertexType::PRIMARY_VERTEX, reco::LeafCandidate::px(), reco::LeafCandidate::py(), reco::LeafCandidate::pz(), reco::Candidate::status(), reco::LeafCandidate::status(), theBeamSpot, theVertexGenerator, vertex(), reco::Candidate::vx(), reco::LeafCandidate::vx(), reco::Candidate::vy(), reco::LeafCandidate::vy(), reco::Candidate::vz(), and reco::LeafCandidate::vz().
int FBaseSimEvent::addSimTrack | ( | const RawParticle * | p, |
int | iv, | ||
int | ig = -1 , |
||
const HepMC::GenVertex * | ev = 0 |
||
) |
Add a new track to the Event and to the various lists.
Definition at line 773 of file FBaseSimEvent.cc.
References FSimVertex::addDaughter(), FSimTrack::addDaughter(), SimTrack::genpartIndex(), RawParticle::momentum(), nSimTracks, dbtoconf::parent, RawParticle::PDGmass(), mathSSE::sqrt(), RawParticle::t(), theSimTracks, theTrackSize, track(), and vertex().
Referenced by addParticles(), fill(), MaterialEffects::interact(), PileUpSimulator::produce(), and TrajectoryManager::updateWithDaughters().
int FBaseSimEvent::addSimVertex | ( | const XYZTLorentzVector & | decayVertex, |
int | im = -1 , |
||
FSimVertexType::VertexType | type = FSimVertexType::ANY |
||
) |
Add a new vertex to the Event and to the various lists.
Definition at line 813 of file FBaseSimEvent.cc.
References nSimVertices, FSimTrack::setEndVertex(), theFSimVerticesType, theSimVertices, theVertexSize, and track().
Referenced by addParticles(), fill(), MaterialEffects::interact(), PileUpSimulator::produce(), TrajectoryManager::reconstruct(), and TrajectoryManager::updateWithDaughters().
int FBaseSimEvent::chargedTrack | ( | int | id | ) | const |
return "reconstructed" charged tracks index.
Definition at line 971 of file FBaseSimEvent.cc.
References nChargedParticleTracks, and theChargedTracks.
void FBaseSimEvent::clear | ( | void | ) |
clear the FBaseSimEvent content before the next event
Definition at line 951 of file FBaseSimEvent.cc.
References nChargedParticleTracks, nGenParticles, nSimTracks, and nSimVertices.
Referenced by python.Vispa.Views.WidgetView.WidgetView::closeEvent(), python.Vispa.Views.BoxDecayView.BoxDecayView::closeEvent(), fill(), python.Vispa.Share.FindAlgorithm.FindAlgorithm::findUsingFindDialog(), python.Vispa.Views.LineDecayView.LineDecayView::setDataObjects(), python.Vispa.Views.WidgetView.WidgetView::setDataObjects(), python.Vispa.Views.TreeView.TreeView::updateContent(), python.Vispa.Views.TableView.TableView::updateContent(), python.Vispa.Views.BoxDecayView.BoxDecayView::updateContent(), and python.Vispa.Views.PropertyView.PropertyView::updateContent().
const HepMC::GenParticle * FBaseSimEvent::embdGenpart | ( | int | i | ) | const |
return MC track with a given id
Definition at line 991 of file FBaseSimEvent.cc.
References i, and theGenParticles.
|
inline |
return embedded track with given id
Referenced by FSimEvent::load().
|
inline |
return embedded vertex with given id
Referenced by FSimEvent::load().
|
inline |
return embedded vertex type with given id
Referenced by FSimEvent::load().
void FBaseSimEvent::fill | ( | const HepMC::GenEvent & | hev | ) |
fill the FBaseSimEvent from the current HepMC::GenEvent
Definition at line 162 of file FBaseSimEvent.cc.
References addParticles(), and clear().
Referenced by FSimEvent::fill().
void FBaseSimEvent::fill | ( | const reco::GenParticleCollection & | hev | ) |
fill the FBaseSimEvent from the current reco::GenParticleCollection
Definition at line 181 of file FBaseSimEvent.cc.
References addParticles(), and clear().
void FBaseSimEvent::fill | ( | const std::vector< SimTrack > & | simTracks, |
const std::vector< SimVertex > & | simVertices | ||
) |
fill the FBaseSimEvent from SimTrack's and SimVert'ices
Definition at line 192 of file FBaseSimEvent.cc.
References abs, addSimTrack(), addSimVertex(), FSimTrack::charge(), clear(), SimTrack::genpartIndex(), BaseParticlePropagator::getSuccess(), lateVertexPosition, CoreSimTrack::momentum(), FSimTrack::momentum(), SimVertex::noParent(), FSimTrack::notYetToEndVertex(), nTracks(), SimVertex::parentIndex(), pos, CoreSimVertex::position(), FSimVertex::position(), position, FSimVertexType::PRIMARY_VERTEX, BaseParticlePropagator::propagateToEcalEntrance(), BaseParticlePropagator::propagateToHcalEntrance(), BaseParticlePropagator::propagateToPreshowerLayer1(), BaseParticlePropagator::propagateToPreshowerLayer2(), BaseParticlePropagator::propagateToVFcalEntrance(), RawParticle::setCharge(), FSimTrack::setEcal(), FSimTrack::setHcal(), FSimTrack::setLayer1(), FSimTrack::setLayer2(), FSimTrack::setVFcal(), matplotRender::t, track(), SimTrack::trackerSurfaceMomentum(), SimTrack::trackerSurfacePosition(), CoreSimTrack::type(), FSimTrack::vertex(), vertex(), RawParticle::vertex(), SimTrack::vertIndex(), x, detailsBasic3DVector::y, and detailsBasic3DVector::z.
|
inline |
Definition at line 146 of file FBaseSimEvent.h.
References myFilter.
Referenced by python.Vispa.Plugins.Browser.BrowserTabController.BrowserTabController::filter(), python.Vispa.Plugins.Browser.BrowserTabController.BrowserTabController::find(), TrajectoryManager::reconstruct(), python.Vispa.Plugins.Browser.BrowserTabController.BrowserTabController::setDataAccessor(), and python.Vispa.Plugins.Browser.BrowserTabController.BrowserTabController::switchCenterView().
|
inlineprotected |
The pointer to the vector of GenParticle's.
Definition at line 168 of file FBaseSimEvent.h.
References theGenParticles.
void FBaseSimEvent::initializePdt | ( | const HepPDT::ParticleDataTable * | aPdt | ) |
Initialize the particle data table.
Definition at line 148 of file FBaseSimEvent.cc.
References pdt.
Referenced by FamosManager::setupGeometryAndField().
|
inline |
Number of "reconstructed" charged tracks.
Definition at line 110 of file FBaseSimEvent.h.
References nChargedParticleTracks.
|
inline |
Number of generator particles.
Definition at line 105 of file FBaseSimEvent.h.
References nGenParticles.
Referenced by addParticles(), and FSimEvent::nGenParts().
|
inline |
Number of tracks.
Definition at line 95 of file FBaseSimEvent.h.
References nSimTracks.
Referenced by addParticles(), fill(), FSimEvent::nTracks(), and print().
|
inline |
Number of vertices.
Definition at line 100 of file FBaseSimEvent.h.
References nSimVertices.
Referenced by FSimEvent::nVertices(), and print().
void FBaseSimEvent::print | ( | void | ) | const |
print the FBaseSimEvent in an intelligible way
Definition at line 934 of file FBaseSimEvent.cc.
References gather_cfg::cout, i, nTracks(), nVertices(), track(), and vertexType().
Referenced by CalorimetryManager::reconstruct().
void FBaseSimEvent::printMCTruth | ( | const HepMC::GenEvent & | hev | ) |
print the original MCTruth event
Definition at line 839 of file FBaseSimEvent.cc.
References gather_cfg::cout, eta(), configurableAnalysis::GenParticle, gen::k, mergeVDriftHistosByStation::name, L1TEmulatorMonitor_cff::p, RecoTau_DiTaus_pt_20-420_cfg::ParticleID, and pdt.
|
inline |
Set the beam spot position.
Definition at line 151 of file FBaseSimEvent.h.
References theBeamSpot.
Referenced by FamosProducer::produce().
|
inline |
Definition at line 148 of file FBaseSimEvent.h.
References theVertexGenerator.
|
inline |
Get the pointer to the particle data table.
Definition at line 64 of file FBaseSimEvent.h.
References pdt.
Referenced by FSimTrack::FSimTrack().
|
inline |
Return track with given Id.
Referenced by addSimTrack(), addSimVertex(), fill(), MaterialEffects::interact(), FSimEvent::load(), TrajectoryManager::makeSinglePSimHit(), TrajectoryManager::moveAllDaughters(), print(), TrajectoryManager::propagateToCalorimeters(), CalorimetryManager::reconstruct(), TrajectoryManager::reconstruct(), and TrajectoryManager::updateWithDaughters().
|
inlineprotected |
The pointer to the vector of FSimTrack's.
Definition at line 158 of file FBaseSimEvent.h.
References theSimTracks.
|
inline |
Return vertex with given Id.
Referenced by addParticles(), addSimTrack(), fill(), and TrajectoryManager::updateWithDaughters().
|
inline |
Return vertex with given Id.
Referenced by print().
|
inlineprotected |
The pointer to the vector of FSimVertex's.
Definition at line 163 of file FBaseSimEvent.h.
References theSimVertices.
|
private |
Definition at line 192 of file FBaseSimEvent.h.
Referenced by FBaseSimEvent().
|
private |
Definition at line 205 of file FBaseSimEvent.h.
Referenced by addParticles(), FBaseSimEvent(), and fill().
|
private |
The particle filter.
Definition at line 195 of file FBaseSimEvent.h.
Referenced by filter(), and ~FBaseSimEvent().
|
private |
Definition at line 186 of file FBaseSimEvent.h.
Referenced by addChargedTrack(), chargedTrack(), clear(), and nChargedTracks().
|
private |
Definition at line 185 of file FBaseSimEvent.h.
Referenced by addParticles(), clear(), and nGenParts().
|
private |
Definition at line 183 of file FBaseSimEvent.h.
Referenced by addSimTrack(), clear(), and nTracks().
|
private |
Definition at line 184 of file FBaseSimEvent.h.
Referenced by addSimVertex(), clear(), and nVertices().
|
private |
Definition at line 201 of file FBaseSimEvent.h.
Referenced by initializePdt(), printMCTruth(), and theTable().
|
private |
Definition at line 207 of file FBaseSimEvent.h.
Referenced by FBaseSimEvent().
|
private |
Definition at line 197 of file FBaseSimEvent.h.
|
private |
Definition at line 198 of file FBaseSimEvent.h.
|
private |
Definition at line 199 of file FBaseSimEvent.h.
|
private |
Definition at line 204 of file FBaseSimEvent.h.
Referenced by addParticles(), FBaseSimEvent(), and setBeamSpot().
|
private |
Definition at line 191 of file FBaseSimEvent.h.
Referenced by addChargedTrack(), and FBaseSimEvent().
|
private |
Definition at line 181 of file FBaseSimEvent.h.
Referenced by addChargedTrack(), chargedTrack(), FBaseSimEvent(), and ~FBaseSimEvent().
|
private |
Definition at line 178 of file FBaseSimEvent.h.
Referenced by addSimVertex(), FBaseSimEvent(), and ~FBaseSimEvent().
|
private |
Definition at line 179 of file FBaseSimEvent.h.
Referenced by addParticles(), embdGenpart(), FBaseSimEvent(), genparts(), and ~FBaseSimEvent().
|
private |
Definition at line 190 of file FBaseSimEvent.h.
Referenced by addParticles(), and FBaseSimEvent().
|
private |
Definition at line 176 of file FBaseSimEvent.h.
Referenced by addSimTrack(), FBaseSimEvent(), tracks(), and ~FBaseSimEvent().
|
private |
Definition at line 177 of file FBaseSimEvent.h.
Referenced by addSimVertex(), FBaseSimEvent(), vertices(), and ~FBaseSimEvent().
|
private |
Definition at line 188 of file FBaseSimEvent.h.
Referenced by addSimTrack(), and FBaseSimEvent().
|
private |
Definition at line 203 of file FBaseSimEvent.h.
Referenced by addParticles(), FBaseSimEvent(), and thePrimaryVertexGenerator().
|
private |
Definition at line 189 of file FBaseSimEvent.h.
Referenced by addSimVertex(), and FBaseSimEvent().