321 std::vector<const GeomDet*>::const_iterator itTracker = trackerGeometry.dets().begin();
322 for (; itTracker != trackerGeometry.dets().end(); ++itTracker) {
323 int subdet = (*itTracker)->geographicalId().subdetId();
327 module.x = (*itTracker)->position().x();
328 module.y = (*itTracker)->position().y();
329 module.z = (*itTracker)->position().z();
330 module.Phi = (*itTracker)->position().phi();
331 module.Eta = (*itTracker)->position().eta();
332 module.DetId = (*itTracker)->geographicalId().rawId();
333 const std::vector<sipixelobjects::CablingPathToDetUnit> path2det =
PixelCabling_->pathToDetUnit(
module.DetId);
334 module.Fed = path2det[0].fed;
368 hcalRecHitCollection = hbheRecHitHandle.
product();
370 double radTodeg = 180. /
Geom::pi();
396 std::vector<edm::Ref<TCandColl>> recoEcalCandColl;
399 typename std::vector<edm::EDGetTokenT<TEleColl>>::const_iterator itElectronColl =
electronToken_.begin();
401 std::vector<edm::EDGetTokenT<trigger::TriggerFilterObjectWithRefs>>::const_iterator itRecoEcalCandColl =
409 ++itElectronColl, ++itElectronCollFlag, ++itRecoEcalCandColl) {
411 iEvent.getByToken(*itRecoEcalCandColl, triggerRecoEcalCandidateCollection);
412 if (triggerRecoEcalCandidateCollection.
failedToGet())
421 if (recoEcalCandColl.empty())
423 if (recoEcalCandColl.empty())
426 typename std::vector<edm::Ref<TCandColl>>::const_iterator itRecoEcalCand =
427 recoEcalCandColl.begin();
430 for (; itRecoEcalCand != recoEcalCandColl.end(); ++itRecoEcalCand) {
431 recoEcalCand = (*itRecoEcalCand);
433 recoEcalCand->superCluster();
435 typename TEleColl::const_iterator itEle =
electrons->begin();
436 for (; itEle !=
electrons->end(); ++itEle) {
440 if (scRefRecoEcalCand != scRef)
443 const std::vector<std::pair<DetId, float>>&
hits = scRef->hitsAndFractions();
445 std::vector<std::pair<DetId, float>>::const_iterator itSChits =
hits.begin();
447 for (; itSChits !=
hits.end(); ++itSChits) {
448 if ((*itSChits).first.subdetId() ==
EcalBarrel) {
449 EBDetId idEBRaw((*itSChits).first);
456 LogDebug(
"SelectedElectronFEDListProducer")
457 <<
" electron hit detID Barrel " << (*itSChits).first.rawId() <<
" eta " << double(
point.eta())
458 <<
" phi " <<
double(
point.phi()) * radTodeg <<
" FED " << hitFED << std::endl;
467 }
else if ((*itSChits).first.subdetId() ==
EcalEndcap) {
468 EEDetId idEERaw((*itSChits).first);
475 LogDebug(
"SelectedElectronFEDListProducer")
476 <<
" electron hit detID Endcap " << (*itSChits).first.rawId() <<
" eta " << double(
point.eta())
477 <<
" phi " <<
double(
point.phi()) * radTodeg <<
" FED " << hitFED << std::endl;
491 LogDebug(
"SelectedElectronFEDListProducer")
492 <<
" ES hit plane X (deiID) " << stripX.
rawId() <<
" six " << stripX.
six() <<
" siy " 493 << stripX.
siy() <<
" plane " << stripX.
plane() <<
" FED ID " << hitFED << std::endl;
511 LogDebug(
"SelectedElectronFEDListProducer")
512 <<
" ES hit plane Y (deiID) " << stripY.
rawId() <<
" six " << stripY.
six() <<
" siy " 513 << stripY.
siy() <<
" plane " << stripY.
plane() <<
" FED ID " << hitFED << std::endl;
528 for (; itHcalRecHit != hcalRecHitCollection->
end(); ++itHcalRecHit) {
534 cellGeometry->getPosition(recHitId).eta(),
535 cellGeometry->getPosition(recHitId).phi());
539 LogDebug(
"SelectedElectronFEDListProducer")
540 <<
" matched hcal recHit : HcalDetId " << recHitId <<
" HcalElectronicsId " << electronicId
541 <<
" dcc id " << electronicId.
dccid() <<
" spigot " << electronicId.
spigot() <<
" fiber channel " 563 if (*itElectronCollFlag) {
570 for (uint32_t iCabling = 0; iCabling < SiStripCabling.size(); iCabling++) {
572 double dphi = fabs(
pos.second -
phi);
574 dphi = 2 * acos(-1) - dphi;
587 regSubdetLayers[ilayer];
588 SiStripRegionCabling::ElementCabling::const_iterator itFedMap = fedVectorMap.begin();
589 for (; itFedMap != fedVectorMap.end(); itFedMap++) {
590 for (uint32_t
op = 0;
op < (itFedMap->second).
size();
op++) {
591 int hitFED = (itFedMap->second)[
op].
fedId();
594 LogDebug(
"SelectedElectronFEDListProducer") <<
" SiStrip (FedID) " << hitFED << std::endl;
608 if (*itElectronCollFlag)
609 momentum =
electron.gsfTrack()->momentum();
611 momentum =
electron.track()->momentum();
616 std::vector<PixelModule>::const_iterator itUp, itDn;
617 if (lowerBound.Phi >= -
M_PI && upperBound.Phi <=
M_PI) {
622 if (lowerBound.Phi < -
M_PI)
623 lowerBound.Phi = lowerBound.Phi + 2 *
M_PI;
629 if (upperBound.Phi < -
M_PI)
630 upperBound.Phi = upperBound.Phi - 2 *
M_PI;
650 auto streamFEDRawProduct = std::make_unique<FEDRawDataCollection>();
652 std::vector<uint32_t>::const_iterator itfedList =
fedList_.begin();
653 for (; itfedList !=
fedList_.end(); ++itfedList) {
654 LogDebug(
"SelectedElectronFEDListProducer") <<
" fed point " << *itfedList <<
" ";
656 if (
data.size() > 0) {
657 FEDRawData& fedData = streamFEDRawProduct->FEDData(*itfedList);
void getObjects(Vids &ids, VRphoton &refs) const
various physics-level getters:
math::XYZVector beamSpotPosition_
std::vector< edm::EDGetTokenT< trigger::TriggerFilterObjectWithRefs > > recoEcalCandidateToken_
const HcalElectronicsMap * HcalReadoutMap_
const edm::ESGetToken< CaloGeometry, CaloGeometryRecord > caloGeometryToken_
edm::InputTag beamSpotTag_
std::vector< uint32_t > fedList_
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
const edm::ESGetToken< HcalDbService, HcalDbRecord > hcalDbToken_
int GetFED(double eta, double phi) const
const edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > trackerGeometryToken_
std::string outputLabelModule_
const DetId lookup(HcalElectronicsId fId) const
lookup the logical detid associated with the given electronics id
T const * product() const
std::vector< T >::const_iterator const_iterator
const CaloSubdetectorGeometry * GeometryES_
const edm::ESGetToken< SiPixelFedCablingMap, SiPixelFedCablingMapRcd > siPixelFedCablingMapToken_
const Cabling & getRegionCabling() const
std::vector< Element > ElementCabling
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
bool dumpSelectedSiStripFed_
const CaloGeometry * GeometryCalo_
edm::EDGetTokenT< HBHERecHitCollection > hbheRecHitToken_
const Position position(const uint32_t) const
std::unique_ptr< SiPixelFedCablingTree > PixelCabling_
edm::EDGetTokenT< FEDRawDataCollection > rawDataToken_
GlobalPoint getPosition(const DetId &id) const
Get the position of a given detector id.
void resize(size_t newsize)
constexpr int fiberIndex() const
get the fiber index. For VME 1-8 (which of eight fibers carried by a spigot), for uTCA fibers are zer...
edm::InputTag HBHERecHitTag_
const edm::ESGetToken< EcalElectronicsMapping, EcalMappingRcd > ecalMappingToken_
edm::InputTag rawDataTag_
const_iterator begin() const
std::vector< RegionCabling > Cabling
const edm::ESGetToken< SiStripRegionCabling, SiStripRegionCablingRcd > siStripRegionCablingToken_
std::vector< int > isGsfElectronCollection_
bool dumpSelectedHCALFed_
const FEDRawData & FEDData(int fedid) const
retrieve data for fed
constexpr auto deltaR(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
const_iterator end() const
XYZVectorD XYZVector
spatial vector with cartesian internal representation
constexpr uint32_t rawId() const
get the raw id
const EcalElectronicsMapping * EcalMapping_
constexpr int dccid() const
get the (Hcal local) DCC id for VME, crate number for uTCA
std::pair< double, double > Position
std::vector< PixelModule > pixelModuleVector_
edm::EDGetTokenT< reco::BeamSpot > beamSpotToken_
constexpr int fiberChanId() const
get the fiber channel id (which of channels on a fiber)
std::vector< WedgeCabling > RegionCabling
bool dumpSelectedSiPixelFed_
char data[epos_bytes_allocation]
const std::pair< double, double > regionDimensions() const
constexpr int spigot() const
get the spigot (input number on DCC, AMC card number for uTCA)
ESTransientHandle< T > getTransientHandle(const ESGetToken< T, R > &iToken) const
const SiStripRegionCabling * StripRegionCabling_
const unsigned char * data() const
Return a const pointer to the beginning of the data buffer.
int ES_fedId_[2][2][40][40]
std::vector< ElementCabling > WedgeCabling
std::vector< int > addThisSelectedFEDs_
std::pair< double, double > regionDimension_
const CaloSubdetectorGeometry * getSubdetectorGeometry(const DetId &id) const
access the subdetector geometry for the given subdetector directly
Readout chain identification for Hcal.
void pixelFedDump(std::vector< PixelModule >::const_iterator &itDn, std::vector< PixelModule >::const_iterator &itUp, const PixelRegion ®ion)
std::vector< edm::EDGetTokenT< TEleColl > > electronToken_
bool dumpSelectedEcalFed_
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point