Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2022-05-24 22:30:01

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 import RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi
0004 
0005 interestingEcalDetIdEB = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0006     basicClustersLabel = "hybridSuperClusters:hybridBarrelBasicClusters",
0007     recHitsLabel       = "ecalRecHit:EcalRecHitsEB"
0008     )
0009 
0010 interestingEcalDetIdEBU = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0011     basicClustersLabel = "hybridSuperClusters:uncleanOnlyHybridBarrelBasicClusters",
0012     recHitsLabel       = "ecalRecHit:EcalRecHitsEB"
0013     )
0014 
0015 interestingEcalDetIdEE = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0016     basicClustersLabel = "multi5x5SuperClusters:multi5x5EndcapBasicClusters",
0017     recHitsLabel       = "ecalRecHit:EcalRecHitsEE"
0018     )
0019 
0020 interestingEcalDetIdPFEB = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0021     basicClustersLabel = "particleFlowSuperClusterECAL:particleFlowBasicClusterECALBarrel",
0022     recHitsLabel       = "ecalRecHit:EcalRecHitsEB"
0023     )
0024 
0025 interestingEcalDetIdPFEE = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0026     basicClustersLabel = "particleFlowSuperClusterECAL:particleFlowBasicClusterECALEndcap",
0027     recHitsLabel       = "ecalRecHit:EcalRecHitsEE"
0028     )
0029 
0030 interestingEcalDetIdPFES = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0031     basicClustersLabel = "particleFlowSuperClusterECAL:particleFlowBasicClusterECALPreshower",
0032     recHitsLabel       = "ecalPreshowerRecHit:EcalRecHitsES",
0033     severityLevel      = -1,
0034     keepNextToDead     = False,
0035     keepNextToBoundary = False    
0036     )
0037 
0038 interestingEcalDetIdOOTPFEB = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0039     basicClustersLabel = "particleFlowSuperClusterOOTECAL:particleFlowBasicClusterOOTECALBarrel",
0040     recHitsLabel       = "ecalRecHit:EcalRecHitsEB"
0041     )
0042 
0043 interestingEcalDetIdOOTPFEE = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0044     basicClustersLabel = "particleFlowSuperClusterOOTECAL:particleFlowBasicClusterOOTECALEndcap",
0045     recHitsLabel       = "ecalRecHit:EcalRecHitsEE"
0046     )
0047 
0048 interestingEcalDetIdOOTPFES = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0049     basicClustersLabel = "particleFlowSuperClusterOOTECAL:particleFlowBasicClusterOOTECALPreshower",
0050     recHitsLabel       = "ecalPreshowerRecHit:EcalRecHitsES",
0051     severityLevel      = -1,
0052     keepNextToDead     = False,
0053     keepNextToBoundary = False    
0054     )
0055 
0056 interestingEcalDetIdRefinedEB = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0057     basicClustersLabel = "particleFlowEGamma:EBEEClusters",
0058     recHitsLabel       = "ecalRecHit:EcalRecHitsEB"
0059     )
0060 
0061 interestingEcalDetIdRefinedEE = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0062     basicClustersLabel = "particleFlowEGamma:EBEEClusters",
0063     recHitsLabel       = "ecalRecHit:EcalRecHitsEE"
0064     )
0065 
0066 interestingEcalDetIdRefinedES = RecoEcal.EgammaClusterProducers.interestingDetIdCollectionProducer_cfi.interestingDetIdCollectionProducer.clone(
0067     basicClustersLabel = "particleFlowEGamma:ESClusters",
0068     recHitsLabel       = "ecalPreshowerRecHit:EcalRecHitsES",
0069     severityLevel      = -1,
0070     keepNextToDead     = False,
0071     keepNextToBoundary = False    
0072     )
0073     
0074 # rechits associated to high pt tracks for HSCP
0075 
0076 from TrackingTools.TrackAssociator.default_cfi import TrackAssociatorParameterBlock
0077 
0078 interestingTrackEcalDetIds = cms.EDProducer('InterestingTrackEcalDetIdProducer',
0079     TrackAssociatorParameterBlock,
0080     TrackCollection = cms.InputTag("generalTracks"),
0081     MinTrackPt      = cms.double(50.0)
0082 )
0083 
0084 reducedEcalRecHitsEB = cms.EDProducer("ReducedRecHitCollectionProducer",
0085     recHitsLabel = cms.InputTag("ecalRecHit","EcalRecHitsEB"),
0086     interestingDetIdCollections = cms.VInputTag(
0087             # ecal
0088             cms.InputTag("interestingEcalDetIdEB"),
0089             cms.InputTag("interestingEcalDetIdEBU"),
0090             #ged
0091             cms.InputTag("interestingEcalDetIdPFEB"),
0092             cms.InputTag("interestingEcalDetIdRefinedEB"),
0093             # oot
0094             cms.InputTag("interestingEcalDetIdOOTPFEB"),
0095             # egamma
0096             cms.InputTag("interestingGedEleIsoDetIdEB"),
0097             cms.InputTag("interestingGedGamIsoDetIdEB"),
0098             cms.InputTag("interestingOotGamIsoDetIdEB"),
0099             cms.InputTag("interestingGamIsoDetIdEB"),
0100             # tau
0101             #cms.InputTag("caloRecoTauProducer"),
0102             # muons
0103             cms.InputTag("muonEcalDetIds"),
0104             # high pt tracks
0105             cms.InputTag("interestingTrackEcalDetIds")
0106             ),
0107     reducedHitsCollection = cms.string('')
0108 )
0109 
0110 reducedEcalRecHitsEE = cms.EDProducer("ReducedRecHitCollectionProducer",
0111     recHitsLabel = cms.InputTag("ecalRecHit","EcalRecHitsEE"),
0112     interestingDetIdCollections = cms.VInputTag(
0113             # ecal
0114             cms.InputTag("interestingEcalDetIdEE"),
0115             #ged
0116             cms.InputTag("interestingEcalDetIdPFEE"),
0117             cms.InputTag("interestingEcalDetIdRefinedEE"),            
0118             # oot
0119             cms.InputTag("interestingEcalDetIdOOTPFEE"),
0120             # egamma
0121             cms.InputTag("interestingGedEleIsoDetIdEE"),
0122             cms.InputTag("interestingGedGamIsoDetIdEE"),
0123             cms.InputTag("interestingOotGamIsoDetIdEE"),
0124             cms.InputTag("interestingGamIsoDetIdEE"),
0125             # tau
0126             #cms.InputTag("caloRecoTauProducer"),
0127             # muons
0128             cms.InputTag("muonEcalDetIds"),
0129             # high pt tracks
0130             cms.InputTag("interestingTrackEcalDetIds")
0131             ),
0132     reducedHitsCollection = cms.string('')
0133 )
0134 
0135 reducedEcalRecHitsES = cms.EDProducer("ReducedESRecHitCollectionProducer",
0136                                       scEtThreshold = cms.double(15),
0137                                       EcalRecHitCollectionES = cms.InputTag('ecalPreshowerRecHit','EcalRecHitsES'),
0138                                       EndcapSuperClusterCollection = cms.InputTag('correctedMulti5x5SuperClustersWithPreshower'),
0139                                       OutputLabel_ES = cms.string(''),
0140                                       interestingDetIds = cms.VInputTag(
0141                                         cms.InputTag("interestingEcalDetIdPFES"),
0142                                         cms.InputTag("interestingEcalDetIdRefinedES"), 
0143                                         cms.InputTag("interestingEcalDetIdOOTPFES"),
0144                                       ),
0145                                       interestingDetIdsNotToClean = cms.VInputTag(
0146                                           cms.InputTag("interestingOotEgammaIsoESDetId"),
0147                                       )
0148 )
0149 
0150 #selected digis
0151 from RecoEcal.EgammaClusterProducers.ecalDigiSelector_cff import *
0152 
0153 reducedEcalRecHitsTask = cms.Task(interestingEcalDetIdEB,interestingEcalDetIdEBU,
0154                                           interestingEcalDetIdEE,
0155                                           interestingEcalDetIdPFEB,interestingEcalDetIdPFEE,interestingEcalDetIdPFES,
0156                                           interestingEcalDetIdOOTPFEB,interestingEcalDetIdOOTPFEE,interestingEcalDetIdOOTPFES,
0157                                           interestingEcalDetIdRefinedEB,interestingEcalDetIdRefinedEE,interestingEcalDetIdRefinedES,
0158                                           interestingTrackEcalDetIds,
0159                                           reducedEcalRecHitsEB,
0160                                           reducedEcalRecHitsEE,
0161                                           seldigisTask,
0162                                           reducedEcalRecHitsES)
0163 reducedEcalRecHitsSequence = cms.Sequence(reducedEcalRecHitsTask)
0164                                           
0165 reducedEcalRecHitsSequenceEcalOnlyTask = cms.Task(interestingEcalDetIdEB,interestingEcalDetIdEBU,
0166                                           interestingEcalDetIdEE,
0167                                           reducedEcalRecHitsEB,
0168                                           reducedEcalRecHitsEE,
0169                                           seldigisTask)
0170 reducedEcalRecHitsSequenceEcalOnly = cms.Sequence(reducedEcalRecHitsSequenceEcalOnlyTask)
0171 
0172 _phase2_reducedEcalRecHitsTask = reducedEcalRecHitsTask.copy()
0173 _phase2_reducedEcalRecHitsTask.remove(reducedEcalRecHitsES)
0174 
0175 from Configuration.Eras.Modifier_phase2_common_cff import phase2_common
0176 phase2_common.toReplaceWith( reducedEcalRecHitsTask , _phase2_reducedEcalRecHitsTask )
0177 
0178 
0179 _fastSim_reducedEcalRecHitsTask = reducedEcalRecHitsTask.copyAndExclude(seldigisTask)
0180 from Configuration.Eras.Modifier_fastSim_cff import fastSim
0181 fastSim.toReplaceWith( reducedEcalRecHitsTask, _fastSim_reducedEcalRecHitsTask)
0182 
0183 _pp_on_AA_reducedEcalRecHitsTask = reducedEcalRecHitsTask.copy()
0184 _pp_on_AA_reducedEcalRecHitsTask.remove(interestingEcalDetIdOOTPFEB)
0185 _pp_on_AA_reducedEcalRecHitsTask.remove(interestingEcalDetIdOOTPFEE)
0186 _pp_on_AA_reducedEcalRecHitsTask.remove(interestingEcalDetIdOOTPFES)
0187 
0188 from Configuration.ProcessModifiers.pp_on_AA_cff import pp_on_AA
0189 pp_on_AA.toReplaceWith(reducedEcalRecHitsTask, _pp_on_AA_reducedEcalRecHitsTask)
0190 
0191 pp_on_AA.toModify(reducedEcalRecHitsEB.interestingDetIdCollections, func = lambda list: list.remove(cms.InputTag("interestingEcalDetIdOOTPFEB")) )
0192 pp_on_AA.toModify(reducedEcalRecHitsEB.interestingDetIdCollections, func = lambda list: list.remove(cms.InputTag("interestingOotGamIsoDetIdEB")) )
0193 pp_on_AA.toModify(reducedEcalRecHitsEE.interestingDetIdCollections, func = lambda list: list.remove(cms.InputTag("interestingEcalDetIdOOTPFEE")) )
0194 pp_on_AA.toModify(reducedEcalRecHitsEE.interestingDetIdCollections, func = lambda list: list.remove(cms.InputTag("interestingOotGamIsoDetIdEE")) )
0195 pp_on_AA.toModify(reducedEcalRecHitsES.interestingDetIds, func = lambda list: list.remove(cms.InputTag("interestingEcalDetIdOOTPFES")) )
0196 pp_on_AA.toModify(reducedEcalRecHitsES.interestingDetIdsNotToClean, func = lambda list: list.remove(cms.InputTag("interestingOotEgammaIsoESDetId")) )
0197 
0198 from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
0199 egamma_lowPt_exclusive.toModify(reducedEcalRecHitsES,
0200                            scEtThreshold = 1.0)