CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes
TotemRPClusterProducer Class Reference
Inheritance diagram for TotemRPClusterProducer:
edm::stream::EDProducer<>

Public Member Functions

void produce (edm::Event &e, const edm::EventSetup &c) override
 
 TotemRPClusterProducer (const edm::ParameterSet &conf)
 
 ~TotemRPClusterProducer () override
 
- Public Member Functions inherited from edm::stream::EDProducer<>
 EDProducer ()=default
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &)
 

Private Member Functions

void run (const edm::DetSetVector< TotemRPDigi > &input, edm::DetSetVector< TotemRPCluster > &output)
 

Private Attributes

TotemRPClusterProducerAlgorithm algorithm_
 
edm::ParameterSet conf_
 
edm::InputTag digiInputTag_
 
edm::EDGetTokenT< edm::DetSetVector< TotemRPDigi > > digiInputTagToken_
 
int verbosity_
 

Additional Inherited Members

- Public Types inherited from edm::stream::EDProducer<>
typedef CacheContexts< T... > CacheTypes
 
typedef CacheTypes::GlobalCache GlobalCache
 
typedef AbilityChecker< T... > HasAbility
 
typedef CacheTypes::LuminosityBlockCache LuminosityBlockCache
 
typedef LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCacheLuminosityBlockContext
 
typedef CacheTypes::LuminosityBlockSummaryCache LuminosityBlockSummaryCache
 
typedef CacheTypes::RunCache RunCache
 
typedef RunContextT< RunCache, GlobalCacheRunContext
 
typedef CacheTypes::RunSummaryCache RunSummaryCache
 

Detailed Description

Merges neighbouring active TOTEM RP strips into clusters.

Definition at line 28 of file TotemRPClusterProducer.cc.

Constructor & Destructor Documentation

◆ TotemRPClusterProducer()

TotemRPClusterProducer::TotemRPClusterProducer ( const edm::ParameterSet conf)
explicit

Definition at line 56 of file TotemRPClusterProducer.cc.

56  : conf_(conf), algorithm_(conf) {
57  verbosity_ = conf.getParameter<int>("verbosity");
58 
59  digiInputTag_ = conf.getParameter<edm::InputTag>("tagDigi");
60  digiInputTagToken_ = consumes<edm::DetSetVector<TotemRPDigi>>(digiInputTag_);
61 
62  produces<edm::DetSetVector<TotemRPCluster>>();
63 }

References digiInputTag_, digiInputTagToken_, edm::ParameterSet::getParameter(), and verbosity_.

◆ ~TotemRPClusterProducer()

TotemRPClusterProducer::~TotemRPClusterProducer ( )
inlineoverride

Definition at line 38 of file TotemRPClusterProducer.cc.

Member Function Documentation

◆ fillDescriptions()

void TotemRPClusterProducer::fillDescriptions ( edm::ConfigurationDescriptions descr)
static

Definition at line 96 of file TotemRPClusterProducer.cc.

96  {
98 
99  desc.add<edm::InputTag>("tagDigi", edm::InputTag("totemRPRawToDigi", "TrackingStrip"))
100  ->setComment("input digis collection to retrieve");
101  desc.add<int>("verbosity", 0);
102 
103  descr.add("totemRPClusterProducer", desc);
104 }

References edm::ConfigurationDescriptions::add(), submitPVResolutionJobs::desc, and HLT_FULL_cff::InputTag.

◆ produce()

void TotemRPClusterProducer::produce ( edm::Event e,
const edm::EventSetup c 
)
override

Definition at line 67 of file TotemRPClusterProducer.cc.

67  {
68  // get input
70  e.getByToken(digiInputTagToken_, input);
71 
72  // prepare output
74 
75  // run clusterisation
76  if (!input->empty())
77  run(*input, output);
78 
79  // save output to event
80  e.put(make_unique<DetSetVector<TotemRPCluster>>(output));
81 }

References digiInputTagToken_, MillePedeFileConverter_cfg::e, input, convertSQLitetoXML_cfg::output, and run().

