Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Light by light modifier 1100 pre1 #27633

Merged
merged 9 commits into from
Aug 22, 2019
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import FWCore.ParameterSet.Config as cms

egamma_lowPt_exclusive = cms.Modifier()
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,8 @@
selectedEcalEBDigiCollection = cms.string('selectedEcalEBDigiCollection'),
selectedEcalEEDigiCollection = cms.string('selectedEcalEEDigiCollection')
)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(selectDigi,
cluster_pt_thresh = 1.0,
single_cluster_thresh = 1.0)
Original file line number Diff line number Diff line change
Expand Up @@ -155,3 +155,10 @@
pp_on_AA_2018.toModify(particleFlowSuperClusterECAL, useDynamicDPhiWindow = False)
pp_on_AA_2018.toModify(particleFlowSuperClusterECAL, phiwidth_SuperClusterBarrel = 0.20)
pp_on_AA_2018.toModify(particleFlowSuperClusterECAL, phiwidth_SuperClusterEndcap = 0.20)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(particleFlowSuperClusterECAL,
thresh_SCEt = 1.0,
thresh_PFClusterSeedBarrel = 0.5,
thresh_PFClusterSeedEndcap = 0.5)

Original file line number Diff line number Diff line change
Expand Up @@ -195,3 +195,7 @@
pp_on_AA_2018.toModify(reducedEcalRecHitsEE.interestingDetIdCollections, func = lambda list: list.remove(cms.InputTag("interestingOotGamIsoDetIdEE")) )
pp_on_AA_2018.toModify(reducedEcalRecHitsES.interestingDetIds, func = lambda list: list.remove(cms.InputTag("interestingEcalDetIdOOTPFES")) )
pp_on_AA_2018.toModify(reducedEcalRecHitsES.interestingDetIdsNotToClean, func = lambda list: list.remove(cms.InputTag("interestingOotEgammaIsoESDetId")) )

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(reducedEcalRecHitsES,
scEtThreshold = 1.0)
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,10 @@
SeedConfiguration = dict( allowHGCal = True )
)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(ecalDrivenElectronSeeds.SeedConfiguration,
LowPtThreshold =1.0,
applyHOverECut = False)

# create ecal driven seeds for electron using HGCal Multiclusters
ecalDrivenElectronSeedsFromMultiCl = ecalDrivenElectronSeeds.clone(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,3 +63,11 @@
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(gedGsfElectronsTmp.preselection, minSCEtBarrel = 15.0)
pp_on_AA_2018.toModify(gedGsfElectronsTmp.preselection, minSCEtEndcaps = 15.0)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(gedGsfElectronsTmp.preselection,
minSCEtBarrel = 1.0,
minSCEtEndcaps = 1.0)
egamma_lowPt_exclusive.toModify(gedGsfElectronsTmp,
applyPreselection = False)

8 changes: 8 additions & 0 deletions RecoEgamma/EgammaElectronProducers/python/gsfElectrons_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,3 +117,11 @@
ecalDrivenGsfElectronsFromMultiCl = ecalDrivenGsfElectrons.clone(
gsfElectronCoresTag = "ecalDrivenGsfElectronCoresFromMultiCl",
)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(gsfElectrons.preselection,
minSCEtBarrel = 1.0,
minSCEtEndcaps = 1.0)

egamma_lowPt_exclusive.toModify(gsfElectrons,
applyPreselection = False)
Original file line number Diff line number Diff line change
Expand Up @@ -136,3 +136,15 @@

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toReplaceWith(interestingEgammaIsoDetIdsTask, _pp_on_AA_interestingEgammaIsoDetIdsTask)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(interestingGedEgammaIsoESDetId,
minSCEt = 1.0, #default 500
minEleEt = 1.0, #default 20
minPhoEt = 1.0 #default 20
)
egamma_lowPt_exclusive.toModify(interestingGedEgammaIsoHCALDetId,
minSCEt = 1.0, #default 20
minEleEt= 1.0, #default 20
minPhoEt= 1.0 #default 20
)
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,10 @@

gedPhotonSequence = cms.Sequence(gedPhotons)



from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(gedPhotons,
minSCEtBarrel = 1.0,
minSCEtEndcap = 1.0)
egamma_lowPt_exclusive.toModify(gedPhotonsTmp,
minSCEtBarrel = 1.0,
minSCEtEndcap = 1.0)
3 changes: 3 additions & 0 deletions RecoEgamma/EgammaPhotonProducers/python/photonCore_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,6 @@
scIslandEndcapProducer = "correctedIslandEndcapSuperClusters",
minSCEt = 8.0
)
from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(photonCore,minSCEt=0) #
egamma_lowPt_exclusive.toModify(islandPhotonCore,minSCEt = 1.0) #default 8
8 changes: 8 additions & 0 deletions RecoEgamma/EgammaPhotonProducers/python/photons_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,3 +150,11 @@
RecHitFlagToBeExcludedEE = multi5x5BasicClustersCleaned.RecHitFlagToBeExcluded,
RecHitSeverityToBeExcludedEE = cleanedHybridSuperClusters.RecHitSeverityToBeExcluded,
)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(photons,
minSCEtBarrel = 1.0, #default 10
minSCEtEndcap = 1.0) #default 10
egamma_lowPt_exclusive.toModify(islandPhotons,
minSCEtBarrel = 1.0, #default 5
minSCEtEndcap = 1.0) #default 15
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is not a part of the regular pp reco.
Why is this modified?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, we will not change the island Photon thresholds (updating it in the next commit).

