CMS 3D CMS Logo

SiStripClusterizer.cc
Go to the documentation of this file.
6 
8  : inputTags(conf.getParameter<std::vector<edm::InputTag>>("DigiProducersList")),
10  conf.getParameter<edm::ParameterSet>("Clusterizer"))) {
11  produces<edmNew::DetSetVector<SiStripCluster>>();
13  inputTags, [this](edm::InputTag const& tag) { return consumes<edm::DetSetVector<SiStripDigi>>(tag); });
14 }
15 
17  auto output = std::make_unique<edmNew::DetSetVector<SiStripCluster>>();
18  output->reserve(10000, 4 * 10000);
19 
21  // edm::Handle< edmNew::DetSetVector<SiStripDigi> > inputNew;
22 
23  algorithm->initialize(es);
24 
25  for (auto const& token : inputTokens) {
26  if (findInput(token, inputOld, event))
27  algorithm->clusterize(*inputOld, *output);
28  // else if( findInput( tag, inputNew, event) ) algorithm->clusterize(*inputNew, *output);
29  else
30  edm::LogError("Input Not Found") << "[SiStripClusterizer::produce] "; // << tag;
31  }
32 
33  LogDebug("Output") << output->dataSize() << " clusters from " << output->size() << " modules";
34  output->shrink_to_fit();
35  event.put(std::move(output));
36 }
37 
38 template <class T>
40  e.getByToken(tag, handle);
41  return handle.isValid();
42 }
convertSQLitetoXML_cfg.output
output
Definition: convertSQLitetoXML_cfg.py:72
patZpeak.handle
handle
Definition: patZpeak.py:23
edm::EDGetTokenT
Definition: EDGetToken.h:33
edm
HLT enums.
Definition: AlignableModifier.h:19
SiStripClusterizer::algorithm
std::unique_ptr< StripClusterizerAlgorithm > algorithm
Definition: SiStripClusterizer.h:22
HLT_FULL_cff.InputTag
InputTag
Definition: HLT_FULL_cff.py:85964
SiStripClusterizer.h
beamerCreator.create
def create(alignables, pedeDump, additionalData, outputFile, config)
Definition: beamerCreator.py:44
SiStripClusterizer::inputTags
const std::vector< edm::InputTag > inputTags
Definition: SiStripClusterizer.h:21
edm::Handle
Definition: AssociativeIterator.h:50
GlobalPosition_Frontier_DevDB_cff.tag
tag
Definition: GlobalPosition_Frontier_DevDB_cff.py:11
HLTMuonOfflineAnalyzer_cfi.inputTags
inputTags
All input tags are specified in this pset for convenience.
Definition: HLTMuonOfflineAnalyzer_cfi.py:82
edm::vector_transform
auto vector_transform(std::vector< InputType > const &input, Function predicate) -> std::vector< typename std::remove_cv< typename std::remove_reference< decltype(predicate(input.front()))>::type >::type >
Definition: transform.h:11
SiStripClusterizer::findInput
bool findInput(const edm::EDGetTokenT< T > &, edm::Handle< T > &, const edm::Event &)
Definition: SiStripClusterizer.cc:39
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:223
edm::ParameterSet
Definition: ParameterSet.h:47
SiStripClusterizer::produce
void produce(edm::Event &, const edm::EventSetup &) override
Definition: SiStripClusterizer.cc:16
SiStripCluster.h
Event.h
ParameterSet
Definition: Functions.h:16
SiStripClusterizer::inputTokens
token_v inputTokens
Definition: SiStripClusterizer.h:25
qcdUeDQM_cfi.algorithm
algorithm
Definition: qcdUeDQM_cfi.py:32
trackerHitRTTI::vector
Definition: trackerHitRTTI.h:21
edm::EventSetup
Definition: EventSetup.h:57
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
eostools.move
def move(src, dest)
Definition: eostools.py:511
std
Definition: JetResolutionObject.h:76
transform.h
StripClusterizerAlgorithmFactory
Definition: StripClusterizerAlgorithmFactory.h:12
SiStripClusterizer::SiStripClusterizer
SiStripClusterizer(const edm::ParameterSet &conf)
Definition: SiStripClusterizer.cc:7
event
Definition: event.py:1
edm::Event
Definition: Event.h:73
edm::InputTag
Definition: InputTag.h:15
StripClusterizerAlgorithmFactory.h
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37
unpackBuffers-CaloStage2.token
token
Definition: unpackBuffers-CaloStage2.py:318