forked from cms-sw/cmssw
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Backport: add PF cluster validation to ECAL-only and HCAL-only sequen…
…ces (cms-sw#30636) Add PFCluster validation to ECAL-only and HCAL-only workflows.
- Loading branch information
Showing
5 changed files
with
125 additions
and
124 deletions.
There are no files selected for viewing
212 changes: 105 additions & 107 deletions
212
Validation/CaloTowers/test/CaloScan/template_2018_since_1010pre2.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,108 +1,106 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
import FWCore.ParameterSet.Config as cms | ||
|
||
from Configuration.Eras.Era_Run2_2018_cff import Run2_2018 | ||
process = cms.Process('TEST',Run2_2018) | ||
|
||
### RANDOM setting (change last digit(s) to make runs different !) | ||
process.load("Configuration.StandardSequences.SimulationRandomNumberGeneratorSeeds_cff") | ||
|
||
process.load("Configuration.StandardSequences.Simulation_cff") | ||
process.load("Configuration.StandardSequences.Reconstruction_cff") | ||
process.load("SimGeneral.MixingModule.mixNoPU_cfi") | ||
process.load('Configuration/StandardSequences/DigiToRaw_cff') | ||
process.load('Configuration/StandardSequences/RawToDigi_cff') | ||
|
||
process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") | ||
from Configuration.AlCa.autoCond import autoCond | ||
process.GlobalTag.globaltag = autoCond['phase1_2018_realistic'] | ||
|
||
process.load("IOMC.EventVertexGenerators.VtxSmearedGauss_cfi") | ||
process.load("Configuration.StandardSequences.GeometryDB_cff") | ||
process.load("Configuration.StandardSequences.MagneticField_cff") | ||
process.g4SimHits.UseMagneticField = False | ||
|
||
process.load("DQMServices.Core.DQMStore_cfi") | ||
process.load("DQMServices.Components.MEtoEDMConverter_cfi") | ||
|
||
process.maxEvents = cms.untracked.PSet( | ||
input = cms.untracked.int32(1000) | ||
) | ||
# Input source | ||
process.source = cms.Source("PoolSource", | ||
firstEvent = cms.untracked.uint32(XXXXX), | ||
fileNames = cms.untracked.vstring('file:mc.root') | ||
) | ||
|
||
process.FEVT = cms.OutputModule("PoolOutputModule", | ||
outputCommands = cms.untracked.vstring('drop *', 'keep *_MEtoEDMConverter_*_*'), | ||
splitLevel = cms.untracked.int32(0), | ||
fileName = cms.untracked.string("output.root") | ||
) | ||
|
||
process.VtxSmeared.SigmaX = 0.00001 | ||
process.VtxSmeared.SigmaY = 0.00001 | ||
process.VtxSmeared.SigmaZ = 0.00001 | ||
|
||
process.load("Validation.HcalHits.HcalSimHitsValidation_cfi") | ||
process.HcalSimHitsAnalyser.outputFile = cms.untracked.string('HcalSimHitsValidation.root') | ||
|
||
process.load("Validation.HcalDigis.HcalDigisParam_cfi") | ||
process.hcaldigisAnalyzer.outputFile = cms.untracked.string('HcalDigisValidationRelVal.root') | ||
|
||
process.load("Validation.HcalRecHits.HcalRecHitParam_cfi") | ||
|
||
process.load("Validation.CaloTowers.CaloTowersParam_cfi") | ||
process.calotowersAnalyzer.outputFile = cms.untracked.string('CaloTowersValidationRelVal.root') | ||
|
||
|
||
process.load("Validation.RecoParticleFlow.PFCluster_cfi") | ||
process.pfclusterAnalyzer.outputFile = cms.untracked.string('PFcluster.root') | ||
|
||
#------------- CUSTOMIZATION - replace hbhereco with hbheprereco | ||
delattr(process,"hbhereco") | ||
process.hbhereco = process.hbheprereco.clone() | ||
process.hcalLocalRecoSequence = cms.Sequence(process.hbhereco+process.hfprereco+process.hfreco+process.horeco) | ||
|
||
|
||
#---------- PATH | ||
# -- NB: for vertex smearing the Label should be: "unsmeared" | ||
# for GEN produced since 760pre6, for older GEN - just "": | ||
|
||
process.VtxSmeared.src = cms.InputTag("generator", "") | ||
process.generatorSmeared = cms.EDProducer("GeneratorSmearedProducer") | ||
process.g4SimHits.Generator.HepMCProductLabel = cms.InputTag('VtxSmeared') | ||
|
||
|
||
process.p = cms.Path( | ||
process.VtxSmeared * | ||
process.generatorSmeared * | ||
process.g4SimHits * | ||
process.mix * | ||
process.ecalDigiSequence * | ||
process.hcalDigiSequence * | ||
process.addPileupInfo * | ||
process.bunchSpacingProducer * | ||
process.ecalPacker * | ||
process.esDigiToRaw * | ||
process.hcalRawData * | ||
process.rawDataCollector * | ||
process.ecalDigis * | ||
process.ecalPreshowerDigis * | ||
process.hcalDigis * | ||
process.castorDigis * | ||
process.calolocalreco * | ||
process.caloTowersRec * | ||
process.hcalnoise * | ||
process.particleFlowCluster * | ||
# | ||
process.HcalSimHitsAnalyser * | ||
process.hcaldigisAnalyzer * | ||
process.calotowersAnalyzer * | ||
process.pfclusterAnalyzer * | ||
process.hcalRecoAnalyzer * | ||
# | ||
process.MEtoEDMConverter | ||
) | ||
|
||
process.outpath = cms.EndPath(process.FEVT) | ||
|
||
process = cms.Process('TEST',Run2_2018) | ||
|
||
### RANDOM setting (change last digit(s) to make runs different !) | ||
process.load("Configuration.StandardSequences.SimulationRandomNumberGeneratorSeeds_cff") | ||
|
||
process.load("Configuration.StandardSequences.Simulation_cff") | ||
process.load("Configuration.StandardSequences.Reconstruction_cff") | ||
process.load("SimGeneral.MixingModule.mixNoPU_cfi") | ||
process.load('Configuration/StandardSequences/DigiToRaw_cff') | ||
process.load('Configuration/StandardSequences/RawToDigi_cff') | ||
|
||
process.load("Configuration.StandardSequences.FrontierConditions_GlobalTag_cff") | ||
from Configuration.AlCa.autoCond import autoCond | ||
process.GlobalTag.globaltag = autoCond['phase1_2018_realistic'] | ||
|
||
process.load("IOMC.EventVertexGenerators.VtxSmearedGauss_cfi") | ||
process.load("Configuration.StandardSequences.GeometryDB_cff") | ||
process.load("Configuration.StandardSequences.MagneticField_cff") | ||
process.g4SimHits.UseMagneticField = False | ||
|
||
process.load("DQMServices.Core.DQMStore_cfi") | ||
process.load("DQMServices.Components.MEtoEDMConverter_cfi") | ||
|
||
process.maxEvents = cms.untracked.PSet( | ||
input = cms.untracked.int32(1000) | ||
) | ||
# Input source | ||
process.source = cms.Source("PoolSource", | ||
firstEvent = cms.untracked.uint32(XXXXX), | ||
fileNames = cms.untracked.vstring('file:mc.root') | ||
) | ||
|
||
process.FEVT = cms.OutputModule("PoolOutputModule", | ||
outputCommands = cms.untracked.vstring('drop *', 'keep *_MEtoEDMConverter_*_*'), | ||
splitLevel = cms.untracked.int32(0), | ||
fileName = cms.untracked.string("output.root") | ||
) | ||
|
||
process.VtxSmeared.SigmaX = 0.00001 | ||
process.VtxSmeared.SigmaY = 0.00001 | ||
process.VtxSmeared.SigmaZ = 0.00001 | ||
|
||
process.load("Validation.HcalHits.HcalSimHitsValidation_cfi") | ||
process.HcalSimHitsAnalyser.outputFile = cms.untracked.string('HcalSimHitsValidation.root') | ||
|
||
process.load("Validation.HcalDigis.HcalDigisParam_cfi") | ||
process.hcaldigisAnalyzer.outputFile = cms.untracked.string('HcalDigisValidationRelVal.root') | ||
|
||
process.load("Validation.HcalRecHits.HcalRecHitParam_cfi") | ||
|
||
process.load("Validation.CaloTowers.CaloTowersParam_cfi") | ||
process.calotowersAnalyzer.outputFile = cms.untracked.string('CaloTowersValidationRelVal.root') | ||
|
||
process.load("Validation.RecoParticleFlow.pfClusterValidation_cfi") | ||
|
||
#------------- CUSTOMIZATION - replace hbhereco with hbheprereco | ||
delattr(process,"hbhereco") | ||
process.hbhereco = process.hbheprereco.clone() | ||
process.hcalLocalRecoSequence = cms.Sequence(process.hbhereco+process.hfprereco+process.hfreco+process.horeco) | ||
|
||
|
||
#---------- PATH | ||
# -- NB: for vertex smearing the Label should be: "unsmeared" | ||
# for GEN produced since 760pre6, for older GEN - just "": | ||
|
||
process.VtxSmeared.src = cms.InputTag("generator", "") | ||
process.generatorSmeared = cms.EDProducer("GeneratorSmearedProducer") | ||
process.g4SimHits.Generator.HepMCProductLabel = cms.InputTag('VtxSmeared') | ||
|
||
|
||
process.p = cms.Path( | ||
process.VtxSmeared * | ||
process.generatorSmeared * | ||
process.g4SimHits * | ||
process.mix * | ||
process.ecalDigiSequence * | ||
process.hcalDigiSequence * | ||
process.addPileupInfo * | ||
process.bunchSpacingProducer * | ||
process.ecalPacker * | ||
process.esDigiToRaw * | ||
process.hcalRawData * | ||
process.rawDataCollector * | ||
process.ecalDigis * | ||
process.ecalPreshowerDigis * | ||
process.hcalDigis * | ||
process.castorDigis * | ||
process.calolocalreco * | ||
process.caloTowersRec * | ||
process.hcalnoise * | ||
process.particleFlowCluster * | ||
# | ||
process.HcalSimHitsAnalyser * | ||
process.hcaldigisAnalyzer * | ||
process.calotowersAnalyzer * | ||
process.pfClusterValidation * | ||
process.hcalRecoAnalyzer * | ||
# | ||
process.MEtoEDMConverter | ||
) | ||
|
||
process.outpath = cms.EndPath(process.FEVT) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 8 additions & 2 deletions
10
Validation/RecoParticleFlow/python/PFClusterValidation_cff.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,10 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
from Validation.RecoParticleFlow.PFCluster_cfi import pfclusterAnalyzer | ||
from Validation.RecoParticleFlow.pfClusterValidation_cfi import pfClusterValidation | ||
|
||
pfClusterValidationSequence = cms.Sequence( pfclusterAnalyzer ) | ||
pfClusterValidationSequence = cms.Sequence( pfClusterValidation ) | ||
|
||
pfClusterCaloOnlyValidation = pfClusterValidation.clone( | ||
pflowClusterHCAL = 'particleFlowClusterHCALOnly', | ||
) | ||
|
||
pfClusterCaloOnlyValidationSequence = cms.Sequence( pfClusterCaloOnlyValidation ) |
This file was deleted.
Oops, something went wrong.
10 changes: 10 additions & 0 deletions
10
Validation/RecoParticleFlow/python/pfClusterValidation_cfi.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
from DQMServices.Core.DQMEDAnalyzer import DQMEDAnalyzer | ||
|
||
pfClusterValidation = DQMEDAnalyzer('PFClusterValidation', | ||
pflowClusterECAL = cms.untracked.InputTag('particleFlowClusterECAL'), | ||
pflowClusterHCAL = cms.untracked.InputTag('particleFlowClusterHCAL'), | ||
pflowClusterHO = cms.untracked.InputTag('particleFlowClusterHO'), | ||
pflowClusterHF = cms.untracked.InputTag('particleFlowClusterHF'), | ||
) |