6 changes: 6 additions & 0 deletions RecoParticleFlow/PFProducer/python/particleFlowBlock_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,3 +209,9 @@ def _findIndicesByModule(name):
particleFlowBlock,
elementImporters = _addTimingLayer
)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(particleFlowBlock.elementImporters[2],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please use _findIndicesByModule instead of direct indexing.
A less preferred solution would be to move this change up, to be right after the definition of particleFlowBlock, before all other modifiers are called

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you please suggest how exactly should I do it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

visually, it looks like replacing 2 with _findIndicesByModule("SuperClusterImporter")[0] should work,
perhaps more effective is to do

for imp in particleFlowBlock.elementImporters:
  if imp..importerName.value() == "SuperClusterImporter":
    _scImporter = imp
egamma_lowPt_exclusive.toModify(_scImporter, ...

minSuperClusterPt = 1.0,
minPTforBypass = 0.0)

2 changes: 2 additions & 0 deletions RecoParticleFlow/PFProducer/python/particleFlow_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -231,3 +231,5 @@
electron_protectionsForBadHcal = dict(enableProtections = True),
photon_protectionsForBadHcal = dict(enableProtections = True))

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(particleFlowTmp,photon_MinEt = 1.)
4 changes: 2 additions & 2 deletions RecoParticleFlow/PFTracking/python/pfTrackElec_cfi.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,5 +41,5 @@
pf_convBremFinderID_mvaWeightFileEndcapsHighPt = cms.FileInPath('RecoParticleFlow/PFTracking/data/TMVAClassification_ConvBremFinder_Testetgt20absetagt1_479_BDT.weights.xml')
)



from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(pfTrackElec,MinSCEnergy = 1.0)
Original file line number Diff line number Diff line change
Expand Up @@ -71,3 +71,5 @@
_fastSim_trackerDrivenElectronSeeds.idCollection = cms.VInputTag("trackerDrivenElectronSeedsTmp:preid",)
fastSim.toReplaceWith(trackerDrivenElectronSeeds,_fastSim_trackerDrivenElectronSeeds)

from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff import egamma_lowPt_exclusive
egamma_lowPt_exclusive.toModify(trackerDrivenElectronSeeds,MinPt = 1.0)