18 #ifndef SimDataFormats_Associations_TTStubAssociationMap_h 19 #define SimDataFormats_Associations_TTStubAssociationMap_h 44 using MapTPToVecStub = std::map<TrackingParticlePtr, std::vector<TTStubRefT<T>>>;
119 template <
typename T>
121 template <
typename T>
126 template <
typename T>
132 template <
typename T>
136 template <
typename T>
138 if (stubToTrackingParticleMap_.find(aStub) != stubToTrackingParticleMap_.end()) {
139 return stubToTrackingParticleMap_.find(aStub)->second;
141 return nullTrackingParticlePtr_;
145 template <
typename T>
147 if (trackingParticleToStubVectorMap_.find(aTrackingParticle) != trackingParticleToStubVectorMap_.end()) {
148 return trackingParticleToStubVectorMap_.find(aTrackingParticle)->second;
150 return nullVecStubRef_;
155 template <
typename T>
158 if ((this->findTrackingParticlePtr(aStub)).isNull())
164 template <
typename T>
167 if (this->isGenuine(aStub))
170 if (this->isUnknown(aStub))
176 template <
typename T>
181 if (theClusterAssociationMap_.isNull()) {
185 if (theClusterAssociationMap_->isUnknown(aStub->clusterRef(0)) &&
186 theClusterAssociationMap_->isUnknown(aStub->clusterRef(1)))
TTStubAssociationMap()
Constructors.
MapTPToVecStub< T > trackingParticleToStubVectorMap_
const TrackingParticlePtr & findTrackingParticlePtr(TTStubRefT< T > aStub) const
Operations.
std::map< TTStubRefT< T >, TrackingParticlePtr > MapStubToTP
NOTE: this is needed even if it seems not.
bool isCombinatoric(TTStubRefT< T > aStub) const
bool isUnknown(TTStubRefT< T > aStub) const
std::map< TrackingParticlePtr, std::vector< TTStubRefT< T > >> MapTPToVecStub
void setTTClusterAssociationMap(edm::RefProd< TTClusterAssociationMap< T >> aCluAssoMap)
Set cluster <-> truth association object.
Stores association of Truth Particles (TP) to L1 Track-Trigger Clusters.
edm::RefProd< TTClusterAssociationMap< T > > theClusterAssociationMap_
static const std::vector< TTStubRefT< T > > nullVecStubRef_
const std::vector< TTStubRefT< T > > & findTTStubRefs(TrackingParticlePtr aTrackingParticle) const
~TTStubAssociationMap()
Destructor.
void setTrackingParticleToTTStubsMap(const MapTPToVecStub< T > &aMap)
static const TrackingParticlePtr nullTrackingParticlePtr_
Close class.
MapStubToTP< T > stubToTrackingParticleMap_
Data members.
void setTTStubToTrackingParticleMap(const MapStubToTP< T > &aMap)
bool isGenuine(TTStubRefT< T > aStub) const
MC truth.
const MapStubToTP< T > & getTTStubToTrackingParticleMap() const
Get/set stub <-> truth association maps.
const MapTPToVecStub< T > & getTrackingParticleToTTStubsMap() const
Stores association of Truth Particles (TP) to L1 Track-Trigger Stubs.