src
CalibTracker
SiStripCommon
interface
SiStripOnTrackClusterTableProducerBase.h
Go to the documentation of this file.
1
#include "
FWCore/Framework/interface/stream/EDProducer.h
"
2
#include "
FWCore/Framework/interface/ConsumesCollector.h
"
3
#include "
FWCore/ParameterSet/interface/ParameterSet.h
"
4
5
#include "
DataFormats/NanoAOD/interface/FlatTable.h
"
6
#include "
DataFormats/SiStripCluster/interface/SiStripCluster.h
"
7
#include "
DataFormats/TrackReco/interface/Track.h
"
8
#include "
TrackingTools/PatternTools/interface/TrajTrackAssociation.h
"
9
10
class
SiStripOnTrackClusterTableProducerBase
:
public
edm::stream::EDProducer
<> {
11
public
:
12
explicit
SiStripOnTrackClusterTableProducerBase
(
const
edm::ParameterSet
&
params
)
13
:
m_name
(
params
.getParameter<
std
::
string
>(
"name"
)),
14
m_doc
(
params
.existsAs<
std
::
string
>(
"doc"
) ?
params
.getParameter<
std
::
string
>(
"doc"
) :
""
),
15
m_extension
(
params
.existsAs<
bool
>(
"extension"
) ?
params
.getParameter<
bool
>(
"extension"
) :
true
),
16
m_tracks_token
(consumes<
edm
::
View
<
reco
::Track>>(
params
.getParameter<
edm
::
InputTag
>(
"Tracks"
))),
17
m_association_token
(consumes<
TrajTrackAssociationCollection
>(
params
.getParameter<
edm
::
InputTag
>(
"Tracks"
))) {
18
produces<nanoaod::FlatTable>();
19
}
20
~SiStripOnTrackClusterTableProducerBase
()
override
;
21
22
void
produce
(
edm::Event
&
iEvent
,
const
edm::EventSetup
& iSetup)
final
;
23
24
struct
OnTrackCluster
{
25
uint32_t
det
;
26
const
SiStripCluster
*
cluster
;
27
const
Trajectory
*
traj
;
28
const
reco::Track
*
track
;
29
const
TrajectoryMeasurement
&
measurement
;
30
OnTrackCluster
(uint32_t
detId
,
31
const
SiStripCluster
*
stripCluster
,
32
const
Trajectory
* trajectory,
33
const
reco::Track
* track_,
34
const
TrajectoryMeasurement
& measurement_)
35
:
det
{
detId
},
cluster
{
stripCluster
},
traj
{trajectory},
track
{track_},
measurement
{measurement_} {}
36
};
37
38
virtual
void
fillTable
(
const
std::vector<OnTrackCluster>&
clusters
,
39
const
edm::View<reco::Track>
&
tracks
,
40
nanoaod::FlatTable
*
table
,
41
const
edm::EventSetup
& iSetup) = 0;
42
43
template
<
typename
VALUES>
44
static
void
addColumn
(
nanoaod::FlatTable
*
table
,
const
std::string
&
name
, VALUES&&
values
,
const
std::string
&
doc
) {
45
using
value_type
=
typename
std::remove_reference<VALUES>::type::value_type
;
46
table
->template addColumn<value_type>(
name
,
values
,
doc
);
47
}
48
49
private
:
50
const
std::string
m_name
;
51
const
std::string
m_doc
;
52
bool
m_extension
;
53
54
const
edm::EDGetTokenT<edm::View<reco::Track>
>
m_tracks_token
;
55
const
edm::EDGetTokenT<TrajTrackAssociationCollection>
m_association_token
;
56
};
SiStripOnTrackClusterTableProducerBase::m_name
const std::string m_name
Definition:
SiStripOnTrackClusterTableProducerBase.h:50
FlatTable.h
ProducerED_cfi.InputTag
InputTag
Definition:
ProducerED_cfi.py:5
SiStripOnTrackClusterTableProducerBase::m_extension
bool m_extension
Definition:
SiStripOnTrackClusterTableProducerBase.h:52
EDProducer.h
TableParser.table
table
Definition:
TableParser.py:113
SiStripOnTrackClusterTableProducerBase
Definition:
SiStripOnTrackClusterTableProducerBase.h:10
std
Definition:
JetResolutionObject.h:76
SiStripOnTrackClusterTableProducerBase::SiStripOnTrackClusterTableProducerBase
SiStripOnTrackClusterTableProducerBase(const edm::ParameterSet ¶ms)
Definition:
SiStripOnTrackClusterTableProducerBase.h:12
edm::EDGetTokenT
Definition:
EDGetToken.h:37
Trajectory
Definition:
Trajectory.h:38
nanoaod::FlatTable
Definition:
FlatTable.h:38
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
ParameterSet.h
DiMuonV_cfg.tracks
tracks
Definition:
DiMuonV_cfg.py:215
funct::true
true
Definition:
Factorize.h:173
edm::View
Definition:
CaloClusterFwd.h:14
iEvent
int iEvent
Definition:
GenABIO.cc:224
reco::JetExtendedAssociation::value_type
Container::value_type value_type
Definition:
JetExtendedAssociation.h:30
SiStripOnTrackClusterTableProducerBase::OnTrackCluster
Definition:
SiStripOnTrackClusterTableProducerBase.h:24
SiStripOnTrackClusterTableProducerBase::OnTrackCluster::traj
const Trajectory * traj
Definition:
SiStripOnTrackClusterTableProducerBase.h:27
SiStripOnTrackClusterTableProducerBase::m_doc
const std::string m_doc
Definition:
SiStripOnTrackClusterTableProducerBase.h:51
SiStripCluster
Definition:
SiStripCluster.h:12
SiStripOnTrackClusterTableProducerBase::OnTrackCluster::det
uint32_t det
Definition:
SiStripOnTrackClusterTableProducerBase.h:25
SiStripOnTrackClusterTableProducerBase::OnTrackCluster::OnTrackCluster
OnTrackCluster(uint32_t detId, const SiStripCluster *stripCluster, const Trajectory *trajectory, const reco::Track *track_, const TrajectoryMeasurement &measurement_)
Definition:
SiStripOnTrackClusterTableProducerBase.h:30
edm::AssociationMap< edm::OneToOne< std::vector< Trajectory >, reco::TrackCollection, unsigned short > >
contentValuesCheck.values
values
Definition:
contentValuesCheck.py:38
edm::EventSetup
Definition:
EventSetup.h:56
hcalRecHitTable_cff.detId
detId
Definition:
hcalRecHitTable_cff.py:12
SiStripOnTrackClusterTableProducerBase::OnTrackCluster::track
const reco::Track * track
Definition:
SiStripOnTrackClusterTableProducerBase.h:28
submitPVValidationJobs.params
def params
Definition:
submitPVValidationJobs.py:483
SiStripOnTrackClusterTableProducerBase::OnTrackCluster::cluster
const SiStripCluster * cluster
Definition:
SiStripOnTrackClusterTableProducerBase.h:26
SiStripOnTrackClusterTableProducerBase::m_association_token
const edm::EDGetTokenT< TrajTrackAssociationCollection > m_association_token
Definition:
SiStripOnTrackClusterTableProducerBase.h:55
SiStripOnTrackClusterTableProducerBase::produce
void produce(edm::Event &iEvent, const edm::EventSetup &iSetup) final
Definition:
SiStripOnTrackClusterTableProducerBase.cc:20
SiStripOnTrackClusterTableProducerBase::OnTrackCluster::measurement
const TrajectoryMeasurement & measurement
Definition:
SiStripOnTrackClusterTableProducerBase.h:29
edm::stream::EDProducer
Definition:
EDProducer.h:36
nano_mu_local_reco_cff.bool
bool
Definition:
nano_mu_local_reco_cff.py:14
TrajTrackAssociation.h
reco::Track
Definition:
Track.h:27
SiStripOnTrackClusterTableProducerBase::addColumn
static void addColumn(nanoaod::FlatTable *table, const std::string &name, VALUES &&values, const std::string &doc)
Definition:
SiStripOnTrackClusterTableProducerBase.h:44
reco
fixed size matrix
Definition:
AlignmentAlgorithmBase.h:46
TrajectoryMeasurement
Definition:
TrajectoryMeasurement.h:25
hcalRecHitTable_cff.doc
doc
Definition:
hcalRecHitTable_cff.py:8
edm
HLT enums.
Definition:
AlignableModifier.h:19
SiStripCluster.h
SiStripOnTrackClusterTableProducerBase::m_tracks_token
const edm::EDGetTokenT< edm::View< reco::Track > > m_tracks_token
Definition:
SiStripOnTrackClusterTableProducerBase.h:54
Track.h
edm::ParameterSet
Definition:
ParameterSet.h:48
SiStripOnTrackClusterTableProducerBase::fillTable
virtual void fillTable(const std::vector< OnTrackCluster > &clusters, const edm::View< reco::Track > &tracks, nanoaod::FlatTable *table, const edm::EventSetup &iSetup)=0
edm::Event
Definition:
Event.h:73
ConsumesCollector.h
sistrip::View
View
Definition:
ConstantsForView.h:26
TrackingMonitor_cfi.stripCluster
stripCluster
Definition:
TrackingMonitor_cfi.py:20
bsc_activity_cfg.clusters
clusters
Definition:
bsc_activity_cfg.py:36
Skims_PA_cff.name
name
Definition:
Skims_PA_cff.py:17
SiStripOnTrackClusterTableProducerBase::~SiStripOnTrackClusterTableProducerBase
~SiStripOnTrackClusterTableProducerBase() override
Definition:
SiStripOnTrackClusterTableProducerBase.cc:7
Generated for CMSSW Reference Manual by
1.8.14