1 import FWCore.ParameterSet.Config
as cms
13 selectMuons = cms.EDProducer(
15 src = cms.InputTag(
"prunedGenParticles"),
23 selectStableMuons = genParticlesForJets.clone(src =
"selectMuons")
25 kinematicSelectedTauValDenominatorZMM = cms.EDFilter(
27 src = cms.InputTag(
'selectStableMuons'),
28 cut = kinematicSelectedTauValDenominatorCut,
29 filter = cms.bool(
False)
32 procAttributes =
dir(proc)
35 helpers.massSearchReplaceAnyInputTag(proc.TauValNumeratorAndDenominatorZMM,
'kinematicSelectedTauValDenominator',
'kinematicSelectedTauValDenominatorZMM')
39 zttModifier = ApplyFunctionToSequence(zttLabeler)
40 proc.TauValNumeratorAndDenominatorZMM.visit(zttModifier)
43 discs_to_retain = [
'ByDecayModeFinding',
'MuonRejection']
44 proc.RunHPSValidationZMM.discriminators = cms.VPSet([p
for p
in proc.RunHPSValidationZMM.discriminators
if any(disc
in p.discriminator.value()
for disc
in discs_to_retain) ])
47 proc.efficienciesZMM.plots = Utils.SetPlotSequence(proc.TauValNumeratorAndDenominatorZMM)
48 proc.efficienciesZMMSummary = cms.EDProducer(
"TauDQMHistEffProducer",
51 denominator = cms.string(
'RecoTauV/standardValidation/hpsPFTauProducerZMM_Summary/#PAR#PlotDen'),
52 efficiency = cms.string(
'RecoTauV/standardValidation/hpsPFTauProducerZMM_Summary/#PAR#Plot'),
53 numerator = cms.string(
'RecoTauV/standardValidation/hpsPFTauProducerZMM_Summary/#PAR#PlotNum'),
54 parameter = cms.vstring(
'summary'),
55 stepByStep = cms.bool(
True)
61 newProcAttributes = [x
for x
in dir(proc)
if (x
not in procAttributes)
and (x.find(
'ZMM') != -1)]
64 for newAttr
in newProcAttributes:
65 locals()[newAttr] = getattr(proc,newAttr)
67 produceDenominatorZMM = cms.Sequence(
69 +cms.ignore(selectStableMuons)
70 +cms.ignore(kinematicSelectedTauValDenominatorZMM)
73 produceDenominator = cms.Sequence(produceDenominatorZMM)
75 runTauValidationBatchMode = cms.Sequence(
77 +TauValNumeratorAndDenominatorZMM
80 runTauValidation = cms.Sequence(
81 runTauValidationBatchMode
def cloneProcessingSnippet(process, sequence, postfix, removePostfix="", noClones=[], addToTask=False, verbose=False)
bool any(const std::vector< T > &v, const T &what)
def SetValidationExtention(module, extension)