CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
MeasurementTrackerEvent Class Reference

#include <MeasurementTrackerEvent.h>

Public Types

using QualityFlags = MeasurementTracker::QualityFlags
 

Public Member Functions

const GeometricSearchTrackergeometricSearchTracker () const
 
const TrackerGeometrygeomTracker () const
 
MeasurementDetWithData idToDet (const DetId &id) const
 Previous MeasurementDetSystem interface. More...
 
const MeasurementTrackermeasurementTracker () const
 
 MeasurementTrackerEvent ()
 Dummy constructor used for I/O (even if it's a transient object) More...
 
 MeasurementTrackerEvent (const MeasurementTracker &tracker, const StMeasurementDetSet *strips, const PxMeasurementDetSet *pixels, const Phase2OTMeasurementDetSet *phase2OT, const VectorHitCollection *phase2OTVectorHits, const VectorHitCollection *phase2OTVectorHitsRej, const std::vector< bool > &stripClustersToSkip, const std::vector< bool > &pixelClustersToSkip, const std::vector< bool > &phase2OTClustersToSkip)
 Real constructor 1: with the full data (owned) More...
 
 MeasurementTrackerEvent (const MeasurementTrackerEvent &other)=delete
 
 MeasurementTrackerEvent (const MeasurementTrackerEvent &trackerEvent, const edm::ContainerMask< edmNew::DetSetVector< SiPixelCluster > > &phase2pixelClustersToSkip, const edm::ContainerMask< edmNew::DetSetVector< Phase2TrackerCluster1D > > &phase2OTClustersToSkip)
 
 MeasurementTrackerEvent (const MeasurementTrackerEvent &trackerEvent, const edm::ContainerMask< edmNew::DetSetVector< SiStripCluster > > &stripClustersToSkip, const edm::ContainerMask< edmNew::DetSetVector< SiPixelCluster > > &pixelClustersToSkip)
 Real constructor 2: with new cluster skips (checked) More...
 
 MeasurementTrackerEvent (MeasurementTrackerEvent &&other)
 
MeasurementTrackerEventoperator= (const MeasurementTrackerEvent &other)=delete
 
MeasurementTrackerEventoperator= (MeasurementTrackerEvent &&other)
 
const std::vector< bool > & phase2OTClustersToSkip () const
 
const Phase2OTMeasurementDetSetphase2OTData () const
 
const VectorHitCollectionphase2OTVectorHits () const
 
const VectorHitCollectionphase2OTVectorHitsRej () const
 
const std::vector< bool > & pixelClustersToSkip () const
 
const PxMeasurementDetSetpixelData () const
 
const std::vector< bool > & stripClustersToSkip () const
 
const StMeasurementDetSetstripData () const
 
 ~MeasurementTrackerEvent ()
 

Private Attributes

bool theOwner = false
 
std::vector< bool > thePhase2OTClustersToSkip
 
const Phase2OTMeasurementDetSetthePhase2OTData = nullptr
 
const VectorHitCollectionthePhase2OTVectorHits = nullptr
 
const VectorHitCollectionthePhase2OTVectorHitsRej = nullptr
 
std::vector< bool > thePixelClustersToSkip
 
const PxMeasurementDetSetthePixelData = nullptr
 
std::vector< bool > theStripClustersToSkip
 
const StMeasurementDetSettheStripData = nullptr
 
const MeasurementTrackertheTracker = nullptr
 

Detailed Description

Definition at line 16 of file MeasurementTrackerEvent.h.

Member Typedef Documentation

◆ QualityFlags

Definition at line 18 of file MeasurementTrackerEvent.h.

Constructor & Destructor Documentation

◆ MeasurementTrackerEvent() [1/6]

MeasurementTrackerEvent::MeasurementTrackerEvent ( )
inline

Dummy constructor used for I/O (even if it's a transient object)

Definition at line 21 of file MeasurementTrackerEvent.h.

21 {}

◆ ~MeasurementTrackerEvent()

MeasurementTrackerEvent::~MeasurementTrackerEvent ( )

Definition at line 4 of file MeasurementTrackerEvent.cc.

4  {
5  if (theOwner) {
6  //std::cout << "Deleting owned MT @" << this << " (strip data @ " << theStripData << ")" << std::endl;
7  delete theStripData;
8  theStripData = nullptr; // also sets to zero since sometimes the FWK seems
9  delete thePixelData;
10  thePixelData = nullptr; // to double-delete the same object (!!!)
11  delete thePhase2OTData;
12  thePhase2OTData = nullptr; // to double-delete the same object (!!!)
13  }
14 }

References theOwner, thePhase2OTData, thePixelData, and theStripData.

◆ MeasurementTrackerEvent() [2/6]

MeasurementTrackerEvent::MeasurementTrackerEvent ( const MeasurementTracker tracker,
const StMeasurementDetSet strips,
const PxMeasurementDetSet pixels,
const Phase2OTMeasurementDetSet phase2OT,
const VectorHitCollection phase2OTVectorHits,
const VectorHitCollection phase2OTVectorHitsRej,
const std::vector< bool > &  stripClustersToSkip,
const std::vector< bool > &  pixelClustersToSkip,
const std::vector< bool > &  phase2OTClustersToSkip 
)
inline

◆ MeasurementTrackerEvent() [3/6]

MeasurementTrackerEvent::MeasurementTrackerEvent ( const MeasurementTrackerEvent trackerEvent,
const edm::ContainerMask< edmNew::DetSetVector< SiStripCluster > > &  stripClustersToSkip,
const edm::ContainerMask< edmNew::DetSetVector< SiPixelCluster > > &  pixelClustersToSkip 
)

Real constructor 2: with new cluster skips (checked)

Definition at line 42 of file MeasurementTrackerEvent.cc.

46  : theTracker(trackerEvent.theTracker),
47  theStripData(trackerEvent.theStripData),
48  thePixelData(trackerEvent.thePixelData),
49  thePhase2OTData(nullptr),
50  thePhase2OTVectorHits(nullptr),
51  thePhase2OTVectorHitsRej(nullptr),
52  theOwner(false) {
53  //std::cout << "Creatign non-owned MT @ " << this << " from @ " << & trackerEvent << " (strip data @ " << trackerEvent.theStripData << ")" << std::endl;
54  if (stripClustersToSkip.refProd().id() != theStripData->handle().id()) {
55  edm::LogError("ProductIdMismatch") << "The strip masking does not point to the strip collection of clusters: "
56  << stripClustersToSkip.refProd().id() << "!=" << theStripData->handle().id();
57  throw cms::Exception("Configuration")
58  << "The strip masking does not point to the strip collection of clusters: "
59  << stripClustersToSkip.refProd().id() << "!=" << theStripData->handle().id() << "\n";
60  }
61 
62  if (pixelClustersToSkip.refProd().id() != thePixelData->handle().id()) {
63  edm::LogError("ProductIdMismatch") << "The pixel masking does not point to the proper collection of clusters: "
64  << pixelClustersToSkip.refProd().id() << "!=" << thePixelData->handle().id();
65  throw cms::Exception("Configuration")
66  << "The pixel masking does not point to the proper collection of clusters: "
67  << pixelClustersToSkip.refProd().id() << "!=" << thePixelData->handle().id() << "\n";
68  }
69 
72 
75 }

References Exception, StMeasurementDetSet::handle(), PxMeasurementDetSet::handle(), edm::HandleBase::id(), pixelClustersToSkip(), stripClustersToSkip(), thePixelClustersToSkip, thePixelData, theStripClustersToSkip, and theStripData.

◆ MeasurementTrackerEvent() [4/6]

MeasurementTrackerEvent::MeasurementTrackerEvent ( const MeasurementTrackerEvent trackerEvent,
const edm::ContainerMask< edmNew::DetSetVector< SiPixelCluster > > &  phase2pixelClustersToSkip,
const edm::ContainerMask< edmNew::DetSetVector< Phase2TrackerCluster1D > > &  phase2OTClustersToSkip 
)

Definition at line 78 of file MeasurementTrackerEvent.cc.

82  : theTracker(trackerEvent.theTracker),
83  theStripData(nullptr),
84  thePixelData(trackerEvent.thePixelData),
85  thePhase2OTData(trackerEvent.thePhase2OTData),
88  theOwner(false) {
89  if (pixelClustersToSkip.refProd().id() != thePixelData->handle().id()) {
90  edm::LogError("ProductIdMismatch") << "The pixel masking does not point to the proper collection of clusters: "
91  << pixelClustersToSkip.refProd().id() << "!=" << thePixelData->handle().id();
92  throw cms::Exception("Configuration")
93  << "The pixel masking does not point to the proper collection of clusters: "
94  << pixelClustersToSkip.refProd().id() << "!=" << thePixelData->handle().id() << "\n";
95  }
96 
97  if (phase2OTClustersToSkip.refProd().id() != thePhase2OTData->handle().id()) {
98  edm::LogError("ProductIdMismatch") << "The pixel masking does not point to the proper collection of clusters: "
99  << pixelClustersToSkip.refProd().id() << "!=" << thePixelData->handle().id();
100  throw cms::Exception("Configuration")
101  << "The pixel masking does not point to the proper collection of clusters: "
102  << pixelClustersToSkip.refProd().id() << "!=" << thePixelData->handle().id() << "\n";
103  }
104 
107 
110 }

References Exception, PxMeasurementDetSet::handle(), Phase2OTMeasurementDetSet::handle(), edm::HandleBase::id(), phase2OTClustersToSkip(), pixelClustersToSkip(), thePhase2OTClustersToSkip, thePhase2OTData, thePixelClustersToSkip, and thePixelData.

◆ MeasurementTrackerEvent() [5/6]

MeasurementTrackerEvent::MeasurementTrackerEvent ( const MeasurementTrackerEvent other)
delete

◆ MeasurementTrackerEvent() [6/6]

MeasurementTrackerEvent::MeasurementTrackerEvent ( MeasurementTrackerEvent &&  other)

Definition at line 16 of file MeasurementTrackerEvent.cc.

16  {
17  theTracker = other.theTracker;
18  theStripData = other.theStripData;
19  thePixelData = other.thePixelData;
20  thePhase2OTData = other.thePhase2OTData;
21  thePhase2OTVectorHits = other.thePhase2OTVectorHits;
22  thePhase2OTVectorHitsRej = other.thePhase2OTVectorHitsRej;
23  theOwner = other.theOwner;
24  other.theOwner = false; // make sure to fully transfer the ownership
25  theStripClustersToSkip = std::move(other.theStripClustersToSkip);
26  thePixelClustersToSkip = std::move(other.thePixelClustersToSkip);
27 }

References eostools::move(), trackingPlots::other, theOwner, thePhase2OTData, thePhase2OTVectorHits, thePhase2OTVectorHitsRej, thePixelClustersToSkip, thePixelData, theStripClustersToSkip, theStripData, and theTracker.

Member Function Documentation

◆ geometricSearchTracker()

const GeometricSearchTracker* MeasurementTrackerEvent::geometricSearchTracker ( ) const
inline

◆ geomTracker()

const TrackerGeometry* MeasurementTrackerEvent::geomTracker ( ) const
inline

◆ idToDet()

MeasurementDetWithData MeasurementTrackerEvent::idToDet ( const DetId id) const
inline

◆ measurementTracker()

const MeasurementTracker& MeasurementTrackerEvent::measurementTracker ( ) const
inline

◆ operator=() [1/2]

MeasurementTrackerEvent& MeasurementTrackerEvent::operator= ( const MeasurementTrackerEvent other)
delete

◆ operator=() [2/2]

MeasurementTrackerEvent & MeasurementTrackerEvent::operator= ( MeasurementTrackerEvent &&  other)

Definition at line 28 of file MeasurementTrackerEvent.cc.

28  {
29  theTracker = other.theTracker;
30  theStripData = other.theStripData;
31  thePixelData = other.thePixelData;
32  thePhase2OTData = other.thePhase2OTData;
33  thePhase2OTVectorHits = other.thePhase2OTVectorHits;
34  thePhase2OTVectorHitsRej = other.thePhase2OTVectorHitsRej;
35  theOwner = other.theOwner;
36  other.theOwner = false; // make sure to fully transfer the ownership
37  theStripClustersToSkip = std::move(other.theStripClustersToSkip);
38  thePixelClustersToSkip = std::move(other.thePixelClustersToSkip);
39  return *this;
40 }

References eostools::move(), trackingPlots::other, theOwner, thePhase2OTData, thePhase2OTVectorHits, thePhase2OTVectorHitsRej, thePixelClustersToSkip, thePixelData, theStripClustersToSkip, theStripData, and theTracker.

◆ phase2OTClustersToSkip()

const std::vector<bool>& MeasurementTrackerEvent::phase2OTClustersToSkip ( ) const
inline

Definition at line 69 of file MeasurementTrackerEvent.h.

69 { return thePhase2OTClustersToSkip; }

References thePhase2OTClustersToSkip.

Referenced by MeasurementTrackerEvent().

◆ phase2OTData()

const Phase2OTMeasurementDetSet& MeasurementTrackerEvent::phase2OTData ( ) const
inline

Definition at line 64 of file MeasurementTrackerEvent.h.

64 { return *thePhase2OTData; }

References thePhase2OTData.

◆ phase2OTVectorHits()

const VectorHitCollection& MeasurementTrackerEvent::phase2OTVectorHits ( ) const
inline

Definition at line 65 of file MeasurementTrackerEvent.h.

65 { return *thePhase2OTVectorHits; }

References thePhase2OTVectorHits.

◆ phase2OTVectorHitsRej()

const VectorHitCollection& MeasurementTrackerEvent::phase2OTVectorHitsRej ( ) const
inline

Definition at line 66 of file MeasurementTrackerEvent.h.

66 { return *thePhase2OTVectorHitsRej; }

References thePhase2OTVectorHitsRej.

◆ pixelClustersToSkip()

const std::vector<bool>& MeasurementTrackerEvent::pixelClustersToSkip ( ) const
inline

Definition at line 68 of file MeasurementTrackerEvent.h.

68 { return thePixelClustersToSkip; }

References thePixelClustersToSkip.

Referenced by MeasurementTrackerEvent().

◆ pixelData()

const PxMeasurementDetSet& MeasurementTrackerEvent::pixelData ( ) const
inline

Definition at line 63 of file MeasurementTrackerEvent.h.

63 { return *thePixelData; }

References thePixelData.

◆ stripClustersToSkip()

const std::vector<bool>& MeasurementTrackerEvent::stripClustersToSkip ( ) const
inline

Definition at line 67 of file MeasurementTrackerEvent.h.

67 { return theStripClustersToSkip; }

References theStripClustersToSkip.

Referenced by MeasurementTrackerEvent().

◆ stripData()

const StMeasurementDetSet& MeasurementTrackerEvent::stripData ( ) const
inline

Definition at line 62 of file MeasurementTrackerEvent.h.

62 { return *theStripData; }

References theStripData.

Member Data Documentation

◆ theOwner

bool MeasurementTrackerEvent::theOwner = false
private

◆ thePhase2OTClustersToSkip

std::vector<bool> MeasurementTrackerEvent::thePhase2OTClustersToSkip
private

Definition at line 89 of file MeasurementTrackerEvent.h.

Referenced by MeasurementTrackerEvent(), and phase2OTClustersToSkip().

◆ thePhase2OTData

const Phase2OTMeasurementDetSet* MeasurementTrackerEvent::thePhase2OTData = nullptr
private

◆ thePhase2OTVectorHits

const VectorHitCollection* MeasurementTrackerEvent::thePhase2OTVectorHits = nullptr
private

◆ thePhase2OTVectorHitsRej

const VectorHitCollection* MeasurementTrackerEvent::thePhase2OTVectorHitsRej = nullptr
private

◆ thePixelClustersToSkip

std::vector<bool> MeasurementTrackerEvent::thePixelClustersToSkip
private

◆ thePixelData

const PxMeasurementDetSet* MeasurementTrackerEvent::thePixelData = nullptr
private

◆ theStripClustersToSkip

std::vector<bool> MeasurementTrackerEvent::theStripClustersToSkip
private

◆ theStripData

const StMeasurementDetSet* MeasurementTrackerEvent::theStripData = nullptr
private

◆ theTracker

const MeasurementTracker* MeasurementTrackerEvent::theTracker = nullptr
private
MeasurementTrackerEvent::theTracker
const MeasurementTracker * theTracker
Definition: MeasurementTrackerEvent.h:79
MeasurementTrackerEvent::thePixelClustersToSkip
std::vector< bool > thePixelClustersToSkip
Definition: MeasurementTrackerEvent.h:88
MeasurementTrackerEvent::thePhase2OTClustersToSkip
std::vector< bool > thePhase2OTClustersToSkip
Definition: MeasurementTrackerEvent.h:89
MeasurementTracker::geometricSearchTracker
const GeometricSearchTracker * geometricSearchTracker() const
Definition: MeasurementTracker.h:38
MeasurementTrackerEvent::thePhase2OTVectorHits
const VectorHitCollection * thePhase2OTVectorHits
Definition: MeasurementTrackerEvent.h:83
MeasurementTrackerEvent::stripClustersToSkip
const std::vector< bool > & stripClustersToSkip() const
Definition: MeasurementTrackerEvent.h:67
MeasurementTrackerEvent::theStripClustersToSkip
std::vector< bool > theStripClustersToSkip
Definition: MeasurementTrackerEvent.h:87
MeasurementTrackerEvent::thePhase2OTVectorHitsRej
const VectorHitCollection * thePhase2OTVectorHitsRej
Definition: MeasurementTrackerEvent.h:84
PxMeasurementDetSet::handle
const edm::Handle< edmNew::DetSetVector< SiPixelCluster > > & handle() const
Definition: TkMeasurementDetSet.h:385
Phase2OTMeasurementDetSet::handle
const edm::Handle< edmNew::DetSetVector< Phase2TrackerCluster1D > > & handle() const
Definition: TkMeasurementDetSet.h:471
trackingPlots.other
other
Definition: trackingPlots.py:1460
MeasurementTracker::geomTracker
const TrackerGeometry * geomTracker() const
Definition: MeasurementTracker.h:36
PbPb_ZMuSkimMuonDPG_cff.tracker
tracker
Definition: PbPb_ZMuSkimMuonDPG_cff.py:60
MeasurementTrackerEvent::measurementTracker
const MeasurementTracker & measurementTracker() const
Definition: MeasurementTrackerEvent.h:61
MeasurementTrackerEvent::phase2OTClustersToSkip
const std::vector< bool > & phase2OTClustersToSkip() const
Definition: MeasurementTrackerEvent.h:69
MeasurementTrackerEvent::phase2OTVectorHits
const VectorHitCollection & phase2OTVectorHits() const
Definition: MeasurementTrackerEvent.h:65
MeasurementTrackerEvent::theStripData
const StMeasurementDetSet * theStripData
Definition: MeasurementTrackerEvent.h:80
MeasurementTrackerEvent::thePixelData
const PxMeasurementDetSet * thePixelData
Definition: MeasurementTrackerEvent.h:81
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
MeasurementTracker::idToDet
MeasurementDetWithData idToDet(const DetId &id, const MeasurementTrackerEvent &data) const override=0
MeasurementDetSystem interface.
StMeasurementDetSet::handle
edm::Handle< edmNew::DetSetVector< SiStripCluster > > & handle()
Definition: TkMeasurementDetSet.h:204
eostools.move
def move(src, dest)
Definition: eostools.py:511
Exception
Definition: hltDiff.cc:245
MeasurementTrackerEvent::phase2OTVectorHitsRej
const VectorHitCollection & phase2OTVectorHitsRej() const
Definition: MeasurementTrackerEvent.h:66
MeasurementTrackerEvent::pixelClustersToSkip
const std::vector< bool > & pixelClustersToSkip() const
Definition: MeasurementTrackerEvent.h:68
edm::HandleBase::id
ProductID id() const
Definition: HandleBase.cc:29
DigiDM_cff.strips
strips
#turn off noise in all subdetectors simHcalUnsuppressedDigis.doNoise = False mix.digitizers....
Definition: DigiDM_cff.py:32
MeasurementTrackerEvent::thePhase2OTData
const Phase2OTMeasurementDetSet * thePhase2OTData
Definition: MeasurementTrackerEvent.h:82
MeasurementTrackerEvent::theOwner
bool theOwner
Definition: MeasurementTrackerEvent.h:85