diff --git a/CalibCalorimetry/CaloMiscalibTools/plugins/HcalRecHitRecalib.cc b/CalibCalorimetry/CaloMiscalibTools/plugins/HcalRecHitRecalib.cc index 5bf6db0c3fc70..9d01dd9e9809c 100644 --- a/CalibCalorimetry/CaloMiscalibTools/plugins/HcalRecHitRecalib.cc +++ b/CalibCalorimetry/CaloMiscalibTools/plugins/HcalRecHitRecalib.cc @@ -4,6 +4,7 @@ #include "DataFormats/Common/interface/Handle.h" #include "FWCore/ParameterSet/interface/FileInPath.h" #include "FWCore/Framework/interface/ESHandle.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "DataFormats/HcalRecHit/interface/HcalRecHitCollections.h" #include "FWCore/MessageLogger/interface/MessageLogger.h" @@ -54,7 +55,7 @@ void HcalRecHitRecalib::beginRun(const edm::Run&, const edm::EventSetup& iSetup) { edm::ESHandle topology; - iSetup.get().get( topology ); + iSetup.get().get( topology ); mapHcal_.prefillMap(*topology); diff --git a/CalibCalorimetry/HcalAlgos/src/HcalPulseShapes.cc b/CalibCalorimetry/HcalAlgos/src/HcalPulseShapes.cc index 94075f1499738..e286c9f6d313b 100644 --- a/CalibCalorimetry/HcalAlgos/src/HcalPulseShapes.cc +++ b/CalibCalorimetry/HcalAlgos/src/HcalPulseShapes.cc @@ -10,7 +10,7 @@ #include "FWCore/Framework/interface/EventSetup.h" #include "FWCore/MessageLogger/interface/MessageLogger.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" // #include "CalibCalorimetry/HcalAlgos/interface/HcalDbASCIIIO.h" #include @@ -115,7 +115,7 @@ void HcalPulseShapes::beginRun(edm::EventSetup const & es) theMCParams = new HcalMCParams(*p.product()); edm::ESHandle htopo; - es.get().get(htopo); + es.get().get(htopo); theTopology=new HcalTopology(*htopo); theMCParams->setTopo(theTopology); diff --git a/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py b/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py index 6ca27894231c8..abf3a1b5bd9ce 100644 --- a/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py +++ b/CalibCalorimetry/HcalPlugins/python/Hcal_Conditions_forGlobalTag_cff.py @@ -22,5 +22,3 @@ es_prefer_hcalHardcode = cms.ESPrefer("HcalHardcodeCalibrations", "es_hardcode") -import Geometry.HcalEventSetup.hcalTopologyConstants_cfi as hcalTopologyConstants_cfi -es_hardcode.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) diff --git a/CalibCalorimetry/HcalPlugins/src/HcalDbProducer.cc b/CalibCalorimetry/HcalPlugins/src/HcalDbProducer.cc index 54cdc261e97ef..c125a48fdfcdf 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalDbProducer.cc +++ b/CalibCalorimetry/HcalPlugins/src/HcalDbProducer.cc @@ -28,8 +28,8 @@ #include "CalibFormats/HcalObjects/interface/HcalDbService.h" #include "CalibFormats/HcalObjects/interface/HcalDbRecord.h" - #include "CondFormats/HcalObjects/interface/AllObjects.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "HcalDbProducer.h" @@ -99,7 +99,7 @@ void HcalDbProducer::pedestalsCallback (const HcalPedestalsRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -117,7 +117,7 @@ void HcalDbProducer::pedestalWidthsCallback (const HcalPedestalWidthsRcd& fRecor if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -136,7 +136,7 @@ void HcalDbProducer::gainsCallback (const HcalGainsRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -155,7 +155,7 @@ void HcalDbProducer::gainWidthsCallback (const HcalGainWidthsRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -173,7 +173,7 @@ void HcalDbProducer::QIEDataCallback (const HcalQIEDataRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -191,7 +191,7 @@ void HcalDbProducer::channelQualityCallback (const HcalChannelQualityRcd& fRecor if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -209,7 +209,7 @@ void HcalDbProducer::respCorrsCallback (const HcalRespCorrsRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -227,7 +227,7 @@ void HcalDbProducer::LUTCorrsCallback (const HcalLUTCorrsRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -245,7 +245,7 @@ void HcalDbProducer::PFCorrsCallback (const HcalPFCorrsRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -263,7 +263,7 @@ void HcalDbProducer::timeCorrsCallback (const HcalTimeCorrsRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -281,7 +281,7 @@ void HcalDbProducer::zsThresholdsCallback (const HcalZSThresholdsRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -299,7 +299,7 @@ void HcalDbProducer::L1triggerObjectsCallback (const HcalL1TriggerObjectsRcd& fR if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } @@ -327,7 +327,7 @@ void HcalDbProducer::lutMetadataCallback (const HcalLutMetadataRcd& fRecord) { if (item->topo()==0) { edm::ESHandle htopo; - fRecord.getRecord().get(htopo); + fRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); item->setTopo(topo); } diff --git a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc index 9b59789b045e7..44cd39a7f04f5 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc +++ b/CalibCalorimetry/HcalPlugins/src/HcalHardcodeCalibrations.cc @@ -15,7 +15,7 @@ #include "CalibCalorimetry/HcalAlgos/interface/HcalDbHardcode.h" #include "CondFormats/DataRecord/interface/HcalAllRcds.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "Geometry/ForwardGeometry/interface/ZdcTopology.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" @@ -287,7 +287,7 @@ HcalHardcodeCalibrations::setIntervalFor( const edm::eventsetup::EventSetupRecor std::auto_ptr HcalHardcodeCalibrations::producePedestals (const HcalPedestalsRcd& rec) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::producePedestals-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalPedestals (topo,false)); @@ -302,7 +302,7 @@ std::auto_ptr HcalHardcodeCalibrations::producePedestals (const H std::auto_ptr HcalHardcodeCalibrations::producePedestalWidths (const HcalPedestalWidthsRcd& rec) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::producePedestalWidths-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalPedestalWidths (topo,false)); @@ -317,7 +317,7 @@ std::auto_ptr HcalHardcodeCalibrations::producePedestalWidth std::auto_ptr HcalHardcodeCalibrations::produceGains (const HcalGainsRcd& rec) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceGains-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalGains (topo)); @@ -332,7 +332,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceGains (const HcalGains std::auto_ptr HcalHardcodeCalibrations::produceGainWidths (const HcalGainWidthsRcd& rec) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceGainWidths-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalGainWidths (topo)); @@ -360,7 +360,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceQIEData (const HcalQ */ edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalQIEData (topo)); @@ -375,7 +375,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceQIEData (const HcalQ std::auto_ptr HcalHardcodeCalibrations::produceChannelQuality (const HcalChannelQualityRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceChannelQuality-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalChannelQuality (topo)); @@ -391,7 +391,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceChannelQualit std::auto_ptr HcalHardcodeCalibrations::produceRespCorrs (const HcalRespCorrsRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceRespCorrs-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalRespCorrs (topo)); @@ -435,7 +435,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceRespCorrs (const H std::auto_ptr HcalHardcodeCalibrations::produceLUTCorrs (const HcalLUTCorrsRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceLUTCorrs-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalLUTCorrs (topo)); @@ -450,7 +450,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceLUTCorrs (const Hca std::auto_ptr HcalHardcodeCalibrations::producePFCorrs (const HcalPFCorrsRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::producePFCorrs-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalPFCorrs (topo)); @@ -465,7 +465,7 @@ std::auto_ptr HcalHardcodeCalibrations::producePFCorrs (const HcalP std::auto_ptr HcalHardcodeCalibrations::produceTimeCorrs (const HcalTimeCorrsRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceTimeCorrs-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalTimeCorrs (topo)); @@ -480,7 +480,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceTimeCorrs (const H std::auto_ptr HcalHardcodeCalibrations::produceZSThresholds (const HcalZSThresholdsRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceZSThresholds-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalZSThresholds (topo)); @@ -496,7 +496,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceZSThresholds (c std::auto_ptr HcalHardcodeCalibrations::produceL1TriggerObjects (const HcalL1TriggerObjectsRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceL1TriggerObjects-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalL1TriggerObjects (topo)); @@ -525,7 +525,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceElectronicsMa std::auto_ptr HcalHardcodeCalibrations::produceValidationCorrs (const HcalValidationCorrsRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceValidationCorrs-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalValidationCorrs (topo)); @@ -540,7 +540,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceValidationCo std::auto_ptr HcalHardcodeCalibrations::produceLutMetadata (const HcalLutMetadataRcd& rcd) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceLutMetadata-> ..."; edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalLutMetadata (topo)); @@ -586,7 +586,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceDcsMap (const HcalDcs std::auto_ptr HcalHardcodeCalibrations::produceRecoParams (const HcalRecoParamsRcd& rec) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceRecoParams-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalRecoParams (topo)); @@ -600,7 +600,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceRecoParams (const std::auto_ptr HcalHardcodeCalibrations::produceTimingParams (const HcalTimingParamsRcd& rec) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceTimingParams-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalTimingParams (topo)); @@ -614,7 +614,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceTimingParams (c std::auto_ptr HcalHardcodeCalibrations::produceLongRecoParams (const HcalLongRecoParamsRcd& rec) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceLongRecoParams-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalLongRecoParams (topo)); @@ -644,7 +644,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceMCParams (const Hca edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceMCParams-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalMCParams (topo)); std::vector cells = allCells(*topo); @@ -661,7 +661,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceMCParams (const Hca std::auto_ptr HcalHardcodeCalibrations::produceFlagHFDigiTimeParams (const HcalFlagHFDigiTimeParamsRcd& rec) { edm::LogInfo("HCAL") << "HcalHardcodeCalibrations::produceFlagHFDigiTimeParams-> ..."; edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalFlagHFDigiTimeParams (topo)); @@ -689,7 +689,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceFlagHFD std::auto_ptr HcalHardcodeCalibrations::produceCholeskyMatrices (const HcalCholeskyMatricesRcd& rec) { edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalCholeskyMatrices (topo)); @@ -712,7 +712,7 @@ std::auto_ptr HcalHardcodeCalibrations::produceCholeskyMat std::auto_ptr HcalHardcodeCalibrations::produceCovarianceMatrices (const HcalCovarianceMatricesRcd& rec) { edm::ESHandle htopo; - rec.getRecord().get(htopo); + rec.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); std::auto_ptr result (new HcalCovarianceMatrices (topo)); std::vector cells = allCells(*topo); diff --git a/CalibCalorimetry/HcalPlugins/src/HcalTextCalibrations.cc b/CalibCalorimetry/HcalPlugins/src/HcalTextCalibrations.cc index d8679c8135721..2e8f7bb621b3e 100644 --- a/CalibCalorimetry/HcalPlugins/src/HcalTextCalibrations.cc +++ b/CalibCalorimetry/HcalPlugins/src/HcalTextCalibrations.cc @@ -15,7 +15,7 @@ #include "FWCore/Framework/interface/ValidityInterval.h" #include "CalibCalorimetry/HcalAlgos/interface/HcalDbASCIIIO.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "CondFormats/DataRecord/interface/HcalAllRcds.h" @@ -196,7 +196,7 @@ std::auto_ptr produce_impl (const std::string& fFile) { std::auto_ptr HcalTextCalibrations::producePedestals (const HcalPedestalsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["Pedestals"]); @@ -204,76 +204,77 @@ std::auto_ptr HcalTextCalibrations::producePedestals (const HcalP std::auto_ptr HcalTextCalibrations::producePedestalWidths (const HcalPedestalWidthsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["PedestalWidths"]); } std::auto_ptr HcalTextCalibrations::produceGains (const HcalGainsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["Gains"]); } std::auto_ptr HcalTextCalibrations::produceGainWidths (const HcalGainWidthsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["GainWidths"]); } std::auto_ptr HcalTextCalibrations::produceQIEData (const HcalQIEDataRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["QIEData"]); } std::auto_ptr HcalTextCalibrations::produceChannelQuality (const HcalChannelQualityRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["ChannelQuality"]); } -std::auto_ptr HcalTextCalibrations::produceZSThresholds (const HcalZSThresholdsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); +std::auto_ptr HcalTextCalibrations::produceZSThresholds (const HcalZSThresholdsRcd& rcd) { + edm::ESHandle htopo; + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["ZSThresholds"]); } std::auto_ptr HcalTextCalibrations::produceRespCorrs (const HcalRespCorrsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["RespCorrs"]); } std::auto_ptr HcalTextCalibrations::produceLUTCorrs (const HcalLUTCorrsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["LUTCorrs"]); } std::auto_ptr HcalTextCalibrations::producePFCorrs (const HcalPFCorrsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["PFCorrs"]); } std::auto_ptr HcalTextCalibrations::produceTimeCorrs (const HcalTimeCorrsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["TimeCorrs"]); } std::auto_ptr HcalTextCalibrations::produceL1TriggerObjects (const HcalL1TriggerObjectsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["L1TriggerObjects"]); } @@ -284,14 +285,14 @@ std::auto_ptr HcalTextCalibrations::produceElectronicsMap (c std::auto_ptr HcalTextCalibrations::produceValidationCorrs (const HcalValidationCorrsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["ValidationCorrs"]); } std::auto_ptr HcalTextCalibrations::produceLutMetadata (const HcalLutMetadataRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["LutMetadata"]); } @@ -307,47 +308,47 @@ std::auto_ptr HcalTextCalibrations::produceDcsMap (const HcalDcsMapR std::auto_ptr HcalTextCalibrations::produceCovarianceMatrices (const HcalCovarianceMatricesRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["CovarianceMatrices"]); } std::auto_ptr HcalTextCalibrations::produceCholeskyMatrices (const HcalCholeskyMatricesRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["CholeskyMatrices"]); } std::auto_ptr HcalTextCalibrations::produceRecoParams (const HcalRecoParamsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["RecoParams"]); } std::auto_ptr HcalTextCalibrations::produceLongRecoParams (const HcalLongRecoParamsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["LongRecoParams"]); } std::auto_ptr HcalTextCalibrations::produceTimingParams (const HcalTimingParamsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["TimingParams"]); } std::auto_ptr HcalTextCalibrations::produceMCParams (const HcalMCParamsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["MCParams"]); } std::auto_ptr HcalTextCalibrations::produceFlagHFDigiTimeParams (const HcalFlagHFDigiTimeParamsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo,mInputs ["FlagHFDigiTimeParams"]); } diff --git a/CalibCalorimetry/HcalStandardModules/src/HcalPedestalAnalyzer.cc b/CalibCalorimetry/HcalStandardModules/src/HcalPedestalAnalyzer.cc index a85df90bbb4ae..759648db0ec2a 100644 --- a/CalibCalorimetry/HcalStandardModules/src/HcalPedestalAnalyzer.cc +++ b/CalibCalorimetry/HcalStandardModules/src/HcalPedestalAnalyzer.cc @@ -215,9 +215,8 @@ void HcalPedestalAnalyzer::analyze(const edm::Event& e, const edm::EventSetup& e eventSetup.get().get(conditions); if (m_topo==0) { - const IdealGeometryRecord& record = eventSetup.get(); edm::ESHandle topology; - record.get (topology); + eventSetup.get().get( topology ); m_topo=new HcalTopology(*topology); } diff --git a/CalibCalorimetry/HcalTPGEventSetup/src/HcalTPGCoderULUT.cc b/CalibCalorimetry/HcalTPGEventSetup/src/HcalTPGCoderULUT.cc index 8b39b53bea4de..74352a644aea0 100644 --- a/CalibCalorimetry/HcalTPGEventSetup/src/HcalTPGCoderULUT.cc +++ b/CalibCalorimetry/HcalTPGEventSetup/src/HcalTPGCoderULUT.cc @@ -34,6 +34,7 @@ #include "FWCore/MessageLogger/interface/MessageLogger.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" #include "CalibFormats/HcalObjects/interface/HcalDbService.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" // // class decleration @@ -129,7 +130,7 @@ HcalTPGCoderULUT::produce(const HcalTPGRecord& iRecord) { if (theCoder_==0) { edm::ESHandle htopo; - iRecord.getRecord().get(htopo); + iRecord.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); buildCoder(topo); } diff --git a/CalibFormats/HcalObjects/interface/HcalTPGRecord.h b/CalibFormats/HcalObjects/interface/HcalTPGRecord.h index 0e6020c3815b0..bd290b1a67600 100644 --- a/CalibFormats/HcalObjects/interface/HcalTPGRecord.h +++ b/CalibFormats/HcalObjects/interface/HcalTPGRecord.h @@ -21,7 +21,8 @@ #include "FWCore/Framework/interface/EventSetupRecordImplementation.h" #include "CalibFormats/HcalObjects/interface/HcalDbRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalTPGRecord : public edm::eventsetup::DependentRecordImplementation >{}; +class HcalTPGRecord : public edm::eventsetup::DependentRecordImplementation >{}; #endif diff --git a/Calibration/HcalCalibAlgos/src/HcalCalibrator.cc b/Calibration/HcalCalibAlgos/src/HcalCalibrator.cc index 022e4085f6baf..93f55f3e81cb2 100644 --- a/Calibration/HcalCalibAlgos/src/HcalCalibrator.cc +++ b/Calibration/HcalCalibAlgos/src/HcalCalibrator.cc @@ -123,7 +123,7 @@ HcalCalibrator::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetup) iSetup.get().get(pG); mTheCaloGeometry = pG.product(); edm::ESHandle pT; - iSetup.get().get(pT); + iSetup.get().get(pT); mTheHcalTopology = pT.product(); } diff --git a/Calibration/IsolatedParticles/plugins/IsolatedGenParticles.cc b/Calibration/IsolatedParticles/plugins/IsolatedGenParticles.cc index a42e0585bdf81..3f644191d4054 100644 --- a/Calibration/IsolatedParticles/plugins/IsolatedGenParticles.cc +++ b/Calibration/IsolatedParticles/plugins/IsolatedGenParticles.cc @@ -121,7 +121,7 @@ void IsolatedGenParticles::analyze(const edm::Event& iEvent, const edm::EventSet const CaloTopology *caloTopology = theCaloTopology.product(); edm::ESHandle htopo; - iSetup.get().get(htopo); + iSetup.get().get(htopo); const HcalTopology* theHBHETopology = htopo.product(); //===================== save L1 Trigger information ======================= diff --git a/Calibration/IsolatedParticles/plugins/IsolatedTracksCone.cc b/Calibration/IsolatedParticles/plugins/IsolatedTracksCone.cc index 4359a06a8fb96..735ffb765fe7b 100644 --- a/Calibration/IsolatedParticles/plugins/IsolatedTracksCone.cc +++ b/Calibration/IsolatedParticles/plugins/IsolatedTracksCone.cc @@ -183,7 +183,7 @@ void IsolatedTracksCone::analyze(const edm::Event& iEvent, // const CaloSubdetectorTopology* theEETopology = theCaloTopology->getSubdetectorTopology(DetId::Ecal,EcalEndcap); edm::ESHandle htopo; - iSetup.get().get(htopo); + iSetup.get().get(htopo); const HcalTopology* theHBHETopology = htopo.product(); edm::Handle barrelRecHitsHandle; diff --git a/Calibration/IsolatedParticles/plugins/IsolatedTracksHcalScale.cc b/Calibration/IsolatedParticles/plugins/IsolatedTracksHcalScale.cc index f1abbe3729e62..abc71a27d495e 100644 --- a/Calibration/IsolatedParticles/plugins/IsolatedTracksHcalScale.cc +++ b/Calibration/IsolatedParticles/plugins/IsolatedTracksHcalScale.cc @@ -81,12 +81,6 @@ void IsolatedTracksHcalScale::analyze(const edm::Event& iEvent, const edm::Event iSetup.get().get(theCaloTopology); const CaloTopology *caloTopology = theCaloTopology.product(); - /* - edm::ESHandle htopo; - iSetup.get().get(htopo); - const HcalTopology* theHBHETopology = htopo.product(); - */ - // Retrieve the good/bad ECAL channels from the DB edm::ESHandle ecalChStatus; iSetup.get().get(ecalChStatus); diff --git a/Calibration/IsolatedParticles/plugins/IsolatedTracksNxN.cc b/Calibration/IsolatedParticles/plugins/IsolatedTracksNxN.cc index 0b265e3f20dae..2dd82d69bbaf8 100644 --- a/Calibration/IsolatedParticles/plugins/IsolatedTracksNxN.cc +++ b/Calibration/IsolatedParticles/plugins/IsolatedTracksNxN.cc @@ -400,7 +400,7 @@ void IsolatedTracksNxN::analyze(const edm::Event& iEvent, const edm::EventSetup& const CaloTopology *caloTopology = theCaloTopology.product(); edm::ESHandle htopo; - iSetup.get().get(htopo); + iSetup.get().get(htopo); const HcalTopology* theHBHETopology = htopo.product(); edm::Handle barrelRecHitsHandle; diff --git a/Calibration/IsolatedParticles/plugins/StudyHLT.cc b/Calibration/IsolatedParticles/plugins/StudyHLT.cc index dfef39e05d928..6695119302c6b 100644 --- a/Calibration/IsolatedParticles/plugins/StudyHLT.cc +++ b/Calibration/IsolatedParticles/plugins/StudyHLT.cc @@ -142,7 +142,7 @@ void StudyHLT::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetup) const CaloTopology *caloTopology = theCaloTopology.product(); edm::ESHandle htopo; - iSetup.get().get(htopo); + iSetup.get().get(htopo); const HcalTopology* theHBHETopology = htopo.product(); edm::ESHandle bFieldH; diff --git a/CaloOnlineTools/HcalOnlineDb/src/HcalOmdsCalibrations.cc b/CaloOnlineTools/HcalOnlineDb/src/HcalOmdsCalibrations.cc index 79a38e4040152..6a08bf219a33a 100644 --- a/CaloOnlineTools/HcalOnlineDb/src/HcalOmdsCalibrations.cc +++ b/CaloOnlineTools/HcalOnlineDb/src/HcalOmdsCalibrations.cc @@ -200,7 +200,7 @@ std::auto_ptr produce_impl (const std::string & fTag, std::auto_ptr HcalOmdsCalibrations::producePedestals (const HcalPedestalsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["Pedestals"], @@ -213,7 +213,7 @@ std::auto_ptr HcalOmdsCalibrations::producePedestals (const HcalP std::auto_ptr HcalOmdsCalibrations::producePedestalWidths (const HcalPedestalWidthsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["PedestalWidths"], mVersion["PedestalWidths"], @@ -225,7 +225,7 @@ std::auto_ptr HcalOmdsCalibrations::producePedestalWidths (c std::auto_ptr HcalOmdsCalibrations::produceGains (const HcalGainsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["Gains"], mVersion["Gains"], @@ -237,7 +237,7 @@ std::auto_ptr HcalOmdsCalibrations::produceGains (const HcalGainsRcd& std::auto_ptr HcalOmdsCalibrations::produceGainWidths (const HcalGainWidthsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["GainWidths"], mVersion["GainWidths"], @@ -249,7 +249,7 @@ std::auto_ptr HcalOmdsCalibrations::produceGainWidths (const Hca std::auto_ptr HcalOmdsCalibrations::produceQIEData (const HcalQIEDataRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["QIEData"], mVersion["QIEData"], @@ -261,7 +261,7 @@ std::auto_ptr HcalOmdsCalibrations::produceQIEData (const HcalQIEDa std::auto_ptr HcalOmdsCalibrations::produceChannelQuality (const HcalChannelQualityRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["ChannelQuality"], mVersion["ChannelQuality"], @@ -273,7 +273,7 @@ std::auto_ptr HcalOmdsCalibrations::produceChannelQuality (c std::auto_ptr HcalOmdsCalibrations::produceZSThresholds (const HcalZSThresholdsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["ZSThresholds"], mVersion["ZSThresholds"], @@ -285,7 +285,7 @@ std::auto_ptr HcalOmdsCalibrations::produceZSThresholds (const std::auto_ptr HcalOmdsCalibrations::produceRespCorrs (const HcalRespCorrsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["RespCorrs"], mVersion["RespCorrs"], @@ -297,7 +297,7 @@ std::auto_ptr HcalOmdsCalibrations::produceRespCorrs (const HcalR std::auto_ptr HcalOmdsCalibrations::produceL1TriggerObjects (const HcalL1TriggerObjectsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["L1TriggerObjects"], mVersion["L1TriggerObjects"], @@ -318,7 +318,7 @@ std::auto_ptr HcalOmdsCalibrations::produceElectronicsMap (c std::auto_ptr HcalOmdsCalibrations::produceValidationCorrs (const HcalValidationCorrsRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["ValidationCorrs"], mVersion["ValidationCorrs"], @@ -330,7 +330,7 @@ std::auto_ptr HcalOmdsCalibrations::produceValidationCorrs std::auto_ptr HcalOmdsCalibrations::produceLutMetadata (const HcalLutMetadataRcd& rcd) { edm::ESHandle htopo; - rcd.getRecord().get(htopo); + rcd.getRecord().get(htopo); const HcalTopology* topo=&(*htopo); return produce_impl (topo, mInputs ["LutMetadata"], mVersion["LutMetadata"], diff --git a/CondFormats/DataRecord/interface/HcalChannelQualityRcd.h b/CondFormats/DataRecord/interface/HcalChannelQualityRcd.h index c000e9879e277..17bcd80f45d32 100644 --- a/CondFormats/DataRecord/interface/HcalChannelQualityRcd.h +++ b/CondFormats/DataRecord/interface/HcalChannelQualityRcd.h @@ -1,8 +1,10 @@ -// this file is generated automatically by /afs/fnal.gov/files/home/room1/ratnikov/bin/makeNewClass.sh // name: ratnikov, date: Thu Oct 20 01:13:51 CDT 2005 #ifndef HcalChannelQualityRcd_H #define HcalChannelQualityRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalChannelQualityRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalChannelQualityRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalCholeskyMatricesRcd.h b/CondFormats/DataRecord/interface/HcalCholeskyMatricesRcd.h index c1807d787656b..d69063758d75f 100644 --- a/CondFormats/DataRecord/interface/HcalCholeskyMatricesRcd.h +++ b/CondFormats/DataRecord/interface/HcalCholeskyMatricesRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalCholeskyMatricesRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalCholeskyMatricesRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalCovarianceMatricesRcd.h b/CondFormats/DataRecord/interface/HcalCovarianceMatricesRcd.h index 62c02b3c606ae..6cf67206cac54 100644 --- a/CondFormats/DataRecord/interface/HcalCovarianceMatricesRcd.h +++ b/CondFormats/DataRecord/interface/HcalCovarianceMatricesRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalCovarianceMatricesRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalCovarianceMatricesRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalFlagHFDigiTimeParamsRcd.h b/CondFormats/DataRecord/interface/HcalFlagHFDigiTimeParamsRcd.h index f3cdab9766836..cc619e3683e6f 100644 --- a/CondFormats/DataRecord/interface/HcalFlagHFDigiTimeParamsRcd.h +++ b/CondFormats/DataRecord/interface/HcalFlagHFDigiTimeParamsRcd.h @@ -1,6 +1,9 @@ #ifndef HcalFlagHFDigiTimeParamsRcd_H #define HcalFlagHFDigiTimeParamsRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalFlagHFDigiTimeParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalFlagHFDigiTimeParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalGainWidthsRcd.h b/CondFormats/DataRecord/interface/HcalGainWidthsRcd.h index 458734e44e0a8..7da16f7bba161 100644 --- a/CondFormats/DataRecord/interface/HcalGainWidthsRcd.h +++ b/CondFormats/DataRecord/interface/HcalGainWidthsRcd.h @@ -1,8 +1,10 @@ -// this file is generated automatically by /afs/fnal.gov/files/home/room1/ratnikov/bin/makeNewClass.sh // name: ratnikov, date: Mon Sep 26 17:02:44 CDT 2005 #ifndef HcalGainWidthsRcd_H #define HcalGainWidthsRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalGainWidthsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalGainWidthsRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalGainsRcd.h b/CondFormats/DataRecord/interface/HcalGainsRcd.h index b116025f67754..9baa5db8b1cce 100644 --- a/CondFormats/DataRecord/interface/HcalGainsRcd.h +++ b/CondFormats/DataRecord/interface/HcalGainsRcd.h @@ -1,8 +1,10 @@ -// this file is generated automatically by /afs/fnal.gov/files/home/room1/ratnikov/bin/makeNewClass.sh // name: ratnikov, date: Mon Sep 26 17:02:30 CDT 2005 #ifndef HcalGainsRcd_H #define HcalGainsRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalGainsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalGainsRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalL1TriggerObjectsRcd.h b/CondFormats/DataRecord/interface/HcalL1TriggerObjectsRcd.h index fa44d783b3a3c..f410de9b8b686 100644 --- a/CondFormats/DataRecord/interface/HcalL1TriggerObjectsRcd.h +++ b/CondFormats/DataRecord/interface/HcalL1TriggerObjectsRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalL1TriggerObjectsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalL1TriggerObjectsRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalLUTCorrsRcd.h b/CondFormats/DataRecord/interface/HcalLUTCorrsRcd.h index 95dc11c10836e..7aa68097d8eed 100644 --- a/CondFormats/DataRecord/interface/HcalLUTCorrsRcd.h +++ b/CondFormats/DataRecord/interface/HcalLUTCorrsRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalLUTCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalLUTCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalLongRecoParamsRcd.h b/CondFormats/DataRecord/interface/HcalLongRecoParamsRcd.h index 953e32eca148f..f6637dc35f128 100644 --- a/CondFormats/DataRecord/interface/HcalLongRecoParamsRcd.h +++ b/CondFormats/DataRecord/interface/HcalLongRecoParamsRcd.h @@ -1,6 +1,9 @@ #ifndef HcalLongRecoParamsRcd_H #define HcalLongRecoParamsRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalLongRecoParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalLongRecoParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalLutMetadataRcd.h b/CondFormats/DataRecord/interface/HcalLutMetadataRcd.h index c1f6a47adbf95..5aef2b4734bc4 100644 --- a/CondFormats/DataRecord/interface/HcalLutMetadataRcd.h +++ b/CondFormats/DataRecord/interface/HcalLutMetadataRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalLutMetadataRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalLutMetadataRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalMCParamsRcd.h b/CondFormats/DataRecord/interface/HcalMCParamsRcd.h index 8f7f3f4eca565..dcb8529aa2ea8 100644 --- a/CondFormats/DataRecord/interface/HcalMCParamsRcd.h +++ b/CondFormats/DataRecord/interface/HcalMCParamsRcd.h @@ -1,6 +1,9 @@ #ifndef HcalMCParamsRcd_H #define HcalMCParamsRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalMCParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalMCParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalPFCorrsRcd.h b/CondFormats/DataRecord/interface/HcalPFCorrsRcd.h index 3389297d8ced4..cab0a76e301a1 100644 --- a/CondFormats/DataRecord/interface/HcalPFCorrsRcd.h +++ b/CondFormats/DataRecord/interface/HcalPFCorrsRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalPFCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalPFCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalPedestalWidthsRcd.h b/CondFormats/DataRecord/interface/HcalPedestalWidthsRcd.h index af6fcf2a91667..d2195fca36471 100644 --- a/CondFormats/DataRecord/interface/HcalPedestalWidthsRcd.h +++ b/CondFormats/DataRecord/interface/HcalPedestalWidthsRcd.h @@ -1,8 +1,10 @@ -// this file is generated automatically by /afs/fnal.gov/files/home/room1/ratnikov/bin/makeNewClass.sh // name: ratnikov, date: Mon Sep 26 17:02:35 CDT 2005 #ifndef HcalPedestalWidthsRcd_H #define HcalPedestalWidthsRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalPedestalWidthsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalPedestalWidthsRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalPedestalsRcd.h b/CondFormats/DataRecord/interface/HcalPedestalsRcd.h index d3a3a83ddef56..4dc1745a87e8b 100644 --- a/CondFormats/DataRecord/interface/HcalPedestalsRcd.h +++ b/CondFormats/DataRecord/interface/HcalPedestalsRcd.h @@ -3,7 +3,7 @@ #ifndef HcalPedestalsRcd_H #define HcalPedestalsRcd_H #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalPedestalsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalPedestalsRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalQIEDataRcd.h b/CondFormats/DataRecord/interface/HcalQIEDataRcd.h index 7aa25801203a1..92b0484634bf7 100644 --- a/CondFormats/DataRecord/interface/HcalQIEDataRcd.h +++ b/CondFormats/DataRecord/interface/HcalQIEDataRcd.h @@ -1,8 +1,10 @@ -// this file is generated automatically by /afs/fnal.gov/files/home/room1/ratnikov/bin/makeNewClass.sh // name: ratnikov, date: Tue Oct 18 19:00:40 CDT 2005 #ifndef HcalQIEDataRcd_H #define HcalQIEDataRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalQIEDataRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalQIEDataRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalRecoParamsRcd.h b/CondFormats/DataRecord/interface/HcalRecoParamsRcd.h index 8975a3301f529..3f7e6c103bdcc 100644 --- a/CondFormats/DataRecord/interface/HcalRecoParamsRcd.h +++ b/CondFormats/DataRecord/interface/HcalRecoParamsRcd.h @@ -1,6 +1,9 @@ #ifndef HcalRecoParamsRcd_H #define HcalRecoParamsRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalRecoParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalRecoParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalRespCorrsRcd.h b/CondFormats/DataRecord/interface/HcalRespCorrsRcd.h index 404205c550234..2a7ff55b8dc99 100644 --- a/CondFormats/DataRecord/interface/HcalRespCorrsRcd.h +++ b/CondFormats/DataRecord/interface/HcalRespCorrsRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalRespCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalRespCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalTimeCorrsRcd.h b/CondFormats/DataRecord/interface/HcalTimeCorrsRcd.h index 0885ffa2782bf..f60fe6c7356d9 100644 --- a/CondFormats/DataRecord/interface/HcalTimeCorrsRcd.h +++ b/CondFormats/DataRecord/interface/HcalTimeCorrsRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalTimeCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalTimeCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalTimingParamsRcd.h b/CondFormats/DataRecord/interface/HcalTimingParamsRcd.h index 7916f4df0f391..79b3e623f71d9 100644 --- a/CondFormats/DataRecord/interface/HcalTimingParamsRcd.h +++ b/CondFormats/DataRecord/interface/HcalTimingParamsRcd.h @@ -1,6 +1,9 @@ #ifndef HcalTimingParamsRcd_H #define HcalTimingParamsRcd_H + #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" -class HcalTimingParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" + +class HcalTimingParamsRcd : public edm::eventsetup::DependentRecordImplementation > {}; + #endif diff --git a/CondFormats/DataRecord/interface/HcalValidationCorrsRcd.h b/CondFormats/DataRecord/interface/HcalValidationCorrsRcd.h index f6018d38f785b..d07944278beb1 100644 --- a/CondFormats/DataRecord/interface/HcalValidationCorrsRcd.h +++ b/CondFormats/DataRecord/interface/HcalValidationCorrsRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalValidationCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalValidationCorrsRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondFormats/DataRecord/interface/HcalZSThresholdsRcd.h b/CondFormats/DataRecord/interface/HcalZSThresholdsRcd.h index f13e486c1523f..939bb2286f09d 100644 --- a/CondFormats/DataRecord/interface/HcalZSThresholdsRcd.h +++ b/CondFormats/DataRecord/interface/HcalZSThresholdsRcd.h @@ -20,8 +20,8 @@ // #include "FWCore/Framework/interface/DependentRecordImplementation.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" -class HcalZSThresholdsRcd : public edm::eventsetup::DependentRecordImplementation > {}; +class HcalZSThresholdsRcd : public edm::eventsetup::DependentRecordImplementation > {}; #endif diff --git a/CondTools/Geometry/plugins/calowriters.cc b/CondTools/Geometry/plugins/calowriters.cc index 217aeed044d78..3340fe9a6f5fc 100644 --- a/CondTools/Geometry/plugins/calowriters.cc +++ b/CondTools/Geometry/plugins/calowriters.cc @@ -59,7 +59,7 @@ CaloGeometryDBEP::produceAligned( const type //********************************************************************************************* edm::ESHandle hcalTopology; - iRecord.getRecord().get( hcalTopology ); + iRecord.getRecord().get( hcalTopology ); // We know that the numer of shapes chanes with changing depth // so, this check is temporary disabled. We need to implement diff --git a/CondTools/Hcal/plugins/HcalDumpConditions.cc b/CondTools/Hcal/plugins/HcalDumpConditions.cc index 39b6fea5acafe..580a24485aa76 100644 --- a/CondTools/Hcal/plugins/HcalDumpConditions.cc +++ b/CondTools/Hcal/plugins/HcalDumpConditions.cc @@ -31,7 +31,7 @@ September 21, 2009 Added HcalLutMetadata - Gena Kukartsev #include "CalibFormats/HcalObjects/interface/HcalDbService.h" #include "CalibFormats/HcalObjects/interface/HcalDbRecord.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "FWCore/Framework/interface/IOVSyncValue.h" #include "CondFormats/HcalObjects/interface/AllObjects.h" @@ -84,7 +84,7 @@ namespace edmtest HcalDumpConditions::analyze(const edm::Event& e, const edm::EventSetup& context) { edm::ESHandle topology ; - context.get().get( topology ); + context.get().get( topology ); using namespace edm::eventsetup; std::cout <<"HcalDumpConditions::analyze-> I AM IN RUN NUMBER "< #include #include "CondFormats/HcalObjects/interface/HcalLogicalMap.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "CalibCalorimetry/HcalAlgos/interface/HcalLogicalMapGenerator.h" #include "FWCore/Framework/interface/ESHandle.h" @@ -214,7 +214,7 @@ void HcalBaseDQClient::htmlOutput(std::string htmlDir) void HcalBaseDQClient::getLogicalMap(const edm::EventSetup& c) { if (needLogicalMap_ && logicalMap_==0) { edm::ESHandle pT; - c.get().get(pT); + c.get().get(pT); HcalLogicalMapGenerator gen; logicalMap_=new HcalLogicalMap(gen.createMap(&(*pT))); } diff --git a/DQM/HcalMonitorClient/src/HcalMonitorClient.cc b/DQM/HcalMonitorClient/src/HcalMonitorClient.cc index ec951f81d186c..58feb5333da44 100644 --- a/DQM/HcalMonitorClient/src/HcalMonitorClient.cc +++ b/DQM/HcalMonitorClient/src/HcalMonitorClient.cc @@ -192,7 +192,7 @@ void HcalMonitorClient::beginRun(const edm::Run& r, const edm::EventSetup& c) // Let's get the channel status quality edm::ESHandle topo; - c.get().get(topo); + c.get().get(topo); edm::ESHandle p; c.get().get(p); diff --git a/DQM/HcalMonitorTasks/src/HcalBaseDQMonitor.cc b/DQM/HcalMonitorTasks/src/HcalBaseDQMonitor.cc index 2b781eb09d633..ce8f8f862c0d8 100644 --- a/DQM/HcalMonitorTasks/src/HcalBaseDQMonitor.cc +++ b/DQM/HcalMonitorTasks/src/HcalBaseDQMonitor.cc @@ -1,7 +1,7 @@ #include #include "FWCore/Framework/interface/LuminosityBlock.h" #include "CondFormats/HcalObjects/interface/HcalLogicalMap.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "CalibCalorimetry/HcalAlgos/interface/HcalLogicalMapGenerator.h" #include @@ -222,7 +222,7 @@ bool HcalBaseDQMonitor::IsAllowedCalibType() void HcalBaseDQMonitor::getLogicalMap(const edm::EventSetup& c) { if (needLogicalMap_ && logicalMap_==0) { edm::ESHandle pT; - c.get().get(pT); + c.get().get(pT); HcalLogicalMapGenerator gen; logicalMap_=new HcalLogicalMap(gen.createMap(&(*pT))); } diff --git a/FastSimulation/CaloRecHitsProducer/src/CaloRecHitsProducer.cc b/FastSimulation/CaloRecHitsProducer/src/CaloRecHitsProducer.cc index 2f8d518f9c38a..d918310bc4807 100644 --- a/FastSimulation/CaloRecHitsProducer/src/CaloRecHitsProducer.cc +++ b/FastSimulation/CaloRecHitsProducer/src/CaloRecHitsProducer.cc @@ -14,7 +14,7 @@ #include "FastSimulation/CaloRecHitsProducer/interface/EcalEndcapRecHitsMaker.h" #include "FastSimulation/CaloRecHitsProducer/interface/EcalPreshowerRecHitsMaker.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "FWCore/Framework/interface/EventSetup.h" // Random engine @@ -191,7 +191,7 @@ void CaloRecHitsProducer::endJob() void CaloRecHitsProducer::produce(edm::Event & iEvent, const edm::EventSetup & es) { edm::ESHandle topo; - es.get().get( topo ); + es.get().get( topo ); // create empty outputs for HCAL diff --git a/FastSimulation/CaloRecHitsProducer/src/HcalRecHitsMaker.cc b/FastSimulation/CaloRecHitsProducer/src/HcalRecHitsMaker.cc index b7430e56e3004..76208f8c315ab 100644 --- a/FastSimulation/CaloRecHitsProducer/src/HcalRecHitsMaker.cc +++ b/FastSimulation/CaloRecHitsProducer/src/HcalRecHitsMaker.cc @@ -165,7 +165,7 @@ void HcalRecHitsMaker::init(const edm::EventSetup &es,bool doDigis,bool doMiscal CaloMiscalibMapHcal mapHcal; edm::ESHandle topo; - es.get().get( topo ); + es.get().get( topo ); mapHcal.prefillMap(*topo); edm::FileInPath hcalfiletmp("CalibCalorimetry/CaloMiscalibTools/data/"+hcalfileinpath_); @@ -545,7 +545,7 @@ unsigned HcalRecHitsMaker::createVectorsOfCells(const edm::EventSetup &es) edm::ESHandle pG; es.get().get(pG); edm::ESHandle topo; - es.get().get( topo ); + es.get().get( topo ); nhbcells_ = createVectorOfSubdetectorCells(*pG, *topo, HcalBarrel, hbhi_); nhecells_ = createVectorOfSubdetectorCells(*pG, *topo, HcalEndcap, hehi_); diff --git a/FastSimulation/L1CaloTriggerProducer/src/FastL1GlobalAlgo.cc b/FastSimulation/L1CaloTriggerProducer/src/FastL1GlobalAlgo.cc index 736492afe523b..44768a8f8a242 100644 --- a/FastSimulation/L1CaloTriggerProducer/src/FastL1GlobalAlgo.cc +++ b/FastSimulation/L1CaloTriggerProducer/src/FastL1GlobalAlgo.cc @@ -755,7 +755,7 @@ FastL1GlobalAlgo::FillL1Regions(edm::Event const& e, const edm::EventSetup& c) e.getByLabel(m_L1Config.TowerInput,input); edm::ESHandle cttopo; - c.get().get(cttopo); + c.get().get(cttopo); const CaloTowerConstituentsMap* theTowerConstituentsMap = cttopo.product(); edm::ESHandle calotopo; diff --git a/Geometry/CMSCommonData/python/cmsExtendedGeometry2017XML_cfi.py b/Geometry/CMSCommonData/python/cmsExtendedGeometry2017XML_cfi.py index 38d33f3afc824..872b60160b8a8 100644 --- a/Geometry/CMSCommonData/python/cmsExtendedGeometry2017XML_cfi.py +++ b/Geometry/CMSCommonData/python/cmsExtendedGeometry2017XML_cfi.py @@ -8,6 +8,7 @@ 'Geometry/CMSCommonData/data/extend/cmsextent.xml', 'Geometry/CMSCommonData/data/PhaseI/cms.xml', 'Geometry/CMSCommonData/data/cmsMother.xml', + 'Geometry/CMSCommonData/data/eta3/etaMax.xml', 'Geometry/CMSCommonData/data/cmsTracker.xml', 'Geometry/CMSCommonData/data/caloBase.xml', 'Geometry/CMSCommonData/data/cmsCalo.xml', @@ -213,9 +214,9 @@ 'Geometry/EcalCommonData/data/eeF.xml', 'Geometry/EcalCommonData/data/eeB.xml', 'Geometry/HcalCommonData/data/hcalrotations.xml', - 'Geometry/HcalCommonData/data/hcalalgo.xml', + 'Geometry/HcalCommonData/data/PhaseI/hcalalgo.xml', 'Geometry/HcalCommonData/data/hcalbarrelalgo.xml', - 'Geometry/HcalCommonData/data/hcalendcapalgo.xml', + 'Geometry/HcalCommonData/data/PhaseI/hcalendcapalgo.xml', 'Geometry/HcalCommonData/data/hcalouteralgo.xml', 'Geometry/HcalCommonData/data/hcalforwardalgo.xml', 'Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml', @@ -253,7 +254,7 @@ 'Geometry/TrackerSimData/data/PhaseI/trackersens.xml', 'Geometry/TrackerRecoData/data/PhaseI/trackerRecoMaterial.xml', 'Geometry/EcalSimData/data/ecalsens.xml', - 'Geometry/HcalCommonData/data/hcalsenspmf.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalsenspmf.xml', 'Geometry/HcalSimData/data/hf.xml', 'Geometry/HcalSimData/data/hfpmt.xml', 'Geometry/HcalSimData/data/hffibrebundle.xml', diff --git a/Geometry/CaloEventSetup/plugins/CaloTowerConstituentsMapBuilder.cc b/Geometry/CaloEventSetup/plugins/CaloTowerConstituentsMapBuilder.cc index 1cd67a6209b07..d80be2cace104 100644 --- a/Geometry/CaloEventSetup/plugins/CaloTowerConstituentsMapBuilder.cc +++ b/Geometry/CaloEventSetup/plugins/CaloTowerConstituentsMapBuilder.cc @@ -57,7 +57,7 @@ CaloTowerConstituentsMapBuilder::fillDescriptions(edm::ConfigurationDescriptions // ------------ method called to produce the data ------------ CaloTowerConstituentsMapBuilder::ReturnType -CaloTowerConstituentsMapBuilder::produce(const IdealGeometryRecord& iRecord) +CaloTowerConstituentsMapBuilder::produce(const HcalRecNumberingRecord& iRecord) { edm::ESHandle topology ; iRecord.get( topology ) ; diff --git a/Geometry/CaloEventSetup/plugins/CaloTowerConstituentsMapBuilder.h b/Geometry/CaloEventSetup/plugins/CaloTowerConstituentsMapBuilder.h index 76ffc9f351b2f..2acc26964e793 100644 --- a/Geometry/CaloEventSetup/plugins/CaloTowerConstituentsMapBuilder.h +++ b/Geometry/CaloEventSetup/plugins/CaloTowerConstituentsMapBuilder.h @@ -27,7 +27,7 @@ #include "FWCore/Framework/interface/ESHandle.h" #include "FWCore/ParameterSet/interface/ParameterSet.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "Geometry/CaloTopology/interface/CaloTowerConstituentsMap.h" namespace edm { @@ -45,7 +45,7 @@ class CaloTowerConstituentsMapBuilder : public edm::ESProducer { typedef std::auto_ptr ReturnType; - ReturnType produce(const IdealGeometryRecord&); + ReturnType produce(const HcalRecNumberingRecord&); static void fillDescriptions(edm::ConfigurationDescriptions & descriptions); private: diff --git a/Geometry/CaloEventSetup/python/CaloGeometry_cff.py b/Geometry/CaloEventSetup/python/CaloGeometry_cff.py index 034ca28dec973..ec93c5e6099f2 100644 --- a/Geometry/CaloEventSetup/python/CaloGeometry_cff.py +++ b/Geometry/CaloEventSetup/python/CaloGeometry_cff.py @@ -4,6 +4,6 @@ from Geometry.EcalAlgo.EcalGeometry_cfi import * from Geometry.HcalEventSetup.HcalGeometry_cfi import * from Geometry.HcalEventSetup.CaloTowerGeometry_cfi import * -from Geometry.HcalEventSetup.HcalTopology_cfi import * +from Geometry.HcalEventSetup.hcalTopologyIdeal_cfi import * from Geometry.ForwardGeometry.ForwardGeometry_cfi import * diff --git a/Geometry/CaloEventSetup/test/CaloGeometryAnalyzer.cc b/Geometry/CaloEventSetup/test/CaloGeometryAnalyzer.cc index 60c2cf7608482..20e5dfb7fe2cb 100644 --- a/Geometry/CaloEventSetup/test/CaloGeometryAnalyzer.cc +++ b/Geometry/CaloEventSetup/test/CaloGeometryAnalyzer.cc @@ -1271,7 +1271,7 @@ CaloGeometryAnalyzer::analyze( const edm::Event& /*iEvent*/, const edm::EventSet edm::ESHandle pG; iSetup.get().get(pG); edm::ESHandle pT; - iSetup.get().get(pT); + iSetup.get().get(pT); const std::vector allDetId ( pG->getValidDetIds() ) ; // std::cout<<"Total number of DetIds in all subdets is = "<0) retval+=maxDepthHB_*72*(hid.ieta()-1); + else retval+=maxDepthHB_*72*(32+hid.ieta()); } return retval; } @@ -622,7 +624,9 @@ unsigned int HcalTopology::detId2denseIdHE(const DetId& id) const { ( ( ie>=27 && ie<=28 ) ? 20 + 3*( ie - 27 ) + dp - 1 : 26 + 2*( ie - 29 ) + dp - 1 ) ) ) ) + zn*kHEhalf; } else if (topoVersion_==10) { - retval=(dp-1)+maxDepthHE_*(ip-1)+maxDepthHE_*72*(hid.ieta()-16+zn*(14+29+16)); + retval=(dp-1)+maxDepthHE_*(ip-1); + if (hid.ieta()>0) retval+=maxDepthHE_*72*(hid.ieta()-16); + else retval+=maxDepthHE_*72*((14+29)+hid.ieta()); } return retval; } @@ -637,7 +641,8 @@ unsigned int HcalTopology::detId2denseIdHO(const DetId& id) const { if (topoVersion_==0) { retval=( ip - 1 )*15 + ( ie - 1 ) + zn*kHOhalf; } else if (topoVersion_==10) { - retval=( ip - 1 )*15 + ( ie - 1 ) + zn*kHOhalf; + if (hid.ieta()>0) retval=(ip-1)+72*(hid.ieta()-1); + else retval=(ip-1)+72*(30+hid.ieta()); } return retval; } @@ -654,8 +659,9 @@ unsigned int HcalTopology::detId2denseIdHF(const DetId& id) const { retval = ( ( ip - 1 )/4 )*4 + ( ( ip - 1 )/2 )*22 + 2*( ie - 29 ) + ( dp - 1 ) + zn*kHFhalf; } else if (topoVersion_==10) { - retval = ( ( ip - 1 )/4 )*4 + ( ( ip - 1 )/2 )*22 + - 2*( ie - 29 ) + ( dp - 1 ) + zn*kHFhalf; + retval=dp-1+2*(ip-1); + if (hid.ieta()>0) retval+=2*72*(hid.ieta()-29); + else retval+=2*72*((41+13)+hid.ieta()); } return retval; } diff --git a/Geometry/CaloTopology/test/BuildFile.xml b/Geometry/CaloTopology/test/BuildFile.xml index e777e770913c2..626f839ee844d 100644 --- a/Geometry/CaloTopology/test/BuildFile.xml +++ b/Geometry/CaloTopology/test/BuildFile.xml @@ -1,7 +1,10 @@ - - - - + + + + + + + diff --git a/Geometry/CaloTopology/test/testHcalTopology.cpp b/Geometry/CaloTopology/test/HcalTopologyTester.cc similarity index 51% rename from Geometry/CaloTopology/test/testHcalTopology.cpp rename to Geometry/CaloTopology/test/HcalTopologyTester.cc index 82b5e24326678..d00c941d95056 100644 --- a/Geometry/CaloTopology/test/testHcalTopology.cpp +++ b/Geometry/CaloTopology/test/HcalTopologyTester.cc @@ -2,18 +2,61 @@ #include #include +#include "FWCore/ParameterSet/interface/ParameterSet.h" +#include "FWCore/Framework/interface/Frameworkfwd.h" +#include "FWCore/Framework/interface/EDAnalyzer.h" + +#include "FWCore/Framework/interface/Event.h" +#include "FWCore/Framework/interface/EventSetup.h" +#include "FWCore/Framework/interface/ESTransientHandle.h" +#include "FWCore/Framework/interface/ESHandle.h" +#include "FWCore/Framework/interface/MakerMacros.h" + +#include "DetectorDescription/Core/interface/DDCompactView.h" +#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" +#include "Geometry/HcalCommonData/interface/HcalDDDRecConstants.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" #include "DataFormats/HcalDetId/interface/HcalDetId.h" #include "DataFormats/HcalDetId/interface/HcalSubdetector.h" +#include "CoralBase/Exception.h" + +class HcalTopologyTester : public edm::EDAnalyzer { +public: + explicit HcalTopologyTester(const edm::ParameterSet& ); + ~HcalTopologyTester(); + + + virtual void analyze(const edm::Event&, const edm::EventSetup& ); + void doTest(const HcalTopology& topology); + +private: + // ----------member data --------------------------- +}; + +HcalTopologyTester::HcalTopologyTester(const edm::ParameterSet& ) {} -int main(int /*argc*/, char** /*argv*/) { - // FIXME: for SLHC - HcalTopologyMode::Mode mode = HcalTopologyMode::LHC; - int maxDepthHB = 2; - int maxDepthHE = 3; +HcalTopologyTester::~HcalTopologyTester() {} + +void HcalTopologyTester::analyze(const edm::Event& , + const edm::EventSetup& iSetup ) { + + + edm::ESTransientHandle pDD; + iSetup.get().get( pDD ); + std::cout << "Gets Compact View\n"; + edm::ESHandle pHSNDC; + iSetup.get().get( pHSNDC ); + std::cout << "Gets RecNumbering Record\n"; + edm::ESHandle topo; + iSetup.get().get(topo); + if (topo.isValid()) doTest(*topo); + else std::cout << "Cannot get a valid HcalTopology Object\n"; +} + +void HcalTopologyTester::doTest(const HcalTopology& topology) { - HcalTopology topology(mode, maxDepthHB, maxDepthHE); for (int idet=0; idet<4; idet++) { HcalSubdetector subdet = HcalBarrel; if (idet == 1) subdet = HcalOuter; @@ -55,5 +98,8 @@ int main(int /*argc*/, char** /*argv*/) { } } } - return 0; + } + +//define this as a plug-in +DEFINE_FWK_MODULE(HcalTopologyTester); diff --git a/Geometry/CaloTopology/test/python/testHcalTopology_cfg.py b/Geometry/CaloTopology/test/python/testHcalTopology_cfg.py new file mode 100644 index 0000000000000..388b248e2b779 --- /dev/null +++ b/Geometry/CaloTopology/test/python/testHcalTopology_cfg.py @@ -0,0 +1,52 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") +process.load("SimGeneral.HepPDTESSource.pdt_cfi") + +process.load("Geometry.HcalCommonData.testHcalOnlyGeometryXML_cfi") +process.load("Geometry.HcalCommonData.hcalSimNumberingInitialization_cfi") +process.load("Geometry.HcalCommonData.hcalRecNumberingInitialization_cfi") +process.load("Geometry.HcalEventSetup.hcalTopologyIdeal_cfi") + +process.MessageLogger = cms.Service("MessageLogger", + destinations = cms.untracked.vstring('cout'), + categories = cms.untracked.vstring('HCalGeom'), + debugModules = cms.untracked.vstring('*'), + cout = cms.untracked.PSet( + threshold = cms.untracked.string('DEBUG'), + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + HCalGeom = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ) + ), +) + +process.load("IOMC.RandomEngine.IOMC_cff") +process.RandomNumberGeneratorService.generator.initialSeed = 456789 + +process.source = cms.Source("EmptySource") + +process.generator = cms.EDProducer("FlatRandomEGunProducer", + PGunParameters = cms.PSet( + PartID = cms.vint32(14), + MinEta = cms.double(-3.5), + MaxEta = cms.double(3.5), + MinPhi = cms.double(-3.14159265359), + MaxPhi = cms.double(3.14159265359), + MinE = cms.double(9.99), + MaxE = cms.double(10.01) + ), + AddAntiParticle = cms.bool(False), + Verbosity = cms.untracked.int32(0), + firstRun = cms.untracked.uint32(1) +) + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(1) +) + +process.prod = cms.EDAnalyzer("HcalTopologyTester") + +process.p1 = cms.Path(process.generator*process.prod) diff --git a/Geometry/CaloTopology/test/python/testHcalTopology_cfg_dump.py b/Geometry/CaloTopology/test/python/testHcalTopology_cfg_dump.py new file mode 100644 index 0000000000000..deb93b004e0ae --- /dev/null +++ b/Geometry/CaloTopology/test/python/testHcalTopology_cfg_dump.py @@ -0,0 +1,228 @@ +import FWCore.ParameterSet.Config as cms + +process = cms.Process("PROD") + +process.source = cms.Source("EmptySource") +process.generator = cms.EDProducer("FlatRandomEGunProducer", + PGunParameters = cms.PSet( + PartID = cms.vint32(14), + MaxEta = cms.double(3.5), + MaxPhi = cms.double(3.14159265359), + MinEta = cms.double(-3.5), + MinE = cms.double(9.99), + MinPhi = cms.double(-3.14159265359), + MaxE = cms.double(10.01) + ), + Verbosity = cms.untracked.int32(0), + AddAntiParticle = cms.bool(False), + firstRun = cms.untracked.uint32(1) +) + + +process.randomEngineStateProducer = cms.EDProducer("RandomEngineStateProducer") + + +process.prod = cms.EDAnalyzer("HcalTopologyTester") + + +process.p1 = cms.Path(process.generator+process.prod) + + +process.MessageLogger = cms.Service("MessageLogger", + debugModules = cms.untracked.vstring('*'), + cout = cms.untracked.PSet( + default = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ), + threshold = cms.untracked.string('DEBUG'), + HCalGeom = cms.untracked.PSet( + limit = cms.untracked.int32(0) + ) + ), + categories = cms.untracked.vstring('HCalGeom'), + destinations = cms.untracked.vstring('cout') +) + + +process.RandomNumberGeneratorService = cms.Service("RandomNumberGeneratorService", + horeco = cms.PSet( + initialSeed = cms.untracked.uint32(541321), + engineName = cms.untracked.string('TRandom3') + ), + externalLHEProducer = cms.PSet( + initialSeed = cms.untracked.uint32(234567), + engineName = cms.untracked.string('HepJamesRandom') + ), + saveFileName = cms.untracked.string(''), + hbhereco = cms.PSet( + initialSeed = cms.untracked.uint32(541321), + engineName = cms.untracked.string('TRandom3') + ), + simSiStripDigiSimLink = cms.PSet( + initialSeed = cms.untracked.uint32(1234567), + engineName = cms.untracked.string('HepJamesRandom') + ), + paramMuons = cms.PSet( + initialSeed = cms.untracked.uint32(54525), + engineName = cms.untracked.string('TRandom3') + ), + famosPileUp = cms.PSet( + initialSeed = cms.untracked.uint32(918273), + engineName = cms.untracked.string('TRandom3') + ), + simMuonDTDigis = cms.PSet( + initialSeed = cms.untracked.uint32(1234567), + engineName = cms.untracked.string('HepJamesRandom') + ), + siTrackerGaussianSmearingRecHits = cms.PSet( + initialSeed = cms.untracked.uint32(24680), + engineName = cms.untracked.string('TRandom3') + ), + ecalPreshowerRecHit = cms.PSet( + initialSeed = cms.untracked.uint32(6541321), + engineName = cms.untracked.string('TRandom3') + ), + generator = cms.PSet( + initialSeed = cms.untracked.uint32(456789), + engineName = cms.untracked.string('HepJamesRandom') + ), + simMuonRPCDigis = cms.PSet( + initialSeed = cms.untracked.uint32(1234567), + engineName = cms.untracked.string('HepJamesRandom') + ), + hiSignal = cms.PSet( + initialSeed = cms.untracked.uint32(123456789), + engineName = cms.untracked.string('HepJamesRandom') + ), + mixSimCaloHits = cms.PSet( + initialSeed = cms.untracked.uint32(918273), + engineName = cms.untracked.string('TRandom3') + ), + mix = cms.PSet( + initialSeed = cms.untracked.uint32(12345), + engineName = cms.untracked.string('HepJamesRandom') + ), + VtxSmeared = cms.PSet( + initialSeed = cms.untracked.uint32(98765432), + engineName = cms.untracked.string('HepJamesRandom') + ), + LHCTransport = cms.PSet( + initialSeed = cms.untracked.uint32(87654321), + engineName = cms.untracked.string('TRandom3') + ), + ecalRecHit = cms.PSet( + initialSeed = cms.untracked.uint32(654321), + engineName = cms.untracked.string('TRandom3') + ), + mixData = cms.PSet( + initialSeed = cms.untracked.uint32(12345), + engineName = cms.untracked.string('HepJamesRandom') + ), + mixRecoTracks = cms.PSet( + initialSeed = cms.untracked.uint32(918273), + engineName = cms.untracked.string('TRandom3') + ), + hiSignalG4SimHits = cms.PSet( + initialSeed = cms.untracked.uint32(11), + engineName = cms.untracked.string('HepJamesRandom') + ), + famosSimHits = cms.PSet( + initialSeed = cms.untracked.uint32(13579), + engineName = cms.untracked.string('TRandom3') + ), + MuonSimHits = cms.PSet( + initialSeed = cms.untracked.uint32(987346), + engineName = cms.untracked.string('TRandom3') + ), + g4SimHits = cms.PSet( + initialSeed = cms.untracked.uint32(11), + engineName = cms.untracked.string('HepJamesRandom') + ), + hiSignalLHCTransport = cms.PSet( + initialSeed = cms.untracked.uint32(88776655), + engineName = cms.untracked.string('TRandom3') + ), + mixGenPU = cms.PSet( + initialSeed = cms.untracked.uint32(918273), + engineName = cms.untracked.string('TRandom3') + ), + l1ParamMuons = cms.PSet( + initialSeed = cms.untracked.uint32(6453209), + engineName = cms.untracked.string('TRandom3') + ), + simBeamSpotFilter = cms.PSet( + initialSeed = cms.untracked.uint32(87654321), + engineName = cms.untracked.string('HepJamesRandom') + ), + simMuonCSCDigis = cms.PSet( + initialSeed = cms.untracked.uint32(11223344), + engineName = cms.untracked.string('HepJamesRandom') + ), + hfreco = cms.PSet( + initialSeed = cms.untracked.uint32(541321), + engineName = cms.untracked.string('TRandom3') + ) +) + + +process.HcalRecNumberingInitialization = cms.ESProducer("HcalRecNumberingInitialization") + + +process.HcalSimNumberingInitialization = cms.ESProducer("HcalSimNumberingInitialization") + + +process.hcalTopologyIdeal = cms.ESProducer("HcalTopologyIdealEP", + Exclude = cms.untracked.string(''), + appendToDataLabel = cms.string(''), + hcalTopologyConstants = cms.PSet( + + ) +) + + +process.HepPDTESSource = cms.ESSource("HepPDTESSource", + pdtFileName = cms.FileInPath('SimGeneral/HepPDTESSource/data/particle.tbl') +) + + +process.XMLIdealGeometryESSource = cms.ESSource("XMLIdealGeometryESSource", + geomXMLFiles = cms.vstring('Geometry/CMSCommonData/data/materials.xml', + 'Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml', + 'Geometry/CMSCommonData/data/rotations.xml', + 'Geometry/HcalCommonData/data/hcalrotations.xml', + 'Geometry/CMSCommonData/data/normal/cmsextent.xml', + 'Geometry/CMSCommonData/data/cms.xml', + 'Geometry/CMSCommonData/data/cmsMother.xml', + 'Geometry/CMSCommonData/data/caloBase.xml', + 'Geometry/CMSCommonData/data/cmsCalo.xml', + 'Geometry/CMSCommonData/data/muonBase.xml', + 'Geometry/CMSCommonData/data/cmsMuon.xml', + 'Geometry/CMSCommonData/data/mgnt.xml', + 'Geometry/CMSCommonData/data/muonMB.xml', + 'Geometry/CMSCommonData/data/muonMagnet.xml', + 'Geometry/CMSCommonData/data/eta4/etaMax.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalalgo.xml', + 'Geometry/HcalCommonData/data/hcalcablealgo.xml', + 'Geometry/HcalCommonData/data/hcalbarrelalgo.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalendcapalgo.xml', + 'Geometry/HcalCommonData/data/hcalouteralgo.xml', + 'Geometry/HcalCommonData/data/hcalforwardalgo.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalSimNumbering.xml', + 'Geometry/HcalCommonData/data/Phase0/hcalRecNumbering.xml', + 'Geometry/ForwardCommonData/data/bundle/forwardshield.xml', + 'Geometry/ForwardCommonData/data/forward.xml', + 'Geometry/HcalSimData/data/CaloUtil.xml', + 'Geometry/HcalCommonData/data/hcalsens.xml', + 'Geometry/HcalSimData/data/hf.xml', + 'Geometry/HcalSimData/data/hfpmt.xml', + 'Geometry/HcalSimData/data/hffibrebundle.xml', + 'Geometry/HcalSimData/data/HcalProdCuts.xml', + 'Geometry/CMSCommonData/data/FieldParameters.xml'), + rootNodeName = cms.string('cms:OCMS') +) + + +process.maxEvents = cms.untracked.PSet( + input = cms.untracked.int32(1) +) + diff --git a/Geometry/HcalCommonData/interface/HcalDDDRecConstants.h b/Geometry/HcalCommonData/interface/HcalDDDRecConstants.h index aa94f39b046d3..65ea31a12638e 100644 --- a/Geometry/HcalCommonData/interface/HcalDDDRecConstants.h +++ b/Geometry/HcalCommonData/interface/HcalDDDRecConstants.h @@ -81,6 +81,7 @@ class HcalDDDRecConstants { int nEta; // Number of bins in eta for HB and HE std::vector phiGroup; // Eta Grouping std::vector phibin; // Phi step for all eta bins + std::vector phiUnitS; // Phi unit at SIM stage std::vector layerGroup[nEtaMax]; std::vector nOff; // Speical eta bin #'s in barrel and endcap std::vector > gconsHB; // Geometry constatnts HB diff --git a/Geometry/HcalCommonData/plugins/HcalRecNumberingInitialization.cc b/Geometry/HcalCommonData/plugins/HcalRecNumberingInitialization.cc index ea63acb3dcd80..753817c391e92 100644 --- a/Geometry/HcalCommonData/plugins/HcalRecNumberingInitialization.cc +++ b/Geometry/HcalCommonData/plugins/HcalRecNumberingInitialization.cc @@ -34,7 +34,7 @@ #include #include -#define DebugLog +//#define DebugLog class HcalRecNumberingInitialization : public edm::ESProducer { diff --git a/Geometry/HcalCommonData/plugins/HcalSimNumberingInitialization.cc b/Geometry/HcalCommonData/plugins/HcalSimNumberingInitialization.cc index 7d2d43187de34..b1bb18dcaaeb6 100644 --- a/Geometry/HcalCommonData/plugins/HcalSimNumberingInitialization.cc +++ b/Geometry/HcalCommonData/plugins/HcalSimNumberingInitialization.cc @@ -33,7 +33,7 @@ #include #include -#define DebugLog +//#define DebugLog class HcalSimNumberingInitialization : public edm::ESProducer { diff --git a/Geometry/HcalCommonData/src/HcalDDDRecConstants.cc b/Geometry/HcalCommonData/src/HcalDDDRecConstants.cc index 4521672189901..359d62173b204 100644 --- a/Geometry/HcalCommonData/src/HcalDDDRecConstants.cc +++ b/Geometry/HcalCommonData/src/HcalDDDRecConstants.cc @@ -124,8 +124,17 @@ HcalDDDRecConstants::HcalID HcalDDDRecConstants::getHCID(int subdet,int ieta, if (subdet == static_cast(HcalBarrel) || subdet == static_cast(HcalEndcap)) { eta = ietaMap[ieta-1]; - int phi0 = (iphi-1)/phiGroup[eta-1]; ++phi0; - int unit = hcons->unitPhi(phibin[eta-1]); + int unit = phiUnitS[ieta-1]; + int phi0 = (iphi-1)/phiGroup[eta-1]; + if (unit == 2) { + phi0 = (iphi+1)/2; + phi0 = (phi0-1)/phiGroup[eta-1]; + } else if (unit == 4) { + phi0 = (iphi+5)/4; + phi0 = (phi0-1)/phiGroup[eta-1]; + } + ++phi0; + unit = hcons->unitPhi(phibin[eta-1]); phi = hcons->phiNumber(phi0,unit); depth = layerGroup[eta-1][lay-1]; if (eta == iEtaMin[1]) { @@ -144,6 +153,11 @@ HcalDDDRecConstants::HcalID HcalDDDRecConstants::getHCID(int subdet,int ieta, } else if (subdet == static_cast(HcalOuter)) { depth = 4; } +#ifdef DebugLog + std::cout << "getHCID: input " << subdet << ":" << ieta << ":" << iphi + << ":" << idepth << ":" << lay << " output " << eta << ":" << phi + << ":" << depth << std::endl; +#endif return HcalDDDRecConstants::HcalID(eta,phi,depth); } @@ -341,18 +355,26 @@ void HcalDDDRecConstants::loadSimConst() { // Then Phi bins ieta = 0; - phibin.clear(); + phibin.clear(); phiUnitS.clear(); for (int i=0; igetPhiBin(ieta); phibin.push_back(dphi); ieta += etaGroup[i]; } + for (unsigned int i=1; iunitPhi(hcons->getPhiBin(i-1)); + phiUnitS.push_back(unit); + } #ifdef DebugLog std::cout << "Modified eta/deltaphi table for " << nEta << " bins" << std::endl; for (int i=0; i= iEtaMin[1]-1 && i < iEtaMax[1]) { +#ifdef DebugLog std::cout << "HE " << i << " " << imx << " " << laymax << std::endl; +#endif if (maxDepth[1] < laymax) maxDepth[1] = laymax; } } diff --git a/Geometry/HcalEventSetup/interface/HcalHardcodeGeometryEP.h b/Geometry/HcalEventSetup/interface/HcalHardcodeGeometryEP.h index 93f0e24b508f3..4bc46d2a7bb77 100644 --- a/Geometry/HcalEventSetup/interface/HcalHardcodeGeometryEP.h +++ b/Geometry/HcalEventSetup/interface/HcalHardcodeGeometryEP.h @@ -12,6 +12,7 @@ // class declarations class CaloSubdetectorGeometry; +class HcalRecNumberingRecord; class IdealGeometryRecord; class HcalGeometryRecord; @@ -24,10 +25,10 @@ class HcalHardcodeGeometryEP : public edm::ESProducer { typedef boost::shared_ptr ReturnType; - ReturnType produceIdeal( const IdealGeometryRecord&); + ReturnType produceIdeal( const HcalRecNumberingRecord&); ReturnType produceAligned( const HcalGeometryRecord& ); - void idealRecordCallBack( const IdealGeometryRecord& ); + void idealRecordCallBack( const HcalRecNumberingRecord& ) {} private: edm::ParameterSet ps0; diff --git a/Geometry/HcalEventSetup/interface/HcalTopologyIdealEP.h b/Geometry/HcalEventSetup/interface/HcalTopologyIdealEP.h index c86307e6a64ec..4e7f216838428 100644 --- a/Geometry/HcalEventSetup/interface/HcalTopologyIdealEP.h +++ b/Geometry/HcalEventSetup/interface/HcalTopologyIdealEP.h @@ -12,6 +12,7 @@ #include "FWCore/Framework/interface/ESHandle.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "Geometry/Records/interface/IdealGeometryRecord.h" namespace edm { @@ -32,7 +33,9 @@ class HcalTopologyIdealEP : public edm::ESProducer { static void fillDescriptions( edm::ConfigurationDescriptions & descriptions ); - ReturnType produce(const IdealGeometryRecord&); + ReturnType produce(const HcalRecNumberingRecord&); + + void hcalRecordCallBack( const IdealGeometryRecord& ) {} private: // ----------member data --------------------------- diff --git a/Geometry/HcalEventSetup/python/CaloTowerGeometryDBReader_cfi.py b/Geometry/HcalEventSetup/python/CaloTowerGeometryDBReader_cfi.py index b3ec609dc4a36..f665caa4daaf5 100644 --- a/Geometry/HcalEventSetup/python/CaloTowerGeometryDBReader_cfi.py +++ b/Geometry/HcalEventSetup/python/CaloTowerGeometryDBReader_cfi.py @@ -3,6 +3,3 @@ CaloTowerGeometryFromDBEP = cms.ESProducer( "CaloTowerGeometryFromDBEP", applyAlignment = cms.bool(False) ) - -import Geometry.HcalEventSetup.hcalTopologyConstants_cfi as hcalTopologyConstants_cfi -CaloTowerGeometryFromDBEP.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) diff --git a/Geometry/HcalEventSetup/python/HcalGeometryDBReader_cfi.py b/Geometry/HcalEventSetup/python/HcalGeometryDBReader_cfi.py index 4ce13bc2f3cb4..f65ffed260533 100644 --- a/Geometry/HcalEventSetup/python/HcalGeometryDBReader_cfi.py +++ b/Geometry/HcalEventSetup/python/HcalGeometryDBReader_cfi.py @@ -3,8 +3,6 @@ HcalGeometryFromDBEP = cms.ESProducer("HcalGeometryFromDBEP", applyAlignment = cms.bool(False) ) -import Geometry.HcalEventSetup.hcalTopologyConstants_cfi as hcalTopologyConstants_cfi -HcalGeometryFromDBEP.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) HcalAlignmentEP = cms.ESProducer("HcalAlignmentEP") diff --git a/Geometry/HcalEventSetup/python/HcalTopology_cfi.py b/Geometry/HcalEventSetup/python/HcalTopology_cfi.py index 56054509b5c1b..553ba2173e307 100644 --- a/Geometry/HcalEventSetup/python/HcalTopology_cfi.py +++ b/Geometry/HcalEventSetup/python/HcalTopology_cfi.py @@ -1,8 +1,7 @@ import FWCore.ParameterSet.Config as cms +from Geometry.HcalCommonData.hcalRecNumberingInitialization_cfi import * + import Geometry.HcalEventSetup.hcalTopologyIdeal_cfi hcalTopologyIdeal = Geometry.HcalEventSetup.hcalTopologyIdeal_cfi.hcalTopologyIdeal.clone() - -import Geometry.HcalEventSetup.hcalTopologyConstants_cfi as hcalTopologyConstants_cfi -hcalTopologyIdeal.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) diff --git a/Geometry/HcalEventSetup/python/HcalTrigTowerGeometry_cfi.py b/Geometry/HcalEventSetup/python/HcalTrigTowerGeometry_cfi.py index b99d1921bfdb2..e8531bdd0a83c 100644 --- a/Geometry/HcalEventSetup/python/HcalTrigTowerGeometry_cfi.py +++ b/Geometry/HcalEventSetup/python/HcalTrigTowerGeometry_cfi.py @@ -3,6 +3,3 @@ import Geometry.HcalEventSetup.hcalTrigTowerGeometry_cfi hcalTrigTowerGeometry = Geometry.HcalEventSetup.hcalTrigTowerGeometry_cfi.hcalTrigTowerGeometry.clone() - -import Geometry.HcalEventSetup.hcalTopologyConstants_cfi as hcalTopologyConstants_cfi -hcalTrigTowerGeometry.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) diff --git a/Geometry/HcalEventSetup/python/hcalSLHCTopologyConstants_cfi.py b/Geometry/HcalEventSetup/python/hcalSLHCTopologyConstants_cfi.py index 66dc289e94d74..f812a41fbcecc 100644 --- a/Geometry/HcalEventSetup/python/hcalSLHCTopologyConstants_cfi.py +++ b/Geometry/HcalEventSetup/python/hcalSLHCTopologyConstants_cfi.py @@ -1,7 +1,7 @@ import FWCore.ParameterSet.Config as cms -hcalTopologyConstants = cms.PSet( - mode = cms.string('HcalTopologyMode::SLHC'), - maxDepthHB = cms.int32(4), - maxDepthHE = cms.int32(5) -) +## hcalTopologyConstants = cms.PSet( +## mode = cms.string('HcalTopologyMode::SLHC'), +## maxDepthHB = cms.int32(4), +## maxDepthHE = cms.int32(5) +## ) diff --git a/Geometry/HcalEventSetup/python/hcalTopologyConstants_cfi.py b/Geometry/HcalEventSetup/python/hcalTopologyConstants_cfi.py index 89ee137740f52..790ad85cc9849 100644 --- a/Geometry/HcalEventSetup/python/hcalTopologyConstants_cfi.py +++ b/Geometry/HcalEventSetup/python/hcalTopologyConstants_cfi.py @@ -1,7 +1,7 @@ import FWCore.ParameterSet.Config as cms -hcalTopologyConstants = cms.PSet( - mode = cms.string('HcalTopologyMode::LHC'), - maxDepthHB = cms.int32(2), - maxDepthHE = cms.int32(3) -) +## hcalTopologyConstants = cms.PSet( +## mode = cms.string('HcalTopologyMode::LHC'), +## maxDepthHB = cms.int32(2), +## maxDepthHE = cms.int32(3) +## ) diff --git a/Geometry/HcalEventSetup/python/hcalTopologyIdeal_cfi.py b/Geometry/HcalEventSetup/python/hcalTopologyIdeal_cfi.py new file mode 100644 index 0000000000000..ace69f45b3ec0 --- /dev/null +++ b/Geometry/HcalEventSetup/python/hcalTopologyIdeal_cfi.py @@ -0,0 +1,7 @@ +import FWCore.ParameterSet.Config as cms + +hcalTopologyIdeal = cms.ESProducer('HcalTopologyIdealEP', + Exclude = cms.untracked.string(''), +## hcalTopologyConstants = cms.PSet(), + appendToDataLabel = cms.string('') +) diff --git a/Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.cc b/Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.cc index 823e827ac3990..9f5cf784bdac1 100644 --- a/Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.cc +++ b/Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.cc @@ -18,6 +18,7 @@ // #include "Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" // // constants, enums and typedefs @@ -34,15 +35,17 @@ CaloTowerHardcodeGeometryEP::CaloTowerHardcodeGeometryEP(const edm::ParameterSet { //the following line is needed to tell the framework what // data is being produced - setWhatProduced(this,"TOWER"); + setWhatProduced(this, + &CaloTowerHardcodeGeometryEP::produce, + dependsOn( &CaloTowerHardcodeGeometryEP::idealRecordCallBack ), + "TOWER"); //now do what ever other initialization is needed loader_=new CaloTowerHardcodeGeometryLoader(); /// TODO : allow override of Topology. } -CaloTowerHardcodeGeometryEP::~CaloTowerHardcodeGeometryEP() -{ +CaloTowerHardcodeGeometryEP::~CaloTowerHardcodeGeometryEP() { delete loader_; } @@ -53,10 +56,9 @@ CaloTowerHardcodeGeometryEP::~CaloTowerHardcodeGeometryEP() // ------------ method called to produce the data ------------ CaloTowerHardcodeGeometryEP::ReturnType -CaloTowerHardcodeGeometryEP::produce(const CaloTowerGeometryRecord& iRecord) -{ +CaloTowerHardcodeGeometryEP::produce(const CaloTowerGeometryRecord& iRecord) { edm::ESHandle hcalTopology; - iRecord.getRecord().get( hcalTopology ); + iRecord.getRecord().get( hcalTopology ); std::auto_ptr pCaloSubdetectorGeometry( loader_->load( &*hcalTopology )); diff --git a/Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.h b/Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.h index f2cafe7a1dc86..d7dc706b2966f 100644 --- a/Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.h +++ b/Geometry/HcalEventSetup/src/CaloTowerHardcodeGeometryEP.h @@ -17,15 +17,21 @@ // // class decleration // +class HcalRecNumberingRecord; +class IdealGeometryRecord; + class CaloTowerHardcodeGeometryEP : public edm::ESProducer { - public: - CaloTowerHardcodeGeometryEP(const edm::ParameterSet&); - ~CaloTowerHardcodeGeometryEP(); +public: + CaloTowerHardcodeGeometryEP(const edm::ParameterSet&); + ~CaloTowerHardcodeGeometryEP(); + + typedef std::auto_ptr ReturnType; + + ReturnType produce(const CaloTowerGeometryRecord&); - typedef std::auto_ptr ReturnType; + void idealRecordCallBack( const HcalRecNumberingRecord& ) {} - ReturnType produce(const CaloTowerGeometryRecord&); private: // ----------member data --------------------------- CaloTowerHardcodeGeometryLoader* loader_; diff --git a/Geometry/HcalEventSetup/src/HcalHardcodeGeometryEP.cc b/Geometry/HcalEventSetup/src/HcalHardcodeGeometryEP.cc index 7e9a8ae7fca8c..8bfec22e5834a 100644 --- a/Geometry/HcalEventSetup/src/HcalHardcodeGeometryEP.cc +++ b/Geometry/HcalEventSetup/src/HcalHardcodeGeometryEP.cc @@ -20,7 +20,7 @@ #include "Geometry/HcalEventSetup/interface/HcalHardcodeGeometryEP.h" #include "FWCore/Framework/interface/ESHandle.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "Geometry/Records/interface/HcalGeometryRecord.h" #include "Geometry/CaloGeometry/interface/CaloSubdetectorGeometry.h" #include "Geometry/HcalTowerAlgo/interface/HcalFlexiHardcodeGeometryLoader.h" @@ -49,11 +49,6 @@ HcalHardcodeGeometryEP::HcalHardcodeGeometryEP( const edm::ParameterSet& ps ) : &HcalHardcodeGeometryEP::produceAligned, dependsOn( &HcalHardcodeGeometryEP::idealRecordCallBack ), HcalGeometry::producerTag() ); - -// disable -// setWhatProduced( this, -// &HcalHardcodeGeometryEP::produceIdeal, -// edm::es::Label( "HCAL" ) ); } @@ -68,13 +63,8 @@ HcalHardcodeGeometryEP::~HcalHardcodeGeometryEP() // ------------ method called to produce the data ------------ -void -HcalHardcodeGeometryEP::idealRecordCallBack( const IdealGeometryRecord& iRecord ) -{ -} - HcalHardcodeGeometryEP::ReturnType -HcalHardcodeGeometryEP::produceIdeal( const IdealGeometryRecord& iRecord ) +HcalHardcodeGeometryEP::produceIdeal( const HcalRecNumberingRecord& iRecord ) { edm::LogInfo("HCAL") << "Using default HCAL topology" ; @@ -87,7 +77,7 @@ HcalHardcodeGeometryEP::produceIdeal( const IdealGeometryRecord& iRecord ) HcalHardcodeGeometryEP::ReturnType HcalHardcodeGeometryEP::produceAligned( const HcalGeometryRecord& iRecord ) { - const IdealGeometryRecord& idealRecord = iRecord.getRecord(); + const HcalRecNumberingRecord& idealRecord = iRecord.getRecord(); return produceIdeal (idealRecord); } diff --git a/Geometry/HcalEventSetup/src/HcalTopologyIdealEP.cc b/Geometry/HcalEventSetup/src/HcalTopologyIdealEP.cc index eb5ccfa67145c..f4f3f4f87996d 100644 --- a/Geometry/HcalEventSetup/src/HcalTopologyIdealEP.cc +++ b/Geometry/HcalEventSetup/src/HcalTopologyIdealEP.cc @@ -18,6 +18,7 @@ #include "Geometry/HcalEventSetup/interface/HcalTopologyIdealEP.h" #include "Geometry/CaloTopology/interface/HcalTopologyRestrictionParser.h" +#include "Geometry/HcalCommonData/interface/HcalDDDRecConstants.h" #include "FWCore/Utilities/interface/Exception.h" #include "FWCore/MessageLogger/interface/MessageLogger.h" #include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h" @@ -38,23 +39,11 @@ HcalTopologyIdealEP::HcalTopologyIdealEP(const edm::ParameterSet& conf) : m_restrictions(conf.getUntrackedParameter("Exclude")), m_pSet( conf ) { - //std::cout << "HcalTopologyIdealEP::HcalTopologyIdealEP" << std::endl; + std::cout << "HcalTopologyIdealEP::HcalTopologyIdealEP" << std::endl; edm::LogInfo("HCAL") << "HcalTopologyIdealEP::HcalTopologyIdealEP"; - - // copied from HcalHitRelabeller, input like {1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,4} - m_segmentation.resize(29); - std::vector segmentation; - for (int iring=1; iring<=29; ++iring) { - char name[10]; - snprintf(name,10,"Eta%d",iring); - if(conf.existsAs >(name, false)) { - RingSegmentation entry; - entry.ring = iring; - entry.segmentation = conf.getUntrackedParameter >(name); - m_segmentation.push_back(entry); - } - } - setWhatProduced(this); + setWhatProduced(this, + &HcalTopologyIdealEP::produce, + dependsOn( &HcalTopologyIdealEP::hcalRecordCallBack )); } @@ -65,25 +54,12 @@ HcalTopologyIdealEP::~HcalTopologyIdealEP() void HcalTopologyIdealEP::fillDescriptions( edm::ConfigurationDescriptions & descriptions ) { - edm::ParameterSetDescription hcalTopologyConstants; - hcalTopologyConstants.add( "mode", "HcalTopologyMode::LHC" ); - hcalTopologyConstants.add( "maxDepthHB", 2 ); - hcalTopologyConstants.add( "maxDepthHE", 3 ); - - edm::ParameterSetDescription hcalSLHCTopologyConstants; - hcalSLHCTopologyConstants.add( "mode", "HcalTopologyMode::SLHC" ); - hcalSLHCTopologyConstants.add( "maxDepthHB", 7 ); - hcalSLHCTopologyConstants.add( "maxDepthHE", 7 ); + // edm::ParameterSetDescription hcalTopologyConstants; edm::ParameterSetDescription desc; desc.addUntracked( "Exclude", "" ); - desc.addOptional( "hcalTopologyConstants", hcalTopologyConstants ); + // desc.addOptional( "hcalTopologyConstants", hcalTopologyConstants ); descriptions.add( "hcalTopologyIdeal", desc ); - - edm::ParameterSetDescription descSLHC; - descSLHC.addUntracked( "Exclude", "" ); - descSLHC.addOptional( "hcalTopologyConstants", hcalSLHCTopologyConstants ); - descriptions.add( "hcalTopologyIdealSLHC", descSLHC ); } // @@ -92,25 +68,20 @@ HcalTopologyIdealEP::fillDescriptions( edm::ConfigurationDescriptions & descript // ------------ method called to produce the data ------------ HcalTopologyIdealEP::ReturnType -HcalTopologyIdealEP::produce(const IdealGeometryRecord& iRecord) +HcalTopologyIdealEP::produce(const HcalRecNumberingRecord& iRecord) { - // std::cout << "HcalTopologyIdealEP::produce(const IdealGeometryRecord& iRecord)" << std::endl; - edm::LogInfo("HCAL") << "HcalTopologyIdealEP::produce(const IdealGeometryRecord& iRecord)"; - - using namespace edm::es; - - HcalTopologyMode::Mode mode = HcalTopologyMode::LHC; - int maxDepthHB = 2; - int maxDepthHE = 3; - if( m_pSet.exists( "hcalTopologyConstants" )) - { - const edm::ParameterSet hcalTopoConsts( m_pSet.getParameter( "hcalTopologyConstants" )); - StringToEnumParser eparser; - mode = (HcalTopologyMode::Mode) eparser.parseString(hcalTopoConsts.getParameter("mode")); - maxDepthHB = hcalTopoConsts.getParameter("maxDepthHB"); - maxDepthHE = hcalTopoConsts.getParameter("maxDepthHE"); - } - // std::cout << "mode = " << mode << ", maxDepthHB = " << maxDepthHB << ", maxDepthHE = " << maxDepthHE << std::endl; + std::cout << "HcalTopologyIdealEP::produce(const IdealGeometryRecord& iRecord)" << std::endl; + edm::LogInfo("HCAL") << "HcalTopologyIdealEP::produce(const HcalGeometryRecord& iRecord)"; + + edm::ESHandle pHRNDC; + iRecord.get( pHRNDC ); + const HcalDDDRecConstants hdc (*pHRNDC); + + StringToEnumParser eparser; + HcalTopologyMode::Mode mode = eparser.parseString(hdc.getTopoMode()); + int maxDepthHB = hdc.getMaxDepth(0); + int maxDepthHE = hdc.getMaxDepth(1); + std::cout << "mode = " << mode << ", maxDepthHB = " << maxDepthHB << ", maxDepthHE = " << maxDepthHE << std::endl; edm::LogInfo("HCAL") << "mode = " << mode << ", maxDepthHB = " << maxDepthHB << ", maxDepthHE = " << maxDepthHE; ReturnType myTopo(new HcalTopology( mode, maxDepthHB, maxDepthHE )); @@ -122,12 +93,6 @@ HcalTopologyIdealEP::produce(const IdealGeometryRecord& iRecord) throw cms::Exception("Parse Error","Parse error on Exclude "+error); } } - - // see if any depth segmentation needs to be added - for(std::vector::const_iterator ringSegItr = m_segmentation.begin(); - ringSegItr != m_segmentation.end(); ++ringSegItr) { - myTopo->setDepthSegmentation(ringSegItr->ring, ringSegItr->segmentation); - } return myTopo ; } diff --git a/Geometry/HcalEventSetup/test/runTestHcalDDDGeometry_cfg.py b/Geometry/HcalEventSetup/test/runTestHcalDDDGeometry_cfg.py index bdaf10831910a..f494af0dc5609 100644 --- a/Geometry/HcalEventSetup/test/runTestHcalDDDGeometry_cfg.py +++ b/Geometry/HcalEventSetup/test/runTestHcalDDDGeometry_cfg.py @@ -40,6 +40,7 @@ ) process.load("Geometry.HcalEventSetup.HcalDDDGeometry_cfi") +process.load("Geometry.HcalEventSetup.hcalTopologyIdeal_cfi") process.prod = cms.EDAnalyzer("HcalDDDGeometryAnalyzer") diff --git a/Geometry/HcalTowerAlgo/plugins/HcalTrigTowerGeometryESProducer.cc b/Geometry/HcalTowerAlgo/plugins/HcalTrigTowerGeometryESProducer.cc index 5b4f04c24fd28..fc692c4116dd1 100644 --- a/Geometry/HcalTowerAlgo/plugins/HcalTrigTowerGeometryESProducer.cc +++ b/Geometry/HcalTowerAlgo/plugins/HcalTrigTowerGeometryESProducer.cc @@ -1,7 +1,7 @@ #include "HcalTrigTowerGeometryESProducer.h" #include "FWCore/Framework/interface/ModuleFactory.h" #include "FWCore/Framework/interface/ESHandle.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include HcalTrigTowerGeometryESProducer::HcalTrigTowerGeometryESProducer( const edm::ParameterSet & config ) @@ -18,7 +18,7 @@ boost::shared_ptr HcalTrigTowerGeometryESProducer::produce( const CaloGeometryRecord & iRecord ) { edm::ESHandle hcalTopology; - iRecord.getRecord().get( hcalTopology ); + iRecord.getRecord().get( hcalTopology ); m_hcalTrigTowerGeom = boost::shared_ptr( new HcalTrigTowerGeometry( &*hcalTopology)); diff --git a/Geometry/HcalTowerAlgo/test/HcalGeometryAnalyzer.cc b/Geometry/HcalTowerAlgo/test/HcalGeometryAnalyzer.cc index aa969dfea7d36..cbf5810478404 100644 --- a/Geometry/HcalTowerAlgo/test/HcalGeometryAnalyzer.cc +++ b/Geometry/HcalTowerAlgo/test/HcalGeometryAnalyzer.cc @@ -36,7 +36,7 @@ void HcalGeometryAnalyzer::analyze( const edm::Event& /*iEvent*/, const edm::EventSetup& iSetup ) { edm::ESHandle topologyHandle; - iSetup.get().get( topologyHandle ); + iSetup.get().get( topologyHandle ); const HcalTopology* topology ( topologyHandle.product() ) ; edm::ESHandle pG; diff --git a/Geometry/HcalTowerAlgo/test/HcalGeometryDetIdAnalyzer.cc b/Geometry/HcalTowerAlgo/test/HcalGeometryDetIdAnalyzer.cc index 52f316170401d..3b4e11e4362c8 100644 --- a/Geometry/HcalTowerAlgo/test/HcalGeometryDetIdAnalyzer.cc +++ b/Geometry/HcalTowerAlgo/test/HcalGeometryDetIdAnalyzer.cc @@ -36,7 +36,7 @@ void HcalGeometryDetIdAnalyzer::analyze( const edm::Event& /*iEvent*/, const edm::EventSetup& iSetup ) { edm::ESHandle topologyHandle; - iSetup.get().get( topologyHandle ); + iSetup.get().get( topologyHandle ); const HcalTopology* topology ( topologyHandle.product() ) ; edm::ESHandle pG; diff --git a/Geometry/HcalTowerAlgo/test/runHcalGeometryAnalyzer_cfg.py b/Geometry/HcalTowerAlgo/test/runHcalGeometryAnalyzer_cfg.py index c010725c45709..d45dad4936f18 100644 --- a/Geometry/HcalTowerAlgo/test/runHcalGeometryAnalyzer_cfg.py +++ b/Geometry/HcalTowerAlgo/test/runHcalGeometryAnalyzer_cfg.py @@ -10,12 +10,6 @@ appendToDataLabel = cms.string("_master"), HcalReLabel = HcalReLabel ) -## Comment it out to test std Hcal geometry -## -import Geometry.HcalEventSetup.hcalSLHCTopologyConstants_cfi as hcalTopologyConstants_cfi -process.hcalTopologyIdeal.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) -## - process.source = cms.Source("EmptySource") process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(1) diff --git a/Geometry/HcalTowerAlgo/test/runHcalGeometryDBAnalyzer_cfg.py b/Geometry/HcalTowerAlgo/test/runHcalGeometryDBAnalyzer_cfg.py index b240c989fe62a..bb5524e6fc5da 100644 --- a/Geometry/HcalTowerAlgo/test/runHcalGeometryDBAnalyzer_cfg.py +++ b/Geometry/HcalTowerAlgo/test/runHcalGeometryDBAnalyzer_cfg.py @@ -26,11 +26,6 @@ ## appendToDataLabel = cms.string("_master"), ## HcalReLabel = HcalReLabel ## ) -## Comment it out to test std Hcal geometry -## -import Geometry.HcalEventSetup.hcalSLHCTopologyConstants_cfi as hcalTopologyConstants_cfi -process.hcalTopologyIdeal.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) -## process.source = cms.Source("EmptySource") process.maxEvents = cms.untracked.PSet( diff --git a/Geometry/HcalTowerAlgo/test/runHcalGeometryDetIdAnalyzer_cfg.py b/Geometry/HcalTowerAlgo/test/runHcalGeometryDetIdAnalyzer_cfg.py index 5b437f6a79a0b..a4ee02e6f683d 100644 --- a/Geometry/HcalTowerAlgo/test/runHcalGeometryDetIdAnalyzer_cfg.py +++ b/Geometry/HcalTowerAlgo/test/runHcalGeometryDetIdAnalyzer_cfg.py @@ -10,12 +10,6 @@ appendToDataLabel = cms.string("_master"), HcalReLabel = HcalReLabel ) -## Comment it out to test std Hcal geometry -## -import Geometry.HcalEventSetup.hcalSLHCTopologyConstants_cfi as hcalTopologyConstants_cfi -process.hcalTopologyIdeal.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) -## - process.source = cms.Source("EmptySource") process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(1) diff --git a/Geometry/HcalTowerAlgo/test/runHcalTransGeometryAnalyzer_cfg.py b/Geometry/HcalTowerAlgo/test/runHcalTransGeometryAnalyzer_cfg.py index 23223dd87f0f4..6d30f675644fb 100644 --- a/Geometry/HcalTowerAlgo/test/runHcalTransGeometryAnalyzer_cfg.py +++ b/Geometry/HcalTowerAlgo/test/runHcalTransGeometryAnalyzer_cfg.py @@ -10,12 +10,6 @@ appendToDataLabel = cms.string("_master"), HcalReLabel = HcalReLabel ) -## Comment it out to test std Hcal geometry -## -import Geometry.HcalEventSetup.hcalSLHCTopologyConstants_cfi as hcalTopologyConstants_cfi -process.hcalTopologyIdeal.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) -## - process.source = cms.Source("EmptySource") process.maxEvents = cms.untracked.PSet( input = cms.untracked.int32(1) diff --git a/Geometry/Records/interface/CaloGeometryRecord.h b/Geometry/Records/interface/CaloGeometryRecord.h index 8382e786aa188..3d2e3283c6540 100644 --- a/Geometry/Records/interface/CaloGeometryRecord.h +++ b/Geometry/Records/interface/CaloGeometryRecord.h @@ -17,6 +17,7 @@ #include "Geometry/Records/interface/EcalEndcapGeometryRecord.h" #include "Geometry/Records/interface/EcalPreshowerGeometryRecord.h" #include "Geometry/Records/interface/HcalGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "Geometry/Records/interface/CaloTowerGeometryRecord.h" #include "Geometry/Records/interface/ZDCGeometryRecord.h" #include "Geometry/Records/interface/CastorGeometryRecord.h" @@ -32,6 +33,7 @@ class CaloGeometryRecord : EcalEndcapGeometryRecord, EcalPreshowerGeometryRecord, HcalGeometryRecord, + HcalRecNumberingRecord, CaloTowerGeometryRecord, CastorGeometryRecord, ZDCGeometryRecord> > {}; diff --git a/Geometry/Records/interface/CaloTowerGeometryRecord.h b/Geometry/Records/interface/CaloTowerGeometryRecord.h index 6daf67f37c033..dfaceaab901f2 100644 --- a/Geometry/Records/interface/CaloTowerGeometryRecord.h +++ b/Geometry/Records/interface/CaloTowerGeometryRecord.h @@ -13,6 +13,7 @@ #include "FWCore/Framework/interface/EventSetupRecordImplementation.h" #include "FWCore/Framework/interface/DependentRecordImplementation.h" #include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "CondFormats/AlignmentRecord/interface/CaloTowerAlignmentRcd.h" #include "CondFormats/AlignmentRecord/interface/CaloTowerAlignmentErrorRcd.h" #include "Geometry/Records/interface/PCaloTowerRcd.h" @@ -25,6 +26,7 @@ class CaloTowerGeometryRecord : CaloTowerGeometryRecord, boost::mpl::vector< IdealGeometryRecord, + HcalRecNumberingRecord, CaloTowerAlignmentRcd, CaloTowerAlignmentErrorRcd, GlobalPositionRcd, diff --git a/Geometry/Records/interface/HcalGeometryRecord.h b/Geometry/Records/interface/HcalGeometryRecord.h index 0ec419d389544..ff50b916f1888 100644 --- a/Geometry/Records/interface/HcalGeometryRecord.h +++ b/Geometry/Records/interface/HcalGeometryRecord.h @@ -13,6 +13,7 @@ #include "FWCore/Framework/interface/EventSetupRecordImplementation.h" #include "FWCore/Framework/interface/DependentRecordImplementation.h" #include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "CondFormats/AlignmentRecord/interface/HcalAlignmentRcd.h" #include "CondFormats/AlignmentRecord/interface/HcalAlignmentErrorRcd.h" #include "Geometry/Records/interface/PHcalRcd.h" @@ -25,6 +26,7 @@ class HcalGeometryRecord : HcalGeometryRecord, boost::mpl::vector< IdealGeometryRecord, + HcalRecNumberingRecord, HcalAlignmentRcd, HcalAlignmentErrorRcd, GlobalPositionRcd, diff --git a/L1TriggerConfig/L1ScalesProducers/src/L1CaloHcalScaleConfigOnlineProd.cc b/L1TriggerConfig/L1ScalesProducers/src/L1CaloHcalScaleConfigOnlineProd.cc index 9f5db9a7f18ac..36a9748c4fbf2 100644 --- a/L1TriggerConfig/L1ScalesProducers/src/L1CaloHcalScaleConfigOnlineProd.cc +++ b/L1TriggerConfig/L1ScalesProducers/src/L1CaloHcalScaleConfigOnlineProd.cc @@ -80,17 +80,10 @@ L1CaloHcalScaleConfigOnlineProd::L1CaloHcalScaleConfigOnlineProd( hcalScale = new L1CaloHcalScale(0); caloTPG = new CaloTPGTranscoderULUT(); + // FIXME!!! HcalTopologyMode::Mode mode = HcalTopologyMode::LHC; int maxDepthHB = 2; int maxDepthHE = 3; - if( iConfig.exists( "hcalTopologyConstants" )) - { - const edm::ParameterSet hcalTopoConsts = iConfig.getParameter( "hcalTopologyConstants" ); - StringToEnumParser parser; - mode = (HcalTopologyMode::Mode) parser.parseString(hcalTopoConsts.getParameter("mode")); - maxDepthHB = hcalTopoConsts.getParameter("maxDepthHB"); - maxDepthHE = hcalTopoConsts.getParameter("maxDepthHE"); - } theTrigTowerGeometry = new HcalTrigTowerGeometry( new HcalTopology( mode, maxDepthHB, maxDepthHE )); } diff --git a/RecoEgamma/EgammaIsolationAlgos/src/EgammaHadTower.cc b/RecoEgamma/EgammaIsolationAlgos/src/EgammaHadTower.cc index efe9f07ede5f6..31addc17dc1c5 100644 --- a/RecoEgamma/EgammaIsolationAlgos/src/EgammaHadTower.cc +++ b/RecoEgamma/EgammaIsolationAlgos/src/EgammaHadTower.cc @@ -8,7 +8,7 @@ EgammaHadTower::EgammaHadTower(const edm::EventSetup &es,HoeMode mode):mode_(mode) { edm::ESHandle ctmaph; - es.get().get(ctmaph); + es.get().get(ctmaph); towerMap_ = &(*ctmaph); NMaxClusters_ = 4; } diff --git a/RecoJets/JetProducers/src/JetSpecific.cc b/RecoJets/JetProducers/src/JetSpecific.cc index 7a2a2e5e49e00..df5cdcecb48b9 100644 --- a/RecoJets/JetProducers/src/JetSpecific.cc +++ b/RecoJets/JetProducers/src/JetSpecific.cc @@ -51,7 +51,7 @@ void reco::writeSpecific(reco::CaloJet & jet, geometry->getSubdetectorGeometry(DetId::Calo, CaloTowerDetId::SubdetId); edm::ESHandle topology; - c.get().get(topology); + c.get().get(topology); // Make the specific reco::CaloJet::Specific specific; diff --git a/RecoLocalCalo/CaloRecCandCreator/src/CaloRecHitCandidateProducer.cc b/RecoLocalCalo/CaloRecCandCreator/src/CaloRecHitCandidateProducer.cc index ecddbf3933cca..44a3d9939f108 100644 --- a/RecoLocalCalo/CaloRecCandCreator/src/CaloRecHitCandidateProducer.cc +++ b/RecoLocalCalo/CaloRecCandCreator/src/CaloRecHitCandidateProducer.cc @@ -94,13 +94,13 @@ CaloRecHitCandidateProducer::CaloRecHitCandidateProducer ( const edm::ParameterS void CaloRecHitCandidateProducer::produce( edm::Event & fEvent, const edm::EventSetup & fSetup) { // get geometry - // const IdealGeometryRecord& record = fSetup.template get(); - const CaloGeometryRecord& caloRecord = fSetup.get(); + ESHandle geometry; - caloRecord.get (geometry); - const IdealGeometryRecord& record = fSetup.get(); + fSetup.get().get (geometry); + ESHandle topology; - record.get (topology); + fSetup.get().get(topology); + // set Output auto_ptr output ( new CandidateCollection ); // get and process Inputs diff --git a/RecoLocalCalo/CaloTowersCreator/src/CaloTowersCreator.cc b/RecoLocalCalo/CaloTowersCreator/src/CaloTowersCreator.cc index 5894c5b8cbf84..8dc3ca1af6b0b 100644 --- a/RecoLocalCalo/CaloTowersCreator/src/CaloTowersCreator.cc +++ b/RecoLocalCalo/CaloTowersCreator/src/CaloTowersCreator.cc @@ -139,8 +139,8 @@ void CaloTowersCreator::produce(edm::Event& e, const edm::EventSetup& c) { edm::ESHandle htopo; edm::ESHandle cttopo; c.get().get(pG); - c.get().get(htopo); - c.get().get(cttopo); + c.get().get(htopo); + c.get().get(cttopo); // ECAL channel status map **************************************** edm::ESHandle ecalChStatus; diff --git a/RecoLocalCalo/CaloTowersCreator/src/CaloTowersReCreator.cc b/RecoLocalCalo/CaloTowersCreator/src/CaloTowersReCreator.cc index 75cfd49a96270..2f74617efa453 100644 --- a/RecoLocalCalo/CaloTowersCreator/src/CaloTowersReCreator.cc +++ b/RecoLocalCalo/CaloTowersCreator/src/CaloTowersReCreator.cc @@ -64,8 +64,8 @@ void CaloTowersReCreator::produce(edm::Event& e, const edm::EventSetup& c) { edm::ESHandle htopo; edm::ESHandle cttopo; c.get().get(pG); - c.get().get(htopo); - c.get().get(cttopo); + c.get().get(htopo); + c.get().get(cttopo); algo_.setEBEScale(EBEScale); algo_.setEEEScale(EEEScale); diff --git a/RecoLocalCalo/HcalRecProducers/src/HBHEIsolatedNoiseReflagger.cc b/RecoLocalCalo/HcalRecProducers/src/HBHEIsolatedNoiseReflagger.cc index e4bdda2f01fa9..8d630c1486743 100644 --- a/RecoLocalCalo/HcalRecProducers/src/HBHEIsolatedNoiseReflagger.cc +++ b/RecoLocalCalo/HcalRecProducers/src/HBHEIsolatedNoiseReflagger.cc @@ -9,7 +9,7 @@ Original Author: John Paul Chou (Brown University) #include "FWCore/Framework/interface/ESHandle.h" #include "FWCore/Framework/interface/EventSetup.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "DataFormats/JetReco/interface/TrackExtrapolation.h" #include "CondFormats/DataRecord/interface/EcalChannelStatusRcd.h" #include "CondFormats/DataRecord/interface/HcalChannelQualityRcd.h" @@ -91,7 +91,7 @@ HBHEIsolatedNoiseReflagger::produce(edm::Event& iEvent, const edm::EventSetup& e // get the calotower mappings edm::ESHandle ctcm; - evSetup.get().get(ctcm); + evSetup.get().get(ctcm); // get the HB/HE hits edm::Handle hbhehits_h; diff --git a/RecoLocalCalo/HcalRecProducers/src/HcalHitReconstructor.cc b/RecoLocalCalo/HcalRecProducers/src/HcalHitReconstructor.cc index 6e6ead481cb65..6aa5c8f778e45 100644 --- a/RecoLocalCalo/HcalRecProducers/src/HcalHitReconstructor.cc +++ b/RecoLocalCalo/HcalRecProducers/src/HcalHitReconstructor.cc @@ -13,7 +13,7 @@ #include "RecoLocalCalo/HcalRecAlgos/interface/HcalSeverityLevelComputerRcd.h" #include "CalibCalorimetry/HcalAlgos/interface/HcalDbASCIIIO.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include #include @@ -224,7 +224,7 @@ void HcalHitReconstructor::beginRun(edm::Run const&r, edm::EventSetup const & es paramTS = new HcalRecoParams(*p.product()); edm::ESHandle htopo; - es.get().get(htopo); + es.get().get(htopo); theTopology=new HcalTopology(*htopo); paramTS->setTopo(theTopology); @@ -243,7 +243,7 @@ void HcalHitReconstructor::beginRun(edm::Run const&r, edm::EventSetup const & es if (theTopology==0) { edm::ESHandle htopo; - es.get().get(htopo); + es.get().get(htopo); theTopology=new HcalTopology(*htopo); } HFDigiTimeParams->setTopo(theTopology); @@ -269,7 +269,7 @@ void HcalHitReconstructor::produce(edm::Event& e, const edm::EventSetup& eventSe // get conditions edm::ESHandle topo; - eventSetup.get().get(topo); + eventSetup.get().get(topo); edm::ESHandle conditions; diff --git a/RecoLocalCalo/HcalRecProducers/src/HcalSimpleReconstructor.cc b/RecoLocalCalo/HcalRecProducers/src/HcalSimpleReconstructor.cc index f32a3ce96e12e..bad744b4f74d8 100644 --- a/RecoLocalCalo/HcalRecProducers/src/HcalSimpleReconstructor.cc +++ b/RecoLocalCalo/HcalRecProducers/src/HcalSimpleReconstructor.cc @@ -71,7 +71,7 @@ void HcalSimpleReconstructor::beginRun(edm::Run const&r, edm::EventSetup const & paramTS = new HcalRecoParams(*p.product()); edm::ESHandle htopo; - es.get().get(htopo); + es.get().get(htopo); theTopology=new HcalTopology(*htopo); paramTS->setTopo(theTopology); diff --git a/RecoLocalCalo/HcalRecProducers/src/ZdcHitReconstructor.cc b/RecoLocalCalo/HcalRecProducers/src/ZdcHitReconstructor.cc index ab4040db92719..58d4c06ff0144 100644 --- a/RecoLocalCalo/HcalRecProducers/src/ZdcHitReconstructor.cc +++ b/RecoLocalCalo/HcalRecProducers/src/ZdcHitReconstructor.cc @@ -12,6 +12,7 @@ #include "RecoLocalCalo/HcalRecAlgos/interface/HcalSeverityLevelComputer.h" #include "RecoLocalCalo/HcalRecAlgos/interface/HcalSeverityLevelComputerRcd.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include @@ -68,7 +69,7 @@ void ZdcHitReconstructor::beginRun(edm::Run const&r, edm::EventSetup const & es) myobject = new HcalLongRecoParams(*p.product()); edm::ESHandle htopo; - es.get().get(htopo); + es.get().get(htopo); theTopology=new HcalTopology(*htopo); myobject->setTopo(theTopology); diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFHCALDualTimeRecHitProducer.cc b/RecoParticleFlow/PFClusterProducer/plugins/PFHCALDualTimeRecHitProducer.cc index 75bbc31279d1d..3fb65719f3d26 100644 --- a/RecoParticleFlow/PFClusterProducer/plugins/PFHCALDualTimeRecHitProducer.cc +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFHCALDualTimeRecHitProducer.cc @@ -145,7 +145,7 @@ void PFHCALDualTimeRecHitProducer::createRecHits(vector& rechits // get the hcal topology edm::ESHandle hcalTopology; - iSetup.get().get( hcalTopology ); + iSetup.get().get( hcalTopology ); //--ab diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.cc b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.cc index 5d850295bb2e6..28670c77a519e 100644 --- a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.cc +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducer.cc @@ -13,7 +13,7 @@ #include "CondFormats/DataRecord/interface/HcalPFCorrsRcd.h" #include "CondFormats/DataRecord/interface/HcalChannelQualityRcd.h" #include "CondFormats/DataRecord/interface/EcalChannelStatusRcd.h" -#include "Geometry/Records/interface/IdealGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" using namespace std; using namespace edm; @@ -83,7 +83,7 @@ PFRecHitProducer::beginRun(const edm::Run& run, theEcalChStatus = ecalChStatus.product(); edm::ESHandle cttopo; - es.get().get(cttopo); + es.get().get(cttopo); theTowerConstituentsMap = cttopo.product(); } diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHCAL.cc b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHCAL.cc index f15f40f5e7915..df01b77429bbd 100644 --- a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHCAL.cc +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHCAL.cc @@ -962,7 +962,7 @@ void PFRecHitProducerHCAL::createRecHits(vector& rechits, // get the hcal topology edm::ESHandle hcalTopology; - iSetup.get().get( hcalTopology ); + iSetup.get().get( hcalTopology ); // HCAL rechits // vector > hcalHandles; diff --git a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHO.cc b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHO.cc index 80ccc99ebe36c..b1be97a22e989 100644 --- a/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHO.cc +++ b/RecoParticleFlow/PFClusterProducer/plugins/PFRecHitProducerHO.cc @@ -82,7 +82,7 @@ PFRecHitProducerHO::createRecHits(vector& rechits, // get the HO topology edm::ESHandle hcalBarrelTopology; - iSetup.get().get(hcalBarrelTopology); + iSetup.get().get(hcalBarrelTopology); if(!neighbourmapcalculated_) hoNeighbArray( *hcalBarrelGeometry, diff --git a/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py b/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py index ed46360f8ccb5..c85d5f0eb2f34 100644 --- a/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py +++ b/SLHCUpgradeSimulations/Configuration/python/HCalCustoms.py @@ -5,20 +5,8 @@ def customise_HcalPhase0(process): if hasattr(process,'mix') and hasattr(process.mix,'digitizers') and hasattr(process.mix.digitizers,'hcal'): process.mix.digitizers.hcal.HcalReLabel.RelabelHits=cms.untracked.bool(True) - process.mix.digitizers.hcal.HcalReLabel.RelabelRules.Eta1 = cms.untracked.vint32(1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) - process.mix.digitizers.hcal.HcalReLabel.RelabelRules.Eta16 = cms.untracked.vint32(1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3) - process.mix.digitizers.hcal.HcalReLabel.RelabelRules.Eta17 = cms.untracked.vint32(1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) - process.mix.digitizers.hcal.HcalReLabel.RelabelRules.Eta18 = cms.untracked.vint32(1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2) - process.mix.digitizers.hcal.HcalReLabel.RelabelRules.Eta19 = cms.untracked.vint32(1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2) - process.mix.digitizers.hcal.HcalReLabel.RelabelRules.Eta27 = cms.untracked.vint32(1,1,1,1,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3) process.es_hardcode.HcalReLabel.RelabelHits = cms.untracked.bool(True) - process.es_hardcode.HcalReLabel.RelabelRules.Eta1 = cms.untracked.vint32(1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) - process.es_hardcode.HcalReLabel.RelabelRules.Eta16 = cms.untracked.vint32(1,1,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3) - process.es_hardcode.HcalReLabel.RelabelRules.Eta17 = cms.untracked.vint32(1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1) - process.es_hardcode.HcalReLabel.RelabelRules.Eta18 = cms.untracked.vint32(1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2) - process.es_hardcode.HcalReLabel.RelabelRules.Eta19 = cms.untracked.vint32(1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2) - process.es_hardcode.HcalReLabel.RelabelRules.Eta27 = cms.untracked.vint32(1,1,1,1,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3) process.es_hardcode.HEreCalibCutoff = cms.double(20.) #for aging process.es_hardcode.toGet = cms.untracked.vstring( @@ -26,7 +14,6 @@ def customise_HcalPhase0(process): 'RespCorrs' ) - if hasattr(process,'g4SimHits'): process=customise_Sim(process) if hasattr(process,'validation_step'): @@ -58,20 +45,11 @@ def customise_HcalPhase1(process): 'CovarianceMatrices' ) - process.es_hardcode.hcalTopologyConstants.mode=cms.string('HcalTopologyMode::SLHC') - process.es_hardcode.hcalTopologyConstants.maxDepthHB=cms.int32(3) - process.es_hardcode.hcalTopologyConstants.maxDepthHB=cms.int32(3) - process.es_hardcode.hcalTopologyConstants.maxDepthHE=cms.int32(5) process.es_hardcode.HcalReLabel.RelabelHits=cms.untracked.bool(True) # Special Upgrade trick (if absent - regular case assumed) process.es_hardcode.GainWidthsForTrigPrims = cms.bool(True) process.es_hardcode.HEreCalibCutoff = cms.double(100.) #for aging - process.hcalTopologyIdeal.hcalTopologyConstants.mode=cms.string('HcalTopologyMode::SLHC') - process.hcalTopologyIdeal.hcalTopologyConstants.maxDepthHB=cms.int32(3) - process.hcalTopologyIdeal.hcalTopologyConstants.maxDepthHE=cms.int32(5) - - if hasattr(process,'g4SimHits'): process=customise_Sim(process) if hasattr(process,'DigiToRaw'): @@ -119,11 +97,6 @@ def customise_Digi(process): process.mix.digitizers.hcal.HcalReLabel.RelabelHits=cms.untracked.bool(True) process.mix.digitizers.hcal.doTimeSlew = False - if hasattr(process,'HcalTPGCoderULUT'): - process.HcalTPGCoderULUT.hcalTopologyConstants.mode=cms.string('HcalTopologyMode::SLHC') - process.HcalTPGCoderULUT.hcalTopologyConstants.maxDepthHB=cms.int32(3) - process.HcalTPGCoderULUT.hcalTopologyConstants.maxDepthHE=cms.int32(5) - if hasattr(process,'simHcalDigis'): process.simHcalDigis.useConfigZSvalues=cms.int32(1) process.simHcalDigis.HBlevel=cms.int32(16) diff --git a/SimCalorimetry/HcalSimAlgos/src/HcalShapes.cc b/SimCalorimetry/HcalSimAlgos/src/HcalShapes.cc index 0773ea3fd7aaa..11bc565da35bf 100644 --- a/SimCalorimetry/HcalSimAlgos/src/HcalShapes.cc +++ b/SimCalorimetry/HcalSimAlgos/src/HcalShapes.cc @@ -8,6 +8,7 @@ #include "DataFormats/HcalDetId/interface/HcalGenericDetId.h" #include "FWCore/MessageLogger/interface/MessageLogger.h" #include "Geometry/CaloTopology/interface/HcalTopology.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" HcalShapes::HcalShapes() : theMCParams(0), @@ -109,7 +110,7 @@ void HcalShapes::beginRun(edm::EventSetup const & es) // here we are making a _copy_ so we need to add a copy of the topology... edm::ESHandle htopo; - es.get().get(htopo); + es.get().get(htopo); theTopology=new HcalTopology(*htopo); theMCParams->setTopo(theTopology); } diff --git a/SimCalorimetry/HcalSimProducers/BuildFile.xml b/SimCalorimetry/HcalSimProducers/BuildFile.xml index 0906cb516e146..a3f3449ad31d3 100644 --- a/SimCalorimetry/HcalSimProducers/BuildFile.xml +++ b/SimCalorimetry/HcalSimProducers/BuildFile.xml @@ -5,6 +5,7 @@ + diff --git a/SimCalorimetry/HcalSimProducers/interface/HcalDigitizer.h b/SimCalorimetry/HcalSimProducers/interface/HcalDigitizer.h index 08f8ba4ca7760..327c6c79672a8 100644 --- a/SimCalorimetry/HcalSimProducers/interface/HcalDigitizer.h +++ b/SimCalorimetry/HcalSimProducers/interface/HcalDigitizer.h @@ -11,6 +11,7 @@ #include "SimCalorimetry/HcalSimAlgos/interface/ZDCHitFilter.h" #include "SimCalorimetry/HcalSimProducers/interface/HcalHitRelabeller.h" #include "Geometry/CaloGeometry/interface/CaloGeometry.h" +#include "Geometry/HcalCommonData/interface/HcalDDDRecConstants.h" #include "DataFormats/DetId/interface/DetId.h" #include "FWCore/Framework/interface/Frameworkfwd.h" #include "DataFormats/HcalCalibObjects/interface/HEDarkening.h" @@ -60,6 +61,7 @@ class HcalDigitizer /// exist in the geometry void checkGeometry(const edm::EventSetup& eventSetup); const CaloGeometry * theGeometry; + const HcalDDDRecConstants * theRecNumber; void updateGeometry(const edm::EventSetup& eventSetup); void buildHOSiPMCells(const std::vector& allCells, const edm::EventSetup& eventSetup); diff --git a/SimCalorimetry/HcalSimProducers/interface/HcalHitRelabeller.h b/SimCalorimetry/HcalSimProducers/interface/HcalHitRelabeller.h index 813ebd968ff6e..a0074a6c48e99 100644 --- a/SimCalorimetry/HcalSimProducers/interface/HcalHitRelabeller.h +++ b/SimCalorimetry/HcalSimProducers/interface/HcalHitRelabeller.h @@ -5,20 +5,19 @@ #include "Geometry/CaloGeometry/interface/CaloGeometry.h" #include "SimDataFormats/CaloHit/interface/PCaloHit.h" #include "DataFormats/DetId/interface/DetId.h" +#include "Geometry/HcalCommonData/interface/HcalDDDRecConstants.h" #include "FWCore/ParameterSet/interface/ParameterSet.h" class HcalHitRelabeller { public: HcalHitRelabeller(const edm::ParameterSet& ps); void process(std::vector & hcalHits); - void setGeometry(const CaloGeometry *& theGeometry); + void setGeometry(const CaloGeometry *& , const HcalDDDRecConstants *& ); + DetId relabel(const uint32_t testId) const; private: - DetId relabel(const uint32_t testId) const; const CaloGeometry* theGeometry; - - std::vector > m_segmentation; - bool m_CorrectPhi; + const HcalDDDRecConstants* theRecNumber; }; #endif diff --git a/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc b/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc index 35bb13025649b..46bf06e671fe7 100644 --- a/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc +++ b/SimCalorimetry/HcalSimProducers/src/HcalDigitizer.cc @@ -23,6 +23,7 @@ #include "SimCalorimetry/CaloSimAlgos/interface/CaloTDigitizer.h" #include "DataFormats/HcalDigi/interface/HcalDigiCollections.h" #include "Geometry/Records/interface/CaloGeometryRecord.h" +#include "Geometry/Records/interface/HcalRecNumberingRecord.h" #include "CalibFormats/HcalObjects/interface/HcalDbService.h" #include "CalibFormats/HcalObjects/interface/HcalDbRecord.h" #include "SimDataFormats/CrossingFrame/interface/CrossingFrame.h" @@ -146,9 +147,9 @@ HcalDigitizer::HcalDigitizer(const edm::ParameterSet& ps) : double HOtp = ps.getParameter("HOTuningParameter"); bool doHBHEUpgrade = ps.getParameter("HBHEUpgradeQIE"); bool doHFUpgrade = ps.getParameter("HFUpgradeQIE"); - deliveredLumi = ps.getParameter("DelivLuminosity"); - bool agingFlagHE = ps.getParameter("HEDarkening"); - bool agingFlagHF = ps.getParameter("HFDarkening"); + deliveredLumi = ps.getParameter("DelivLuminosity"); + bool agingFlagHE = ps.getParameter("HEDarkening"); + bool agingFlagHF = ps.getParameter("HFDarkening"); // need to make copies, because they might get different noise generators theHBHEAmplifier = new HcalAmplifier(theParameterMap, doNoise); @@ -601,10 +602,12 @@ void HcalDigitizer::checkGeometry(const edm::EventSetup & eventSetup) { // TODO find a way to avoid doing this every event edm::ESHandle geometry; eventSetup.get().get(geometry); + edm::ESHandle pHRNDC; + eventSetup.get().get(pHRNDC); // See if it's been updated - if(&*geometry != theGeometry) - { + if(&*geometry != theGeometry) { theGeometry = &*geometry; + theRecNumber= &*pHRNDC; updateGeometry(eventSetup); } } @@ -617,7 +620,7 @@ void HcalDigitizer::updateGeometry(const edm::EventSetup & eventSetup) { if(theHOSiPMResponse) theHOSiPMResponse->setGeometry(theGeometry); theHFResponse->setGeometry(theGeometry); theZDCResponse->setGeometry(theGeometry); - if(theRelabeller) theRelabeller->setGeometry(theGeometry); + if(theRelabeller) theRelabeller->setGeometry(theGeometry,theRecNumber); const std::vector& hbCells = theGeometry->getValidDetIds(DetId::Hcal, HcalBarrel); const std::vector& heCells = theGeometry->getValidDetIds(DetId::Hcal, HcalEndcap); @@ -663,7 +666,7 @@ void HcalDigitizer::buildHOSiPMCells(const std::vector& allCells, const e edm::ESHandle p; eventSetup.get().get(p); edm::ESHandle htopo; - eventSetup.get().get(htopo); + eventSetup.get().get(htopo); HcalMCParams mcParams(*p.product()); if (mcParams.topo()==0) { @@ -705,26 +708,26 @@ void HcalDigitizer::darkening(std::vector& hcalHits){ int det, z, depth, ieta, phi, lay; HcalTestNumbering::unpackHcalIndex(tmpId,det,z,depth,ieta,phi,lay); - bool darkened = false; - float dweight = 1.; + bool darkened = false; + float dweight = 1.; - //HE darkening - if(det==int(HcalEndcap) && m_HEDarkening){ - dweight = m_HEDarkening->degradation(deliveredLumi,ieta,lay-2);//NB:diff. layer count - darkened = true; + //HE darkening + if(det==int(HcalEndcap) && m_HEDarkening){ + dweight = m_HEDarkening->degradation(deliveredLumi,ieta,lay-2);//NB:diff. layer count + darkened = true; } - //HF darkening - approximate: invert recalibration factor - else if(det==int(HcalForward) && m_HFRecalibration){ - dweight = 1.0/m_HFRecalibration->getCorr(ieta,depth,deliveredLumi); - darkened = true; + //HF darkening - approximate: invert recalibration factor + else if(det==int(HcalForward) && m_HFRecalibration){ + dweight = 1.0/m_HFRecalibration->getCorr(ieta,depth,deliveredLumi); + darkened = true; } //create new hit with darkened energy - //if(darkened) hcalHits[ii] = PCaloHit(hcalHits[ii].energyEM()*dweight,hcalHits[ii].energyHad()*dweight,hcalHits[ii].time(),hcalHits[ii].geantTrackId(),hcalHits[ii].id()); - - //reset hit energy - if(darkened) hcalHits[ii].setEnergy(hcalHits[ii].energy()*dweight); + //if(darkened) hcalHits[ii] = PCaloHit(hcalHits[ii].energyEM()*dweight,hcalHits[ii].energyHad()*dweight,hcalHits[ii].time(),hcalHits[ii].geantTrackId(),hcalHits[ii].id()); + + //reset hit energy + if(darkened) hcalHits[ii].setEnergy(hcalHits[ii].energy()*dweight); } } diff --git a/SimCalorimetry/HcalSimProducers/src/HcalHitRelabeller.cc b/SimCalorimetry/HcalSimProducers/src/HcalHitRelabeller.cc index 056305caf4db3..490d18c3c1701 100644 --- a/SimCalorimetry/HcalSimProducers/src/HcalHitRelabeller.cc +++ b/SimCalorimetry/HcalSimProducers/src/HcalHitRelabeller.cc @@ -4,78 +4,62 @@ #include "Geometry/CaloGeometry/interface/CaloSubdetectorGeometry.h" #include "Geometry/CaloGeometry/interface/CaloCellGeometry.h" +#include "FWCore/MessageLogger/interface/MessageLogger.h" -//#define DEBUG +//#define DebugLog -HcalHitRelabeller::HcalHitRelabeller(const edm::ParameterSet& ps) { - // try to make sure the memory gets pinned in place - m_segmentation.resize(29); - m_CorrectPhi = ps.getUntrackedParameter("CorrectPhi",false); - for (int i=0; i<29; i++) { - char name[10]; - snprintf(name,10,"Eta%d",i+1); - if (i>0) { - m_segmentation[i]=ps.getUntrackedParameter >(name,m_segmentation[i-1]); - } else { - m_segmentation[i]=ps.getUntrackedParameter >(name); - } - } -#ifdef DEBUG - for (int i=0; i<29; i++) { - std::cout << "Segmentation[" << i << "] with " << m_segmentation[i].size() << " elements:"; - for (unsigned int k=0; k& hcalHits) { - for (unsigned int ii=0; iigetSubdetectorGeometry(newcell)->getGeometry(newcell); - GlobalPoint globalposition = (GlobalPoint)(cellGeometry->getPosition()); - - std::cout << "PCaloHit " << newcell << " position: " << globalposition << std::endl; - std::cout.flush(); + DetId newid = relabel(hcalHits[ii].id()); +#ifdef DebugLog + std::cout << "Hit " << ii << " out of " << hcalHits.size() << " " << std::hex << newid.rawId() << std::dec << '\n'; +// HcalDetId newcell(newid); +// if (theGeometry) { +// const CaloCellGeometry *cellGeometry = +// theGeometry->getSubdetectorGeometry(newcell)->getGeometry(newcell); +// GlobalPoint globalposition =(GlobalPoint)(cellGeometry->getPosition()); +// std::cout << "PCaloHit " << newcell << " position: " << globalposition +// << std::endl; +// } +// std::cout.flush(); #endif - hcalHits[ii].setID(newid.rawId()); -#ifdef DEBUG - std::cout << "Modified Hit " << hcalHits[ii] << std::endl; + hcalHits[ii].setID(newid.rawId()); +#ifdef DebugLog + std::cout << "Modified Hit " << hcalHits[ii] << std::endl; #endif + } + } else { + edm::LogWarning("HcalSim") << "HcalHitRelabeller: no valid HcalDDDRecConstants"; } - //End Change by Wetzel } -void HcalHitRelabeller::setGeometry(const CaloGeometry*& geom) { - theGeometry = geom; +void HcalHitRelabeller::setGeometry(const CaloGeometry*& geom, + const HcalDDDRecConstants *& recNum) { + theGeometry = geom; + theRecNumber = recNum; } DetId HcalHitRelabeller::relabel(const uint32_t testId) const { -#ifdef DEBUG +#ifdef DebugLog std::cout << "Enter HcalHitRelabeller::relabel " << std::endl; #endif HcalDetId hid; - int det, z, depth, eta, phi, layer, sign; + int det, z, depth, eta, phi, layer, sign; HcalTestNumbering::unpackHcalIndex(testId,det,z,depth,eta,phi,layer); - - layer-=1; // one is added in the simulation, here used for indexing - + HcalDDDRecConstants::HcalID id = theRecNumber->getHCID(det,eta,phi,layer,depth); sign=(z==0)?(-1):(1); -#ifdef DEBUG +#ifdef DebugLog std::cout << "det: " << det << " " << "z: " << z << " " << "depth: " << depth << " " @@ -84,43 +68,23 @@ DetId HcalHitRelabeller::relabel(const uint32_t testId) const { << "layer: " << layer << " "; std::cout.flush(); #endif - int newDepth = 0; // moved out of if's just for printing purposes... - int phi_skip = phi; - if (m_CorrectPhi) { - if (eta >= 40) phi_skip = (phi-1)*4 - 1; - else if (eta > 20) phi_skip = (phi-1)*2 + 1; - if (phi_skip < 0) phi_skip += 72; - } if (det==int(HcalBarrel)) { - newDepth=m_segmentation[eta-1][layer]; - if(eta==16 && newDepth > 2) newDepth=2;// tower 16 HACK to be watched out.. - hid=HcalDetId(HcalBarrel,eta*sign,phi_skip,newDepth); - } - if (det==int(HcalEndcap)) { - newDepth=m_segmentation[eta-1][layer]; - if (eta==16 && newDepth<3) newDepth=3; // tower 16 HACK to be watched out.. - hid=HcalDetId(HcalEndcap,eta*sign,phi_skip,newDepth); - } - if (det==int(HcalOuter)) { - hid=HcalDetId(HcalOuter,eta*sign,phi_skip,4); - newDepth = 4; - } - if (det==int(HcalForward)) { - hid=HcalDetId(HcalForward,eta*sign,phi_skip,depth); - newDepth = depth; + hid=HcalDetId(HcalBarrel,sign*id.eta,id.phi,id.depth); + } else if (det==int(HcalEndcap)) { + hid=HcalDetId(HcalEndcap,sign*id.eta,id.phi,id.depth); + } else if (det==int(HcalOuter)) { + hid=HcalDetId(HcalOuter,sign*id.eta,id.phi,id.depth); + } else if (det==int(HcalForward)) { + hid=HcalDetId(HcalForward,sign*id.eta,id.phi,id.depth); } -#ifdef DEBUG +#ifdef DebugLog std::cout << " new HcalDetId -> hex.RawID = " << std::hex << hid.rawId() << std::dec; std::cout.flush(); - std::cout << " det, z, depth, eta, phi = " - << det << " " - << z << " " - << newDepth << " " - << eta << " " - << phi << " " << phi_skip << " " - << " ---> " << hid << std::endl; + std::cout << " det, z, depth, eta, phi = " << det << " " + << z << " "<< id.depth << " " << id.eta << " " + << id.phi << " ---> " << hid << std::endl; #endif return hid; } diff --git a/SimCalorimetry/HcalTrigPrimProducers/python/hcaltpdigi_cff.py b/SimCalorimetry/HcalTrigPrimProducers/python/hcaltpdigi_cff.py index fbb84853ffe99..f144f355a1900 100644 --- a/SimCalorimetry/HcalTrigPrimProducers/python/hcaltpdigi_cff.py +++ b/SimCalorimetry/HcalTrigPrimProducers/python/hcaltpdigi_cff.py @@ -17,7 +17,4 @@ RCalibFile = cms.FileInPath('CalibCalorimetry/HcalTPGAlgos/data/RecHit-TPG-calib.dat') ) -import Geometry.HcalEventSetup.hcalTopologyConstants_cfi as hcalTopologyConstants_cfi -HcalTPGCoderULUT.hcalTopologyConstants = cms.PSet(hcalTopologyConstants_cfi.hcalTopologyConstants) - HcalTrigTowerGeometryESProducer = cms.ESProducer("HcalTrigTowerGeometryESProducer")