◆ run()

void TotemRPClusterProducer::run ( const edm::DetSetVector< TotemRPDigi > &  input,
edm::DetSetVector< TotemRPCluster > &  output 
)
private

Definition at line 85 of file TotemRPClusterProducer.cc.

86  {
87  for (const auto& ds_digi : input) {
88  edm::DetSet<TotemRPCluster>& ds_cluster = output.find_or_insert(ds_digi.id);
89 
90  algorithm_.buildClusters(ds_digi.id, ds_digi.data, ds_cluster.data);
91  }
92 }

References algorithm_, TotemRPClusterProducerAlgorithm::buildClusters(), edm::DetSet< T >::data, input, and convertSQLitetoXML_cfg::output.

Referenced by produce().

Member Data Documentation

◆ algorithm_

TotemRPClusterProducerAlgorithm TotemRPClusterProducer::algorithm_
private

Definition at line 49 of file TotemRPClusterProducer.cc.

Referenced by run().

◆ conf_

edm::ParameterSet TotemRPClusterProducer::conf_
private

Definition at line 44 of file TotemRPClusterProducer.cc.

◆ digiInputTag_

edm::InputTag TotemRPClusterProducer::digiInputTag_
private

Definition at line 46 of file TotemRPClusterProducer.cc.

Referenced by TotemRPClusterProducer().

◆ digiInputTagToken_

edm::EDGetTokenT<edm::DetSetVector<TotemRPDigi> > TotemRPClusterProducer::digiInputTagToken_
private

Definition at line 47 of file TotemRPClusterProducer.cc.

Referenced by produce(), and TotemRPClusterProducer().

◆ verbosity_

int TotemRPClusterProducer::verbosity_
private

Definition at line 45 of file TotemRPClusterProducer.cc.

Referenced by TotemRPClusterProducer().

edm::DetSetVector
Definition: DetSetVector.h:61
input
static const std::string input
Definition: EdmProvDump.cc:48
edm::DetSet
Definition: DetSet.h:23
convertSQLitetoXML_cfg.output
output
Definition: convertSQLitetoXML_cfg.py:72
HLT_FULL_cff.InputTag
InputTag
Definition: HLT_FULL_cff.py:89353
edm::ParameterSetDescription
Definition: ParameterSetDescription.h:52
TotemRPClusterProducer::digiInputTagToken_
edm::EDGetTokenT< edm::DetSetVector< TotemRPDigi > > digiInputTagToken_
Definition: TotemRPClusterProducer.cc:47
edm::Handle
Definition: AssociativeIterator.h:50
TotemRPClusterProducer::algorithm_
TotemRPClusterProducerAlgorithm algorithm_
Definition: TotemRPClusterProducer.cc:49
edm::ConfigurationDescriptions::add
void add(std::string const &label, ParameterSetDescription const &psetDescription)
Definition: ConfigurationDescriptions.cc:57
TotemRPClusterProducerAlgorithm::buildClusters
int buildClusters(unsigned int detId, const std::vector< TotemRPDigi > &digi, std::vector< TotemRPCluster > &clusters)
Definition: TotemRPClusterProducerAlgorithm.cc:25
TotemRPClusterProducer::run
void run(const edm::DetSetVector< TotemRPDigi > &input, edm::DetSetVector< TotemRPCluster > &output)
Definition: TotemRPClusterProducer.cc:85
TotemRPClusterProducer::conf_
edm::ParameterSet conf_
Definition: TotemRPClusterProducer.cc:44
TotemRPClusterProducer::digiInputTag_
edm::InputTag digiInputTag_
Definition: TotemRPClusterProducer.cc:46
submitPVResolutionJobs.desc
string desc
Definition: submitPVResolutionJobs.py:251
edm::DetSet::data
collection_type data
Definition: DetSet.h:80
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
edm::InputTag
Definition: InputTag.h:15
TotemRPClusterProducer::verbosity_
int verbosity_
Definition: TotemRPClusterProducer.cc:45
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37