|
|
|
void | fillCentralTOFs () |
|
unsigned int | fillDigiMap (ChamberDigiMap &chDigiMap, unsigned int bx, unsigned int part, unsigned int strip, unsigned int currentIDX) const |
|
int | getCustomStripProperties (const ME0DetId &detId, const ME0DigiPreReco *inDigi, float &tof, int &strip, LocalPoint &digiLocalPoint, LocalError &digiLocalError) const |
|
void | getStripProperties (const ME0EtaPartition *etaPart, const ME0DigiPreReco *inDigi, float &tof, int &strip, LocalPoint &digiLocalPoint, LocalError &digiLocalError) const |
|
Definition at line 40 of file ME0ReDigiProducer.cc.
◆ ChamberDigiMap
◆ DigiIndicies
◆ ME0ReDigiProducer()
◆ ~ME0ReDigiProducer()
ME0ReDigiProducer::~ME0ReDigiProducer |
( |
| ) |
|
|
override |
◆ beginRun()
Definition at line 313 of file ME0ReDigiProducer.cc.
321 throw cms::Exception(
"Setup") <<
"ME0ReDigiProducer::beginRun() - No ME0Chambers in geometry.";
325 throw cms::Exception(
"Setup") <<
"ME0ReDigiProducer::beginRun() - No layers in ME0 geometry.";
327 const unsigned int nPartitions =
chambers.front()->layers()[0]->nEtaPartitions();
336 <<
"ME0ReDigiProducer::beginRun() - The geometry has " <<
nLayers <<
" layers, but the readout of "
337 <<
layerReadout.size() <<
" were specified with the layerReadout parameter.";
340 LogDebug(
"ME0ReDigiProducer") <<
"Building temporary geometry:" << std::endl;
342 LogDebug(
"ME0ReDigiProducer") <<
"Done building temporary geometry!" << std::endl;
346 <<
"ME0ReDigiProducer::beginRun() - The geometry has " <<
tempGeo->
numLayers()
347 <<
" layers, but the readout of " <<
layerReadout.size()
348 <<
" were specified with the layerReadout parameter.";
References chambers, options_cfi::eventSetup, Exception, fillCentralTOFs(), get, layerReadout, LogDebug, MuonTCMETValueMapProducer_cff::nLayers, numberOfPartitions, numberOfStrips, ME0ReDigiProducer::TemporaryGeometry::numLayers(), tempGeo, useBuiltinGeo, and useCusGeoFor1PartGeo.
◆ buildDigis()
Definition at line 370 of file ME0ReDigiProducer.cc.
388 LogDebug(
"ME0ReDigiProducer::buildDigis") <<
"Begin building digis." << std::endl;
390 for (me0dgIt = input_digis.begin(); me0dgIt != input_digis.end(); ++me0dgIt) {
391 const auto& me0Id = (*me0dgIt).first;
392 LogTrace(
"ME0ReDigiProducer::buildDigis") <<
"Starting with roll: " << me0Id << std::endl;
400 LogTrace(
"ME0ReDigiProducer::buildDigis") << std::endl
401 <<
"(" << digi->x() <<
"," << digi->y() <<
"," << digi->tof() <<
","
402 << digi->pdgid() <<
"," << digi->prompt() <<
")-> ";
421 int mapPartIDX = me0Id.roll() - 1;
432 const int bxIdx = std::round(tof /
bxWidth);
433 LogTrace(
"ME0ReDigiProducer::buildDigis") << tof <<
"(" << bxIdx <<
") ";
445 LogTrace(
"ME0ReDigiProducer::buildDigis") <<
"(" << bxIdx <<
"," << mapPartIDX <<
"," <<
strip <<
") ";
447 int matchIDX =
fillDigiMap(chDigiMap, bxIdx, mapPartIDX,
strip, newDigiIdx);
461 digiLocalPoint.
x(), digiLocalPoint.
y(),
sigmaX,
sigmaY, corrCoef, tof, digi->pdgid(), digi->prompt());
462 output_digis.insertDigi(me0Id, out_digi);
468 LogTrace(
"ME0ReDigiProducer::buildDigis") <<
"(" << digiLocalPoint.
x() <<
"," << digiLocalPoint.
y() <<
","
References bxWidth, fillDigiMap(), getCustomStripProperties(), getStripProperties(), MuonDigiCollection< IndexType, DigiType >::insertDigi(), layerReadout, LogDebug, LogTrace, maxBXReadout, mergeDigis, minBXReadout, neutronAcceptance, FastTimerService_cff::range, fftjetvertexadder_cfi::sigmaX, fftjetvertexadder_cfi::sigmaY, mathSSE::sqrt(), digitizers_cfi::strip, timeResolution, useBuiltinGeo, PV3DBase< T, PVType, FrameType >::x(), LocalError::xx(), LocalError::xy(), PV3DBase< T, PVType, FrameType >::y(), and LocalError::yy().
Referenced by produce().
◆ fillCentralTOFs()
void ME0ReDigiProducer::fillCentralTOFs |
( |
| ) |
|
|
private |
Definition at line 476 of file ME0ReDigiProducer.cc.
477 const auto* mainChamber =
geometry->chambers().front();
478 const unsigned int nLayers = mainChamber->nLayers();
482 LogDebug(
"ME0ReDigiProducer::fillCentralTOFs()") <<
"TOF numbers [layer][partition]: ";
483 for (
unsigned int iL = 0; iL <
nLayers; ++iL) {
484 const auto* layer = mainChamber->layers()[iL];
485 const unsigned int mapLayIDX = layer->id().layer() - 1;
486 const unsigned int nPartitions = layer->nEtaPartitions();
488 throw cms::Exception(
"Setup") <<
"ME0ReDigiProducer::fillCentralTOFs() - ME0Layer has no partitions.";
489 tofs[mapLayIDX].resize(nPartitions);
490 for (
unsigned int iP = 0; iP < nPartitions; ++iP) {
491 const unsigned int mapPartIDX = layer->etaPartitions()[iP]->id().roll() - 1;
492 const GlobalPoint centralGP(layer->etaPartitions()[iP]->position());
493 tofs[mapLayIDX][mapPartIDX] = (centralGP.mag() / (CLHEP::c_light / CLHEP::cm));
494 LogDebug(
"ME0ReDigiProducer::fillCentralTOFs()")
495 <<
"[" << mapLayIDX <<
"][" << mapPartIDX <<
"]=" <<
tofs[mapLayIDX][mapPartIDX] <<
" " << std::endl;
References Exception, LogDebug, MuonTCMETValueMapProducer_cff::nLayers, and tofs.
Referenced by beginRun().
◆ fillDigiMap()
unsigned int ME0ReDigiProducer::fillDigiMap |
( |
ChamberDigiMap & |
chDigiMap, |
|
|
unsigned int |
bx, |
|
|
unsigned int |
part, |
|
|
unsigned int |
strip, |
|
|
unsigned int |
currentIDX |
|
) |
| const |
|
private |
◆ getCustomStripProperties()
Definition at line 499 of file ME0ReDigiProducer.cc.
517 const LocalPoint partLocalPoint(inDigi->
x(), inDigi->
y() - partCenter, 0.);
518 strip = topo->channel(partLocalPoint);
522 LocalPoint digiPartLocalPoint = topo->localPosition(stripF);
523 digiLocalError = topo->localError(
528 digiLocalPoint =
LocalPoint(digiPartLocalPoint.
x(), digiPartLocalPoint.
y() + partCenter, 0.0);
References ME0ReDigiProducer::TemporaryGeometry::findEtaPartition(), dqmMemoryStats::float, ME0ReDigiProducer::TemporaryGeometry::getCentralTOF(), ME0ReDigiProducer::TemporaryGeometry::getPartCenter(), ME0ReDigiProducer::TemporaryGeometry::getTopo(), LogTrace, partIdx(), mathSSE::sqrt(), digitizers_cfi::strip, tempGeo, ME0DigiPreReco::x(), PV3DBase< T, PVType, FrameType >::x(), ME0DigiPreReco::y(), and PV3DBase< T, PVType, FrameType >::y().
Referenced by buildDigis().
◆ getStripProperties()
Definition at line 531 of file ME0ReDigiProducer.cc.
546 const LocalPoint partLocalPoint(inDigi->
x(), inDigi->
y(), 0.);
547 strip = topo.channel(partLocalPoint);
551 digiLocalPoint = topo.localPosition(stripF);
552 digiLocalError = topo.localError(stripF, 1. /
sqrt(12.));
References dqmMemoryStats::float, ME0EtaPartition::id(), ME0DetId::layer(), TrapezoidalStripTopology::nstrips(), TrapezoidalStripTopology::pitch(), TrapezoidalStripTopology::radius(), ME0DetId::roll(), ME0EtaPartition::specificTopology(), mathSSE::sqrt(), digitizers_cfi::strip, TrapezoidalStripTopology::stripLength(), tofs, usePads, ME0DigiPreReco::x(), and ME0DigiPreReco::y().
Referenced by buildDigis().
◆ produce()
◆ bxWidth
const float ME0ReDigiProducer::bxWidth |
|
private |
◆ geometry
◆ layerReadout
std::vector<int> ME0ReDigiProducer::layerReadout |
|
private |
◆ maxBXReadout
int ME0ReDigiProducer::maxBXReadout |
|
private |
◆ mergeDigis
bool ME0ReDigiProducer::mergeDigis |
|
private |
◆ minBXReadout
int ME0ReDigiProducer::minBXReadout |
|
private |
◆ neutronAcceptance
double ME0ReDigiProducer::neutronAcceptance |
|
private |
◆ numberOfPartitions
unsigned int ME0ReDigiProducer::numberOfPartitions |
|
private |
◆ numberOfStrips
unsigned int ME0ReDigiProducer::numberOfStrips |
|
private |
◆ tempGeo
◆ timeResolution
double ME0ReDigiProducer::timeResolution |
|
private |
◆ tofs
std::vector<std::vector<double> > ME0ReDigiProducer::tofs |
|
private |
◆ token
◆ useBuiltinGeo
bool ME0ReDigiProducer::useBuiltinGeo |
|
private |
◆ useCusGeoFor1PartGeo
bool ME0ReDigiProducer::useCusGeoFor1PartGeo |
|
private |
◆ usePads
bool ME0ReDigiProducer::usePads |
|
private |
edm::EDGetTokenT< ME0DigiPreRecoCollection > token
virtual CLHEP::HepRandomEngine & getEngine(StreamID const &)=0
Use this engine in event methods.
unsigned int findEtaPartition(float locY) const
float stripLength() const override
det heigth (strip length in the middle)
T const * product() const
MuonDigiCollection< ME0DetId, int > ME0DigiPreRecoMap
const TrapezoidalStripTopology * getTopo(const unsigned int partIdx) const
std::vector< DigiType >::const_iterator const_iterator
static unsigned int partIdx(const InputGenJetsParticleSelector::ParticleVector &p, const reco::Candidate *particle)
const StripTopology & specificTopology() const
std::vector< int > layerReadout
class Point3DBase< float, LocalTag > LocalPoint
void buildDigis(const ME0DigiPreRecoCollection &, ME0DigiPreRecoCollection &, ME0DigiPreRecoMap &, CLHEP::HepRandomEngine *engine)
std::tuple< unsigned int, unsigned int, unsigned int > DigiIndicies
unsigned int numberOfPartitions
float pitch() const override
std::vector< std::vector< double > > tofs
float getPartCenter(const unsigned int partIdx) const
static char chambers[264][20]
T getParameter(std::string const &) const
void getStripProperties(const ME0EtaPartition *etaPart, const ME0DigiPreReco *inDigi, float &tof, int &strip, LocalPoint &digiLocalPoint, LocalError &digiLocalError) const
unsigned int numLayers() const
void insertDigi(const IndexType &index, const DigiType &digi)
insert a digi for a given DetUnit
std::pair< const_iterator, const_iterator > Range
int getCustomStripProperties(const ME0DetId &detId, const ME0DigiPreReco *inDigi, float &tof, int &strip, LocalPoint &digiLocalPoint, LocalError &digiLocalError) const
std::map< DigiIndicies, unsigned int > ChamberDigiMap
unsigned int numberOfStrips
bool useCusGeoFor1PartGeo
int nstrips() const override
float getCentralTOF(const ME0DetId &me0Id, unsigned int partIdx) const
TemporaryGeometry * tempGeo
unsigned int fillDigiMap(ChamberDigiMap &chDigiMap, unsigned int bx, unsigned int part, unsigned int strip, unsigned int currentIDX) const
int layer() const
Layer id: each chamber has six layers of chambers: layer 1 is the inner layer and layer 6 is the oute...
MuonDigiCollection< ME0DetId, ME0DigiPreReco > ME0DigiPreRecoCollection