Ejemplo n.º 1
0
def miniAOD_customizeHeavyIon(process, data):
    from PhysicsTools.PatAlgos.producersHeavyIons.heavyIonJetSetup import aliasFlowPuCsJets, removeL1FastJetJECs, removeJECsForMC, addJECsForData
    from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
    pp_on_AA_2018.toModify(process.slimmedJets, src='selectedPatJets')
    pp_on_AA_2018.toModify(process,
                           func=lambda proc: removeL1FastJetJECs(proc))
    pp_on_AA_2018.toModify(
        process, func=lambda proc: aliasFlowPuCsJets(proc, 'akFlowPuCs4PF'))

    modifyJECs = addJECsForData if data is True else removeJECsForMC
    pp_on_AA_2018.toModify(process, func=lambda proc: modifyJECs(proc))
    r2MaxF = cms.double(0.15), ## forward
    rMinI = cms.double(-0.2), ## intermediate region SC in EB and 2nd hits in PXF
    rMaxI = cms.double(0.2), ## intermediate region SC in EB and 2nd hits in PXF

    # phi windows (dynamic)
    LowPtThreshold = cms.double(5.0),
    HighPtThreshold = cms.double(35.0),
    SizeWindowENeg = cms.double(0.675),
    DeltaPhi1Low = cms.double(0.23),
    DeltaPhi1High = cms.double(0.08),
#    DeltaPhi2 = cms.double(0.008),
    DeltaPhi2B = cms.double(0.008), ## barrel
    DeltaPhi2F = cms.double(0.012), ## forward

    # phi windows (non dynamic, overwritten in case dynamic is selected)
    ePhiMin1 = cms.double(-0.125),
    ePhiMax1 = cms.double(0.075),
    pPhiMin1 = cms.double(-0.075),
    pPhiMax1 = cms.double(0.125),
#    PhiMin2 = cms.double(-0.002),
#    PhiMax2 = cms.double(0.002),
    PhiMin2B = cms.double(-0.002), ## barrel
    PhiMax2B = cms.double(0.002), ## barrel
    PhiMin2F = cms.double(-0.003), ## forward
    PhiMax2F = cms.double(0.003), ## forward
    
)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(ecalDrivenElectronSeedsParameters, SCEtCut = 15.0)
Ejemplo n.º 3
0
trackingPhase1.toReplaceWith(
    tobTecStep,
    tobTecStepClassifier1.clone(
        mva=dict(GBRForestLabel='MVASelectorTobTecStep_Phase1'),
        qualityCuts=[-0.6, -0.45, -0.3]))

from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(
    tobTecStep,
    TrackLwtnnClassifier.clone(src='tobTecStepTracks',
                               qualityCuts=[-0.4, -0.25, -0.1]))
(trackdnn & fastSim).toModify(tobTecStep,
                              vertices="firstStepPrimaryVerticesBeforeMixing")

pp_on_AA_2018.toModify(tobTecStep, qualityCuts=[-0.6, -0.3, 0.7])

import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
trackingLowPU.toReplaceWith(
    tobTecStep,
    RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.
    clone(
        src='tobTecStepTracks',
        useAnyMVA=cms.bool(False),
        GBRForestLabel=cms.string('MVASelectorIter6'),
        trackSelectors=[
            RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.
            clone(name='tobTecStepLoose',
                  chi2n_par=0.4,
                  res_par=(0.003, 0.001),
                  minNumberLayers=5,
Ejemplo n.º 4
0
   # Iso Values 
   useIsolationValues = cms.bool(False),
  SoftElecMVAFilesString = cms.vstring(
    "RecoEgamma/ElectronIdentification/data/TMVA_BDTSoftElectrons_9Dec2013.weights.xml"
                                ), 
  ElecMVAFilesString = cms.vstring(
        "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_10_17Feb2011.weights.xml",
     "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_12_17Feb2011.weights.xml",
     "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_20_17Feb2011.weights.xml",
     "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_22_17Feb2011.weights.xml"
                                 ),

)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(ecalDrivenGsfElectrons, minSCEtBarrel = 15.0)
pp_on_AA_2018.toModify(ecalDrivenGsfElectrons, minSCEtEndcaps = 15.0)

#==============================================================================
# Final producer of persistent gsf electrons
#==============================================================================

gsfElectrons = cms.EDProducer("GsfElectronProducer",

    # input collections
    previousGsfElectronsTag = cms.InputTag("ecalDrivenGsfElectrons"),
    pflowGsfElectronsTag = cms.InputTag("pfElectronTranslator:pf"),
    gsfElectronCoresTag = cms.InputTag("gsfElectronCores"),
    hcalTowers = cms.InputTag("towerMaker"),
    checkHcalStatus = cms.bool(True),
    barrelRecHitCollectionTag = cms.InputTag("ecalRecHit","EcalRecHitsEB"),
Ejemplo n.º 5
0
import FWCore.ParameterSet.Config as cms

reducedHcalRecHits = cms.EDProducer(
    "HcalHitSelection",
    hbheTag=cms.InputTag('hbhereco'),
    hfTag=cms.InputTag('hfreco'),
    hoTag=cms.InputTag('horeco'),
    hoSeverityLevel=cms.int32(13),
    interestingDetIds=cms.VInputTag(
        cms.InputTag("interestingGedEgammaIsoHCALDetId"),
        cms.InputTag("interestingOotEgammaIsoHCALDetId"),
    ))

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018

pp_on_AA_2018.toModify(reducedHcalRecHits.interestingDetIds,
                       func=lambda list: list.remove(
                           cms.InputTag("interestingOotEgammaIsoHCALDetId")))
Ejemplo n.º 6
0
   # regression. The labels are needed in all cases
   ecalRefinedRegressionWeightLabels = cms.vstring('gedelectron_EBCorrection_offline_v1',
                                                   'gedelectron_EECorrection_offline_v1',
                                                   'gedelectron_EBUncertainty_offline_v1',
                                                   'gedelectron_EEUncertainty_offline_v1'),
   combinationRegressionWeightLabels = cms.vstring('gedelectron_p4combination_offline'),
   
   ecalWeightsFromDB = cms.bool(True),
   # if not from DB. Otherwise, keep empty
   ecalRefinedRegressionWeightFiles = cms.vstring(),
   combinationWeightsFromDB = cms.bool(True),
   # if not from DB. Otherwise, keep empty
   combinationRegressionWeightFile = cms.vstring(),                              
 
   # Iso Values 
   useIsolationValues = cms.bool(False),
 SoftElecMVAFilesString = cms.vstring(
    "RecoEgamma/ElectronIdentification/data/TMVA_BDTSoftElectrons_7Feb2014.weights.xml"
                                ),
 ElecMVAFilesString = cms.vstring(
     "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_10_17Feb2011.weights.xml",
     "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_12_17Feb2011.weights.xml",
     "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_20_17Feb2011.weights.xml",
     "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_22_17Feb2011.weights.xml"
                                 ),
)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(gedGsfElectronsTmp, minSCEtBarrel = 15.0)
pp_on_AA_2018.toModify(gedGsfElectronsTmp, minSCEtEndcaps = 15.0)
Ejemplo n.º 7
0
    RecHitSeverityToBeExcluded,
    recHitSeverityToBeExcludedEndcaps=cleanedHybridSuperClusters.
    RecHitSeverityToBeExcluded,

    # Isolation algos configuration
    trkIsol03Cfg=trkIsol03CfgV1,
    trkIsol04Cfg=trkIsol04CfgV1,
    trkIsolHEEP03Cfg=trkIsol03CfgV2,
    trkIsolHEEP04Cfg=trkIsol04CfgV2,

    # regression. The labels are needed in all cases.
    ecalRefinedRegressionWeightLabels=cms.vstring(),
    #"gedelectron_EBCorrection_offline_v1"
    #"gedelectron_EECorrection_offline_v1"
    #"gedelectron_EBUncertainty_offline_v1"
    #"gedelectron_EEUncertainty_offline_v1"
    combinationRegressionWeightLabels=cms.vstring(),
    #"gedelectron_p4combination_offline"

    # Iso values
    useIsolationValues=cms.bool(False),
)

from Configuration.Eras.Modifier_fastSim_cff import fastSim
fastSim.toModify(lowPtGsfElectrons,
                 ctfTracksTag=cms.InputTag("generalTracksBeforeMixing"))

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(lowPtGsfElectrons.preselection, minSCEtBarrel=15.0)
pp_on_AA_2018.toModify(lowPtGsfElectrons.preselection, minSCEtEndcaps=15.0)
Ejemplo n.º 8
0
)
fastSim.toModify(lowPtQuadStepTracks, TTRHBuilder='WithoutRefit')

# Final selection
from RecoTracker.FinalTrackSelectors.TrackMVAClassifierPrompt_cfi import *
lowPtQuadStep = TrackMVAClassifierPrompt.clone(
    src='lowPtQuadStepTracks',
    mva=dict(GBRForestLabel='MVASelectorLowPtQuadStep_Phase1'),
    qualityCuts=[-0.7, -0.35, -0.15],
)
fastSim.toModify(lowPtQuadStep,
                 vertices="firstStepPrimaryVerticesBeforeMixing")
highBetaStar_2018.toModify(lowPtQuadStep, qualityCuts=[-0.9, -0.35, -0.15])
pp_on_AA_2018.toModify(
    lowPtQuadStep,
    mva=dict(GBRForestLabel='HIMVASelectorLowPtQuadStep_Phase1'),
    qualityCuts=[-0.9, -0.4, 0.3],
)

# For Phase2PU140
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
lowPtQuadStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='lowPtQuadStepTracks',
    trackSelectors=[
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name='lowPtQuadStepLoose',
            chi2n_par=2.0,
            res_par=(0.003, 0.002),
            minNumberLayers=3,
            maxNumberLostLayers=2,
            minNumber3DLayers=3,
Ejemplo n.º 9
0
			   *ElecMuonDQM
                           *susyDQM
                           *HiggsDQM
                           *ExoticaDQM
                           *B2GDQM
                           *FSQDQM
                           )

from Configuration.Eras.Modifier_phase1Pixel_cff import phase1Pixel
phase1Pixel.toReplaceWith(dqmPhysics, dqmPhysics.copyAndExclude([ # FIXME
    ewkMuDQM,            # Excessive printouts because 2017 doesn't have HLT yet
    ewkElecDQM,          # Excessive printouts because 2017 doesn't have HLT yet
    ewkMuLumiMonitorDQM, # Excessive printouts because 2017 doesn't have HLT yet
]))
from Configuration.Eras.Modifier_pA_2016_cff import pA_2016
dqmPhysicspA  =  dqmPhysics.copy()
dqmPhysicspA += CentralitypADQM
pA_2016.toReplaceWith(dqmPhysics, dqmPhysicspA)
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
_dqmPhysics  =  dqmPhysics.copy()
_dqmPhysics += CentralityDQM
pp_on_AA_2018.toModify(CentralityDQM, vertexcollection=cms.InputTag("offlinePrimaryVertices"))
pp_on_AA_2018.toReplaceWith(dqmPhysics, _dqmPhysics)

bphysicsOniaDQMHI = bphysicsOniaDQM.clone(vertex=cms.InputTag("hiSelectedVertex"))
dqmPhysicsHI = cms.Sequence(bphysicsOniaDQMHI+CentralityDQM)

from DQM.Physics.qcdPhotonsCosmicDQM_cff import *
dqmPhysicsCosmics = cms.Sequence(dqmPhysics)
dqmPhysicsCosmics.replace(qcdPhotonsDQM, qcdPhotonsCosmicDQM)
Ejemplo n.º 10
0
import FWCore.ParameterSet.Config as cms

##____________________________________________________________________________||
from RecoMET.METProducers.PFMET_cfi import *
from RecoMET.METProducers.pfChMet_cfi import *

##____________________________________________________________________________||
recoPFMET = cms.Sequence(pfMet + particleFlowForChargedMET + pfChMet)

##____________________________________________________________________________||
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(pfMet,  globalThreshold = 999.)
pp_on_AA_2018.toModify(pfChMet, globalThreshold = 999.)
Ejemplo n.º 11
0
import FWCore.ParameterSet.Config as cms

reducedHcalRecHits = cms.EDProducer("HcalHitSelection",
                                    hbheTag = cms.InputTag('hbhereco'),
                                    hfTag = cms.InputTag('hfreco'),
                                    hoTag = cms.InputTag('horeco'),
                                    hoSeverityLevel = cms.int32(13),
                                    interestingDetIds = cms.VInputTag(
                                         cms.InputTag("interestingGedEgammaIsoHCALDetId"),
                                         cms.InputTag("interestingOotEgammaIsoHCALDetId"),
                                         )
                                    )

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(reducedHcalRecHits.interestingDetIds, func = lambda list: list.remove(cms.InputTag("interestingOotEgammaIsoHCALDetId")) )
Ejemplo n.º 12
0
# if read_Ascii_LUTs is true then read Ascii LUTs via "inputLUTs" below

import FWCore.ParameterSet.Config as cms

from Configuration.Eras.Modifier_run2_HCAL_2018_cff import run2_HCAL_2018
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018

from SimCalorimetry.HcalTrigPrimProducers.hcaltpdigi_cfi import *
from CalibCalorimetry.CaloTPG.CaloTPGTranscoder_cfi import *
HcalTPGCoderULUT = cms.ESProducer("HcalTPGCoderULUT",
    read_Ascii_LUTs = cms.bool(False),
    read_XML_LUTs = cms.bool(False),
    read_FG_LUTs = cms.bool(False),
    LUTGenerationMode = cms.bool(True),
    linearLUTs = cms.bool(False),
    tpScales = tpScales,
    MaskBit = cms.int32(0x8000),
    FG_HF_thresholds = cms.vuint32(17, 255),
    inputLUTs = cms.FileInPath('CalibCalorimetry/HcalTPGAlgos/data/inputLUTcoder_physics.dat'),
    FGLUTs = cms.FileInPath('CalibCalorimetry/HcalTPGAlgos/data/HBHE_FG_LUT.dat'),
    RCalibFile = cms.FileInPath('CalibCalorimetry/HcalTPGAlgos/data/RecHit-TPG-calib.dat')
)

HcalTrigTowerGeometryESProducer = cms.ESProducer("HcalTrigTowerGeometryESProducer")

run2_HCAL_2018.toModify(CaloTPGTranscoder, linearLUTs=cms.bool(True))
run2_HCAL_2018.toModify(HcalTPGCoderULUT, linearLUTs=cms.bool(True))
pp_on_AA_2018.toModify(CaloTPGTranscoder, FG_HF_thresholds = cms.vuint32(15, 19))
pp_on_AA_2018.toModify(HcalTPGCoderULUT, FG_HF_thresholds = cms.vuint32(15, 19))
Ejemplo n.º 13
0
doLayersVsPhiVsEtaPerTrack          ['hiConformalPixelTracksQA'] = cms.bool(True)
doGoodTrackLayersVsPhiVsEtaPerTrack ['hiConformalPixelTracksQA'] = cms.bool(False)
doPUmonitoring                      ['hiConformalPixelTracksQA'] = cms.bool(True)
doPlotsVsBXlumi                     ['hiConformalPixelTracksQA'] = cms.bool(False)
doPlotsVsGoodPVtx                   ['hiConformalPixelTracksQA'] = cms.bool(True)
doEffFromHitPatternVsPU             ['hiConformalPixelTracksQA'] = cms.bool(False)
doEffFromHitPatternVsBX             ['hiConformalPixelTracksQA'] = cms.bool(False)
doEffFromHitPatternVsLumi           ['hiConformalPixelTracksQA'] = cms.bool(False)
doStopSource                        ['hiConformalPixelTracksQA'] = cms.bool(True)

selectedTracks.extend( ['generalTracks'] )
#selectedTracks.extend( ['highPurityPtRange0to1']  )
#selectedTracks.extend( ['highPurityPtRange1to10'] )
#selectedTracks.extend( ['highPurityPt10']         )

selectedTracks.extend( ['highPurityPt1'] )
selectedTracks.extend( ['highPurityPtRange0to1'] )
selectedTracks.extend( ['highPurityPV0p1'] )

# not by default
#selectedTracks.extend( ['highPurityPt1Eta2p5to3p0'] )


#selectedTracks2runSequence=cms.Sequence()
#for tracks in selectedTracks :
#    if tracks != 'generalTracks':
#        selectedTracks2runSequence+=sequenceName[tracks]

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(selectedTracks, func=lambda selectedTracks: selectedTracks.extend( ['hiConformalPixelTracksQA'] ))
Ejemplo n.º 14
0
        'BPix1+FPix1_pos', 'BPix1+FPix1_neg', 
        'BPix1+FPix2_pos', 'BPix1+FPix2_neg', 
        'BPix2+FPix1_pos', 'BPix2+FPix1_neg', 
        'FPix1_pos+FPix2_pos', 'FPix1_neg+FPix2_neg',
        'FPix1_pos+FPix3_pos', 'FPix1_neg+FPix3_neg',
        'FPix2_pos+FPix3_pos', 'FPix2_neg+FPix3_neg' 
    ]
trackingPhase1.toModify(pixelPairElectronSeedLayers, layerList = _layerListForPhase1)

from RecoTracker.TkTrackingRegions.globalTrackingRegionWithVertices_cff import globalTrackingRegionWithVertices as _globalTrackingRegionWithVertices
pixelPairElectronTrackingRegions = _globalTrackingRegionWithVertices.clone(RegionPSet = dict(
    ptMin = 1.0,
    originRadius = 0.015,
    fixedError = 0.03,
))
pp_on_AA_2018.toModify(pixelPairElectronTrackingRegions, RegionPSet = dict(ptMin = 8.0))
from RecoTracker.TkHitPairs.hitPairEDProducer_cfi import hitPairEDProducer as _hitPairEDProducer
pixelPairElectronHitDoublets = _hitPairEDProducer.clone(
    seedingLayers = "pixelPairElectronSeedLayers",
    trackingRegions = "pixelPairElectronTrackingRegions",
    maxElement = 1000000,
    produceSeedingHitSets = True,
)
from RecoTracker.TkSeedGenerator.seedCreatorFromRegionConsecutiveHitsEDProducer_cff import seedCreatorFromRegionConsecutiveHitsEDProducer as _seedCreatorFromRegionConsecutiveHitsEDProducer
pixelPairElectronSeeds = _seedCreatorFromRegionConsecutiveHitsEDProducer.clone(
    seedingHitSets = "pixelPairElectronHitDoublets",
)

stripPairElectronSeedLayers = cms.EDProducer("SeedingLayersEDProducer",
    layerList = cms.vstring('TIB1+TIB2', 'TIB1+TID1_pos', 'TIB1+TID1_neg', 'TID2_pos+TID3_pos', 'TID2_neg+TID3_neg',
                            'TEC1_pos+TEC2_pos','TEC2_pos+TEC3_pos','TEC3_pos+TEC4_pos','TEC3_pos+TEC5_pos',
    phiwidth_SuperClusterBarrel = cms.double(0.6),
    etawidth_SuperClusterBarrel = cms.double(0.04),

    phiwidth_SuperClusterEndcap = cms.double(0.6),
    etawidth_SuperClusterEndcap = cms.double(0.04),

    # threshold in preshower
    thresh_PFClusterES = cms.double(0.),           

    # turn on merging of the seed cluster to its nearest neighbors
    # that share a rechit
    doSatelliteClusterMerge = cms.bool(False),
    satelliteClusterSeedThreshold = cms.double(50.0),
    satelliteMajorityFraction = cms.double(0.5),
    dropUnseedable = cms.bool(False),
    #thresh_PFClusterMustacheOutBarrel = cms.double(0.),
    #thresh_PFClusterMustacheOutEndcap = cms.double(0.), 

    #corrections
    applyCrackCorrections = cms.bool(False)
                                              
)

#define the default clustering type
particleFlowSuperClusterECAL = particleFlowSuperClusterECALMustache.clone()

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
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)
Ejemplo n.º 16
0
        'keep Phase2TrackerDigiedmDetSetVector_mix_*_*',
        'keep *_TTClustersFromPhase2TrackerDigis_*_*',
        'keep *_TTStubsFromPhase2TrackerDigis_*_*', 'keep *_TrackerDTC_*_*',
        'keep *_*_Level1TTTracks_*'
    ])
phase2_muon.toModify(FEVTEventContent,
                     outputCommands=FEVTEventContent.outputCommands +
                     ['keep *_muonGEMDigis_*_*'])
run2_GEM_2017.toModify(FEVTEventContent,
                       outputCommands=FEVTEventContent.outputCommands +
                       ['keep *_muonGEMDigis_*_*'])
run3_GEM.toModify(FEVTEventContent,
                  outputCommands=FEVTEventContent.outputCommands +
                  ['keep *_muonGEMDigis_*_*'])
pp_on_AA_2018.toModify(FEVTEventContent,
                       outputCommands=FEVTEventContent.outputCommands +
                       ['keep FEDRawDataCollection_rawDataRepacker_*_*'])
phase2_timing_layer.toModify(FEVTEventContent,
                             outputCommands=FEVTEventContent.outputCommands +
                             RecoLocalFastTimeFEVT.outputCommands)
phase2_timing_layer.toModify(FEVTEventContent,
                             outputCommands=FEVTEventContent.outputCommands +
                             RecoMTDFEVT.outputCommands)

FEVTHLTALLEventContent = cms.PSet(
    outputCommands=cms.untracked.vstring('drop *'),
    splitLevel=cms.untracked.int32(0),
)
FEVTHLTALLEventContent.outputCommands.extend(FEVTEventContent.outputCommands)
FEVTHLTALLEventContent.outputCommands.append('keep *_*_*_HLT')
#
Ejemplo n.º 17
0
# Final selection
from RecoTracker.FinalTrackSelectors.TrackMVAClassifierPrompt_cfi import *
lowPtTripletStep =  TrackMVAClassifierPrompt.clone()
lowPtTripletStep.src = 'lowPtTripletStepTracks'
lowPtTripletStep.mva.GBRForestLabel = 'MVASelectorIter1_13TeV'
lowPtTripletStep.qualityCuts = [-0.6,-0.3,-0.1]

trackingPhase1.toReplaceWith(lowPtTripletStep, lowPtTripletStep.clone(
     mva = dict(GBRForestLabel = 'MVASelectorLowPtTripletStep_Phase1'),
     qualityCuts = [-0.4,0.0,0.3],
))
highBetaStar_2018.toModify(lowPtTripletStep,qualityCuts = [-0.7,-0.3,-0.1])
fastSim.toModify(lowPtTripletStep, vertices = "firstStepPrimaryVerticesBeforeMixing")
pp_on_AA_2018.toModify(lowPtTripletStep, 
        mva = dict(GBRForestLabel = 'HIMVASelectorLowPtTripletStep_Phase1'),
        qualityCuts = [-0.8, -0.4, 0.5],
)


# For LowPU and Phase2PU140
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
lowPtTripletStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src = 'lowPtTripletStepTracks',
    useAnyMVA = cms.bool(False),
    GBRForestLabel = cms.string('MVASelectorIter1'),
    trackSelectors= [
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name = 'lowPtTripletStepLoose',
        ), #end of pset
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
            name = 'lowPtTripletStepTight',
Ejemplo n.º 18
0
for _entry in [FEVTDEBUGEventContent,FEVTDEBUGHLTEventContent,FEVTEventContent]:
    phase2_tracker.toModify(_entry, outputCommands = _entry.outputCommands + [
        'keep Phase2TrackerDigiedmDetSetVector_mix_*_*',
        'keep *_TTClustersFromPhase2TrackerDigis_*_*',
        'keep *_TTStubsFromPhase2TrackerDigis_*_*'
    ])

from Configuration.Eras.Modifier_run2_GEM_2017_cff import run2_GEM_2017
from Configuration.Eras.Modifier_run3_GEM_cff import run3_GEM
from Configuration.Eras.Modifier_phase2_muon_cff import phase2_muon
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
for _entry in [FEVTDEBUGEventContent,FEVTDEBUGHLTEventContent,FEVTEventContent]:
    run2_GEM_2017.toModify(_entry, outputCommands = _entry.outputCommands + ['keep *_muonGEMDigis_*_*'])
    run3_GEM.toModify(_entry, outputCommands = _entry.outputCommands + ['keep *_muonGEMDigis_*_*'])
    phase2_muon.toModify(_entry, outputCommands = _entry.outputCommands + ['keep *_muonGEMDigis_*_*'])
    pp_on_AA_2018.toModify(_entry, outputCommands = _entry.outputCommands + ['keep FEDRawDataCollection_rawDataRepacker_*_*'])

from RecoLocalFastTime.Configuration.RecoLocalFastTime_EventContent_cff import RecoLocalFastTimeFEVT, RecoLocalFastTimeRECO, RecoLocalFastTimeAOD
from Configuration.Eras.Modifier_phase2_timing_layer_cff import phase2_timing_layer
def _addOutputCommands(mod, newCommands):
    phase2_timing_layer.toModify(mod, outputCommands = mod.outputCommands + newCommands.outputCommands)

_addOutputCommands(FEVTDEBUGEventContent,RecoLocalFastTimeFEVT)
_addOutputCommands(FEVTDEBUGHLTEventContent,RecoLocalFastTimeFEVT)
_addOutputCommands(FEVTEventContent,RecoLocalFastTimeFEVT)
_addOutputCommands(RECOSIMEventContent,RecoLocalFastTimeRECO)
_addOutputCommands(AODSIMEventContent,RecoLocalFastTimeAOD)

from RecoMTD.Configuration.RecoMTD_EventContent_cff import RecoMTDFEVT, RecoMTDRECO, RecoMTDAOD
_addOutputCommands(FEVTDEBUGEventContent,RecoMTDFEVT)
_addOutputCommands(FEVTDEBUGHLTEventContent,RecoMTDFEVT)
Ejemplo n.º 19
0
trackingPhase1.toReplaceWith(mixedTripletStep, mixedTripletStepClassifier1.clone(
	mva = dict(GBRForestLabel = 'MVASelectorMixedTripletStep_Phase1'),
	qualityCuts = [-0.5,0.0,0.5]
))

from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(mixedTripletStep, TrackLwtnnClassifier.clone(
     src = 'mixedTripletStepTracks',
     qualityCuts = [-0.8, -0.35, 0.1]
))
(trackdnn & fastSim).toModify(mixedTripletStep,vertices = "firstStepPrimaryVerticesBeforeMixing")

highBetaStar_2018.toModify(mixedTripletStep,qualityCuts = [-0.7,0.0,0.5])
pp_on_AA_2018.toModify(mixedTripletStep, qualityCuts = [-0.5,0.0,0.9])

# For LowPU
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
mixedTripletStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src = 'mixedTripletStepTracks',
    useAnyMVA = cms.bool(False),
    GBRForestLabel = cms.string('MVASelectorIter4'),
    trackSelectors = [
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name = 'mixedTripletStepVtxLoose',
            chi2n_par = 1.2,
            res_par = ( 0.003, 0.001 ),
            minNumberLayers = 3,
            maxNumberLostLayers = 1,
            minNumber3DLayers = 2,
Ejemplo n.º 20
0
    src='highPtTripletStepTracks',
    qualityCuts=[0.2, 0.3, 0.4])

from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(
    highPtTripletStep,
    TrackLwtnnClassifier.clone(
        src='highPtTripletStepTracks',
        qualityCuts=[0.75, 0.775, 0.8],
    ))

highBetaStar_2018.toModify(highPtTripletStep, qualityCuts=[-0.2, 0.3, 0.4])
pp_on_AA_2018.toModify(
    highPtTripletStep,
    mva=dict(GBRForestLabel='HIMVASelectorHighPtTripletStep_Phase1'),
    qualityCuts=[-0.9, -0.3, 0.85],
)

fastSim.toModify(highPtTripletStep,
                 vertices='firstStepPrimaryVerticesBeforeMixing')

# For Phase2PU140
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
highPtTripletStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='highPtTripletStepTracks',
    trackSelectors=[
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name='highPtTripletStepLoose',
            chi2n_par=2.0,
            res_par=(0.003, 0.002),
Ejemplo n.º 21
0
        ),
    photonFloatValueMapOutput = cms.vstring(
        "phoEcalPFClusIso",
        "phoHcalPFClusIso",
        ),
    ootPhotonFloatValueMapSources = cms.VInputTag(
        cms.InputTag("ootPhotonEcalPFClusterIsolationProducer"),
        cms.InputTag("ootPhotonHcalPFClusterIsolationProducer"),
        ),
    ootPhotonFloatValueMapOutput = cms.vstring(
        "ootPhoEcalPFClusIso",
        "ootPhoHcalPFClusIso",
        ),
    gsfElectronFloatValueMapSources = cms.VInputTag(
        cms.InputTag("electronEcalPFClusterIsolationProducer"),
        cms.InputTag("electronHcalPFClusterIsolationProducer"),
        ),
    gsfElectronFloatValueMapOutput = cms.vstring(
        "eleEcalPFClusIso",
        "eleHcalPFClusIso",
        )
    )

from RecoEgamma.EgammaPhotonProducers.reducedEgamma_tools import calibrateReducedEgamma
from Configuration.Eras.Modifier_run2_miniAOD_94XFall17_cff import run2_miniAOD_94XFall17
modifyReducedEGammaRun2MiniAOD9XFall17_ = run2_miniAOD_94XFall17.makeProcessModifier(calibrateReducedEgamma)
from Configuration.Eras.Modifier_run2_miniAOD_80XLegacy_cff import run2_miniAOD_80XLegacy
modifyReducedEGammaRun2MiniAOD8XLegacy_ = run2_miniAOD_80XLegacy.makeProcessModifier(calibrateReducedEgamma)
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify( reducedEgamma, ootPhotons = cms.InputTag("") )
Ejemplo n.º 22
0
    
    # calo muons
    minCaloCompatibility = cms.double(0.6),

    # arbitration cleaning                       
    runArbitrationCleaner = cms.bool(True),
    arbitrationCleanerOptions = cms.PSet( ME1a = cms.bool(True),
                                          Overlap = cms.bool(True),
                                          Clustering = cms.bool(True),
                                          OverlapDPhi   = cms.double(0.0786), # 4.5 degrees
                                          OverlapDTheta = cms.double(0.02), # 1.14 degrees
                                          ClusterDPhi   = cms.double(0.6), # 34 degrees
                                          ClusterDTheta = cms.double(0.02) # 1.14
    ),

    # tracker muon arbitration
    arbitrateTrackerMuons = cms.bool(True)
)

from Configuration.Eras.Modifier_run3_GEM_cff import run3_GEM
run3_GEM.toModify( muons1stStep, TrackAssociatorParameters = dict(useGEM = cms.bool(True) ) )
from Configuration.Eras.Modifier_phase2_muon_cff import phase2_muon
phase2_muon.toModify( muons1stStep, TrackAssociatorParameters = dict(useME0 = cms.bool(True) ) )

muonEcalDetIds = cms.EDProducer("InterestingEcalDetIdProducer",
                                inputCollection = cms.InputTag("muons1stStep")
)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(muons1stStep, minPt = 0.8)
Ejemplo n.º 23
0
from CalibMuon.DTCalibration.DTCalibMuonSelection_cfi import *

# AlCaReco for DT calibration
ALCARECODtCalibHLTFilter = copy.deepcopy(hltHighLevel)
#ALCARECODtCalibHLTFilter.andOr = True ## choose logical OR between Triggerbits
#ALCARECODtCalibHLTFilter.HLTPaths = ['HLT_L1MuOpen*', 'HLT_L1Mu*']
ALCARECODtCalibHLTFilter.throw = False ## dont throw on unknown path names
ALCARECODtCalibHLTFilter.eventSetupPathsKey = 'DtCalib'

import RecoLocalMuon.DTSegment.dt4DSegments_CombPatternReco4D_LinearDriftFromDB_cfi as dt4DSegmentsCfiRef
dt4DSegmentsNoWire = dt4DSegmentsCfiRef.dt4DSegments.clone()
dt4DSegmentsNoWire.Reco4DAlgoConfig.recAlgoConfig.tTrigModeConfig.doWirePropCorrection = False
dt4DSegmentsNoWire.Reco4DAlgoConfig.Reco2DAlgoConfig.recAlgoConfig.tTrigModeConfig.doWirePropCorrection = False

#this is to select collisions
from RecoMET.METFilters.metFilters_cff import primaryVertexFilter, noscraping

seqALCARECODtCalib = cms.Sequence(primaryVertexFilter * noscraping * ALCARECODtCalibHLTFilter * DTCalibMuonSelection * dt4DSegmentsNoWire) 

## customizations for the pp_on_AA_2018 eras
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(ALCARECODtCalibHLTFilter,
                       eventSetupPathsKey='DtCalibHI'
)

seqALCARECODtCalibHI = cms.Sequence(ALCARECODtCalibHLTFilter * dt4DSegmentsNoWire)

#Specify to use HI sequence for the pp_on_AA_2018 eras
pp_on_AA_2018.toReplaceWith(seqALCARECODtCalib,seqALCARECODtCalibHI)
Ejemplo n.º 24
0
    "PixelPairStep",
    "PixelLessStep",
    "TobTecStep",
])

from RecoLocalTracker.SubCollectionProducers.trackClusterRemover_cfi import trackClusterRemover as _trackClusterRemover
_trackClusterRemoverBase = _trackClusterRemover.clone(
    maxChi2                                  = 9.0,
    pixelClusters                            = "siPixelClusters",
    stripClusters                            = "siStripClusters",
    TrackQuality                             = 'highPurity',
    minNumberOfLayersWithMeasBeforeFiltering = 0,
)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(_trackClusterRemoverBase, TrackQuality = 'tight')

#Phase2 : configuring the phase2 track Cluster Remover
from RecoLocalTracker.SubCollectionProducers.phase2trackClusterRemover_cfi import phase2trackClusterRemover as _phase2trackClusterRemover
_trackClusterRemoverBase_trackingPhase2PU140 = _phase2trackClusterRemover.clone(
    maxChi2                                  = 9.0,
    phase2pixelClusters                      = "siPixelClusters",
    phase2OTClusters                         = "siPhase2Clusters",
    TrackQuality                             = 'highPurity',
    minNumberOfLayersWithMeasBeforeFiltering = 0,
)

def _modulePrefix(iteration):
    return iteration[0].lower()+iteration[1:]

def _clusterRemover(iteration):
Ejemplo n.º 25
0
    Fitter = 'FlexibleKFFittingSmoother',
)
fastSim.toModify(lowPtQuadStepTracks,TTRHBuilder = 'WithoutRefit')


# Final selection
from RecoTracker.FinalTrackSelectors.TrackMVAClassifierPrompt_cfi import *
lowPtQuadStep =  TrackMVAClassifierPrompt.clone(
    src = 'lowPtQuadStepTracks',
    mva = dict(GBRForestLabel = 'MVASelectorLowPtQuadStep_Phase1'),
    qualityCuts = [-0.7,-0.35,-0.15],
)
fastSim.toModify(lowPtQuadStep,vertices = "firstStepPrimaryVerticesBeforeMixing")
highBetaStar_2018.toModify(lowPtQuadStep,qualityCuts = [-0.9,-0.35,-0.15])
pp_on_AA_2018.toModify(lowPtQuadStep, 
        mva = dict(GBRForestLabel = 'HIMVASelectorLowPtQuadStep_Phase1'),
        qualityCuts = [-0.9, -0.4, 0.3],
)

# For Phase2PU140
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
lowPtQuadStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src = 'lowPtQuadStepTracks',
    trackSelectors = [
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name = 'lowPtQuadStepLoose',
            chi2n_par = 2.0,
            res_par = ( 0.003, 0.002 ),
            minNumberLayers = 3,
            maxNumberLostLayers = 2,
            minNumber3DLayers = 3,
            d0_par1 = ( 0.8, 4.0 ),
Ejemplo n.º 26
0
    # Iso Values
    useIsolationValues=cms.bool(False),
    SoftElecMVAFilesString=cms.vstring(
        "RecoEgamma/ElectronIdentification/data/TMVA_BDTSoftElectrons_9Dec2013.weights.xml"
    ),
    ElecMVAFilesString=cms.vstring(
        "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_10_17Feb2011.weights.xml",
        "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_12_17Feb2011.weights.xml",
        "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_20_17Feb2011.weights.xml",
        "RecoEgamma/ElectronIdentification/data/TMVA_Category_BDTSimpleCat_22_17Feb2011.weights.xml"
    ),
)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018

pp_on_AA_2018.toModify(ecalDrivenGsfElectrons, minSCEtBarrel=15.0)
pp_on_AA_2018.toModify(ecalDrivenGsfElectrons, minSCEtEndcaps=15.0)

#==============================================================================
# Final producer of persistent gsf electrons
#==============================================================================

gsfElectrons = cms.EDProducer(
    "GsfElectronProducer",

    # input collections
    previousGsfElectronsTag=cms.InputTag("ecalDrivenGsfElectrons"),
    pflowGsfElectronsTag=cms.InputTag("pfElectronTranslator:pf"),
    gsfElectronCoresTag=cms.InputTag("gsfElectronCores"),
    hcalTowers=cms.InputTag("towerMaker"),
    checkHcalStatus=cms.bool(True),
Ejemplo n.º 27
0
    src = 'pixelPairStepTrackCandidates',
    Fitter = cms.string('FlexibleKFFittingSmoother')
    )
fastSim.toModify(pixelPairStepTracks, TTRHBuilder = 'WithoutRefit')

# Final selection
from RecoTracker.FinalTrackSelectors.TrackMVAClassifierPrompt_cfi import *
pixelPairStep =  TrackMVAClassifierPrompt.clone()
pixelPairStep.src = 'pixelPairStepTracks'
pixelPairStep.mva.GBRForestLabel = 'MVASelectorIter2_13TeV'
pixelPairStep.qualityCuts = [-0.2,0.0,0.3]
highBetaStar_2018.toModify(pixelPairStep,qualityCuts = [-0.95,0.0,0.3])

trackingPhase1.toModify(pixelPairStep, mva=dict(GBRForestLabel = 'MVASelectorPixelPairStep_Phase1'))
fastSim.toModify(pixelPairStep, vertices = "firstStepPrimaryVerticesBeforeMixing")
pp_on_AA_2018.toModify(pixelPairStep, qualityCuts = [-0.2, 0.0, 0.9])

# For LowPU and Phase2PU140
import RecoTracker.IterativeTracking.LowPtTripletStep_cff
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
pixelPairStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='pixelPairStepTracks',
    useAnyMVA = cms.bool(True),
    GBRForestLabel = cms.string('MVASelectorIter2'),
    trackSelectors= cms.VPSet(
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name = 'pixelPairStepLoose',
        ), #end of pset
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
            name = 'pixelPairStepTight',
            preFilterName = 'pixelPairStepLoose',
Ejemplo n.º 28
0
                    )

#HI-specific products: needed in AOD, propagate to more inclusive tiers as well
for ec in [RecoJetsAOD.outputCommands, RecoJetsRECO.outputCommands, RecoJetsFEVT.outputCommands]:
    pA_2016.toModify( ec, 
                      func=lambda outputCommands: outputCommands.extend(['keep recoCentrality*_pACentrality_*_*',
                                                                         'keep *_hiFJGridEmptyAreaCalculator_*_*',
                                                                         'keep *_hiFJRhoProducer_*_*'
                                                                         ])
                      )

#HI-specific products: needed in AOD, propagate to more inclusive tiers as well
for ec in [RecoJetsAOD.outputCommands, RecoJetsRECO.outputCommands, RecoJetsFEVT.outputCommands]:
    peripheralPbPb.toModify( ec, 
                             func=lambda outputCommands: outputCommands.extend(['keep recoCentrality*_pACentrality_*_*'])
                             )

for ec in [RecoJetsAOD.outputCommands, RecoJetsRECO.outputCommands, RecoJetsFEVT.outputCommands]:
    pp_on_AA_2018.toModify( ec, 
                                   func=lambda outputCommands: outputCommands.extend(['keep *_hiCentrality_*_*',
                                                                                      'keep *_hiFJRhoProducer_*_*',
                                                                                      'keep *_akPu3PFJets_*_*',
                                                                                      'keep *_akPu4PFJets_*_*',
                                                                                      'keep *_kt4PFJetsForRho_*_*',
                                                                                      'keep *_akCs4PFJets_*_*',
                                                                                      'keep *_akPu4CaloJets_*_*',
                                                                                      'drop *_caloTowers_*_*'

                                                                         ])
    )    
Ejemplo n.º 29
0
    jetPtMin = cms.double(50.0) 
    )

##############################################################################
# AK8 jets with various pileup subtraction schemes
##############################################################################
ak8PFJetsPuppi = ak8PFJets.clone(
    src = cms.InputTag("puppi")
    )

ak8PFJetsCHS = ak8PFJets.clone(
    src = cms.InputTag("pfNoPileUpJME")
    )

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(ak8PFJetsCHS,src = "pfNoPileUpJMEHI", inputEtMin = 9999)

ak8PFJetsCS = ak8PFJets.clone(
    useConstituentSubtraction = cms.bool(True),    
    csRParam = cms.double(0.4),
    csRho_EtaMax = ak8PFJets.Rho_EtaMax,   # Just use the same eta for both C.S. and rho by default
    useExplicitGhosts = cms.bool(True),
    doAreaFastjet = cms.bool(True),
    jetPtMin = cms.double(100.0)
    )


##############################################################################
# Preclustered constituents for substructure, various subtraction schemes
##############################################################################
ak8PFJetsCSConstituents = cms.EDProducer("PFJetConstituentSelector",
Ejemplo n.º 30
0
    GoodTrackFractionPSet   = cms.PSet(
           Name     = cms.string("FractionOfGoodTracks_"),
                  LowerCut = cms.double(0.85),
                  UpperCut = cms.double(1.1),
               )           
)

siStripQTester = cms.EDAnalyzer("QualityTester",
    qtList = cms.untracked.FileInPath('DQM/SiStripMonitorClient/data/sistrip_qualitytest_config_tier0.xml'),
    prescaleFactor = cms.untracked.int32(1),                               
    getQualityTestsFromFile = cms.untracked.bool(True)
)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(siStripQTester,
                       qtList = cms.untracked.FileInPath('DQM/SiStripMonitorClient/data/sistrip_qualitytest_config_tier0_heavyions.xml')
                       )

from CalibTracker.SiStripESProducers.SiStripBadModuleFedErrESSource_cfi import*
siStripBadModuleFedErrESSource.appendToDataLabel = cms.string('BadModules_from_FEDBadChannel')
siStripBadModuleFedErrESSource.ReadFromFile = cms.bool(False)

from CalibTracker.SiStripESProducers.SiStripQualityESProducer_cfi import siStripQualityESProducer 
mergedSiStripQualityProducer = siStripQualityESProducer.clone(
    #names and desigantions
    ListOfRecordToMerge = cms.VPSet(
        cms.PSet(record = cms.string("SiStripDetVOffRcd"), tag = cms.string('')), # DCS information
        cms.PSet(record = cms.string('SiStripDetCablingRcd'), tag = cms.string('')), # Use Detector cabling information to exclude detectors not connected            
        cms.PSet(record = cms.string('SiStripBadChannelRcd'), tag = cms.string('')), # Online Bad components
        cms.PSet(record = cms.string('SiStripBadFiberRcd'), tag = cms.string('')),   # Bad Channel list from the selected IOV as done at PCL
        cms.PSet(record = cms.string('SiStripBadModuleFedErrRcd'), tag = cms.string('BadModules_from_FEDBadChannel')), # BadChannel list from FED erroes              
Ejemplo n.º 31
0
        cms.InputTag("ootPhotonEcalPFClusterIsolationProducer"),
        cms.InputTag("ootPhotonHcalPFClusterIsolationProducer"),
        ),
    ootPhotonFloatValueMapOutput = cms.vstring(
        "ootPhoEcalPFClusIso",
        "ootPhoHcalPFClusIso",
        ),
    gsfElectronFloatValueMapSources = cms.VInputTag(
        cms.InputTag("electronEcalPFClusterIsolationProducer"),
        cms.InputTag("electronHcalPFClusterIsolationProducer"),
        ),
    gsfElectronFloatValueMapOutput = cms.vstring(
        "eleEcalPFClusIso",
        "eleHcalPFClusIso",
        )
    )

from RecoEgamma.EgammaPhotonProducers.reducedEgamma_tools import calibrateReducedEgamma
from Configuration.Eras.Modifier_run2_miniAOD_94XFall17_cff import run2_miniAOD_94XFall17
modifyReducedEGammaRun2MiniAOD9XFall17_ = run2_miniAOD_94XFall17.makeProcessModifier(calibrateReducedEgamma)
from Configuration.Eras.Modifier_run2_miniAOD_80XLegacy_cff import run2_miniAOD_80XLegacy
modifyReducedEGammaRun2MiniAOD8XLegacy_ = run2_miniAOD_80XLegacy.makeProcessModifier(calibrateReducedEgamma)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(reducedEgamma,
    ootPhotons = cms.InputTag(""),
    keepPhotons = "pt>15 && abs(eta)<2.5",
    slimRelinkPhotons = "pt>15 && abs(eta)<2.5",
    relinkPhotons = "pt>15 && abs(eta)<2.5"
    )
Ejemplo n.º 32
0
from Configuration.Eras.Modifier_trackingPhase1_cff import trackingPhase1

trackingPhase1.toReplaceWith(pixelLessStep, pixelLessStepClassifier1.clone(
	mva = dict(GBRForestLabel = 'MVASelectorPixelLessStep_Phase1'),
	qualityCuts = [-0.4,0.0,0.4]
))

from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(pixelLessStep, TrackLwtnnClassifier.clone(
     src = 'pixelLessStepTracks',
     qualityCuts = [-0.6, -0.05, 0.5]
))
(trackdnn & fastSim).toModify(pixelLessStep,vertices = "firstStepPrimaryVerticesBeforeMixing")

pp_on_AA_2018.toModify(pixelLessStep, qualityCuts = [-0.4,0.0,0.8])

# For LowPU
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
pixelLessStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='pixelLessStepTracks',
    useAnyMVA = cms.bool(False),
    GBRForestLabel = cms.string('MVASelectorIter5'),
    trackSelectors= cms.VPSet(
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name = 'pixelLessStepLoose',
            chi2n_par = 0.5,
            res_par = ( 0.003, 0.001 ),
            minNumberLayers = 4,
            maxNumberLostLayers = 1,
            minNumber3DLayers = 3,
Ejemplo n.º 33
0
from PhysicsTools.PatAlgos.slimming.MicroEventContent_cff import *
from RecoEgamma.EgammaPhotonProducers.reducedEgamma_cfi import *
from RecoLuminosity.LumiProducer.bunchSpacingProducer_cfi import bunchSpacingProducer
from HeavyFlavorAnalysis.Onia2MuMu.OniaPhotonConversionProducer_cfi import PhotonCandidates as oniaPhotonCandidates

slimmingTask = cms.Task(
    packedPFCandidatesTask, lostTracks, isolatedTracks,
    offlineSlimmedPrimaryVertices, primaryVertexAssociation, genParticlesTask,
    selectedPatTrigger, slimmedPatTrigger, slimmedCaloJets, slimmedJets,
    slimmedJetsAK8, slimmedGenJets, slimmedGenJetsAK8, slimmedElectrons,
    slimmedMuons, slimmedPhotons, slimmedOOTPhotons, slimmedTaus,
    slimmedSecondaryVertices, slimmedKshortVertices, slimmedLambdaVertices,
    slimmedMETs, metFilterPathsTask, reducedEgamma, bunchSpacingProducer,
    oniaPhotonCandidates)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toReplaceWith(slimmingTask,
                            slimmingTask.copyAndExclude([slimmedOOTPhotons]))

from PhysicsTools.PatAlgos.packedPFCandidateMuonID_cfi import packedPFCandidateMuonID
from RecoHI.HiTracking.hipixeltracks_miniAOD_cfi import hipixeltracks
pp_on_AA_2018.toModify(packedPFCandidateMuonID,
                       muonSelectors=cms.vstring(
                           ["AllTrackerMuons", "TMOneStationTight"]))
lostTrackMuonID = packedPFCandidateMuonID.clone(
    candidates=cms.InputTag("lostTracks"))
pp_on_AA_2018.toReplaceWith(
    slimmingTask,
    cms.Task(slimmingTask.copy(), packedPFCandidateMuonID, lostTrackMuonID,
             hipixeltracks))
Ejemplo n.º 34
0
detachedTripletStepClassifier2.src = 'detachedTripletStepTracks'
detachedTripletStepClassifier2.mva.GBRForestLabel = 'MVASelectorIter0_13TeV'
detachedTripletStepClassifier2.qualityCuts = [-0.2,0.0,0.4]
fastSim.toModify(detachedTripletStepClassifier2,vertices = "firstStepPrimaryVerticesBeforeMixing")

from RecoTracker.FinalTrackSelectors.ClassifierMerger_cfi import *
detachedTripletStep = ClassifierMerger.clone()
detachedTripletStep.inputClassifiers=['detachedTripletStepClassifier1','detachedTripletStepClassifier2']

trackingPhase1.toReplaceWith(detachedTripletStep, detachedTripletStepClassifier1.clone(
     mva = dict(GBRForestLabel = 'MVASelectorDetachedTripletStep_Phase1'),
     qualityCuts = [-0.2,0.3,0.8],
))
highBetaStar_2018.toModify(detachedTripletStep,qualityCuts = [-0.5,0.0,0.5])
pp_on_AA_2018.toModify(detachedTripletStep, 
        mva = dict(GBRForestLabel = 'HIMVASelectorDetachedTripletStep_Phase1'),
        qualityCuts = [-0.2, 0.4, 0.85],
)

# For LowPU
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
detachedTripletStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src = 'detachedTripletStepTracks',
    useAnyMVA = cms.bool(False),
    GBRForestLabel = cms.string('MVASelectorIter3'),
    trackSelectors = [
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name = 'detachedTripletStepVtxLoose',
            chi2n_par = 1.6,
            res_par = ( 0.003, 0.001 ),
            minNumberLayers = 3,
            d0_par1 = ( 1.2, 3.0 ),
Ejemplo n.º 35
0
import FWCore.ParameterSet.Config as cms


electronMergedSeeds =cms.EDProducer("ElectronSeedMerger",
     EcalBasedSeeds = cms.InputTag("ecalDrivenElectronSeeds"),
     TkBasedSeeds  = cms.InputTag("trackerDrivenElectronSeeds:SeedsForGsf")
    )

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(electronMergedSeeds, TkBasedSeeds = '')

electronMergedSeedsFromMultiCl = electronMergedSeeds.clone(
  EcalBasedSeeds = 'ecalDrivenElectronSeedsFromMultiCl'
)
Ejemplo n.º 36
0
           Name     = cms.string("FractionOfGoodTracks_"),
                  LowerCut = cms.double(0.85),
                  UpperCut = cms.double(1.1),
               )           
)

from DQMServices.Core.DQMQualityTester import DQMQualityTester
siStripQTester = DQMQualityTester(
    qtList = cms.untracked.FileInPath('DQM/SiStripMonitorClient/data/sistrip_qualitytest_config_tier0.xml'),
    prescaleFactor = cms.untracked.int32(1),                               
    getQualityTestsFromFile = cms.untracked.bool(True)
)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(siStripQTester,
                       qtList = cms.untracked.FileInPath('DQM/SiStripMonitorClient/data/sistrip_qualitytest_config_tier0_heavyions.xml')
                       )

from CalibTracker.SiStripESProducers.SiStripQualityESProducer_cfi import siStripQualityESProducer 
mergedSiStripQualityProducer = siStripQualityESProducer.clone(
    #names and desigantions
    ListOfRecordToMerge = cms.VPSet(
        cms.PSet(record = cms.string("SiStripDetVOffRcd"), tag = cms.string('')), # DCS information
        cms.PSet(record = cms.string('SiStripDetCablingRcd'), tag = cms.string('')), # Use Detector cabling information to exclude detectors not connected            
        cms.PSet(record = cms.string('SiStripBadChannelRcd'), tag = cms.string('')), # Online Bad components
        cms.PSet(record = cms.string('SiStripBadFiberRcd'), tag = cms.string('')),   # Bad Channel list from the selected IOV as done at PCL
        # BadChannel list from FED errors is included below
        cms.PSet(record = cms.string('RunInfoRcd'), tag = cms.string(''))            # List of FEDs exluded during data taking          
        )
    )
Ejemplo n.º 37
0
    AlgorithmName = 'highPtTripletStep',
    Fitter = 'FlexibleKFFittingSmoother',
)
fastSim.toModify(highPtTripletStepTracks,TTRHBuilder = 'WithoutRefit')

# Final selection
from RecoTracker.FinalTrackSelectors.TrackMVAClassifierPrompt_cfi import *
highPtTripletStep = TrackMVAClassifierPrompt.clone(
    src	= 'highPtTripletStepTracks',
    mva = dict(GBRForestLabel = 'MVASelectorHighPtTripletStep_Phase1'),
    qualityCuts	= [0.2,0.3,0.4],
)
fastSim.toModify(highPtTripletStep,vertices = "firstStepPrimaryVerticesBeforeMixing")
highBetaStar_2018.toModify(highPtTripletStep,qualityCuts = [-0.2,0.3,0.4])
pp_on_AA_2018.toModify(highPtTripletStep, 
        mva = dict(GBRForestLabel = 'HIMVASelectorHighPtTripletStep_Phase1'),
        qualityCuts = [-0.9, -0.3, 0.85],
)

# For Phase2PU140
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
highPtTripletStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src = 'highPtTripletStepTracks',
    trackSelectors = [
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name = 'highPtTripletStepLoose',
            chi2n_par = 2.0,
            res_par = ( 0.003, 0.002 ),
            minNumberLayers = 3,
            maxNumberLostLayers = 3,
            minNumber3DLayers = 3,
            d0_par1 = ( 0.7, 4.0 ),
Ejemplo n.º 38
0
from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(
    detachedTripletStep,
    TrackLwtnnClassifier.clone(
        src='detachedTripletStepTracks',
        qualityCuts=[0.0, 0.4, 0.8],
    ))
(trackdnn & fastSim).toModify(detachedTripletStep,
                              vertices="firstStepPrimaryVerticesBeforeMixing")

highBetaStar_2018.toModify(detachedTripletStep, qualityCuts=[-0.5, 0.0, 0.5])
pp_on_AA_2018.toModify(
    detachedTripletStep,
    mva=dict(GBRForestLabel='HIMVASelectorDetachedTripletStep_Phase1'),
    qualityCuts=[-0.2, 0.4, 0.85],
)

# For LowPU
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
detachedTripletStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='detachedTripletStepTracks',
    useAnyMVA=cms.bool(False),
    GBRForestLabel=cms.string('MVASelectorIter3'),
    trackSelectors=[
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name='detachedTripletStepVtxLoose',
            chi2n_par=1.6,
            res_par=(0.003, 0.001),
            minNumberLayers=3,
Ejemplo n.º 39
0
#AlCaReco filtering for HCAL minbias:
#------------------------------------------------

from Calibration.HcalAlCaRecoProducers.ALCARECOHcalCalMinBiasNoise_cff import *

import HLTrigger.HLTfilters.hltHighLevel_cfi
hcalminbiasHLT =  HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone(
#    HLTPaths = ['HLT_HcalPhiSym'],
    eventSetupPathsKey='HcalCalMinBias',
    throw = False #dont throw except on unknown path name 
)

## customizations for the pp_on_AA_2018 eras
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(hcalminbiasHLT,
                       eventSetupPathsKey='HcalCalMinBiasHI'
)


import RecoLocalCalo.HcalRecProducers.HBHEPhase1Reconstructor_cfi
hbherecoMBNZS = RecoLocalCalo.HcalRecProducers.HBHEPhase1Reconstructor_cfi.hbheprereco.clone(
    digiLabelQIE8  = cms.InputTag("hcalDigiAlCaMB"),
    digiLabelQIE11 = cms.InputTag("hcalDigiAlCaMB"),
###    tsFromDB = cms.bool(False),
    dropZSmarkedPassed = cms.bool(False),
    algorithm = dict(
        useMahi = cms.bool(False),
        useM2 = cms.bool(False),
        useM3 = cms.bool(False)
    ),
    processQIE11 = cms.bool(False),
Ejemplo n.º 40
0
                 vertices="firstStepPrimaryVerticesBeforeMixing")

from RecoTracker.FinalTrackSelectors.ClassifierMerger_cfi import *
pixelLessStep = ClassifierMerger.clone()
pixelLessStep.inputClassifiers = [
    'pixelLessStepClassifier1', 'pixelLessStepClassifier2'
]

from Configuration.Eras.Modifier_trackingPhase1_cff import trackingPhase1
trackingPhase1.toReplaceWith(
    pixelLessStep,
    pixelLessStepClassifier1.clone(
        mva=dict(GBRForestLabel='MVASelectorPixelLessStep_Phase1'),
        qualityCuts=[-0.4, 0.0, 0.4],
    ))
pp_on_AA_2018.toModify(pixelLessStep, qualityCuts=[-0.4, 0.0, 0.8])

# For LowPU
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
pixelLessStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='pixelLessStepTracks',
    useAnyMVA=cms.bool(False),
    GBRForestLabel=cms.string('MVASelectorIter5'),
    trackSelectors=cms.VPSet(
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name='pixelLessStepLoose',
            chi2n_par=0.5,
            res_par=(0.003, 0.001),
            minNumberLayers=4,
            maxNumberLostLayers=1,
            minNumber3DLayers=3,
Ejemplo n.º 41
0
        "phoEcalPFClusIso",
        "phoHcalPFClusIso",
    ),
    ootPhotonFloatValueMapSources=cms.VInputTag(
        cms.InputTag("ootPhotonEcalPFClusterIsolationProducer"),
        cms.InputTag("ootPhotonHcalPFClusterIsolationProducer"),
    ),
    ootPhotonFloatValueMapOutput=cms.vstring(
        "ootPhoEcalPFClusIso",
        "ootPhoHcalPFClusIso",
    ),
    gsfElectronFloatValueMapSources=cms.VInputTag(
        cms.InputTag("electronEcalPFClusterIsolationProducer"),
        cms.InputTag("electronHcalPFClusterIsolationProducer"),
    ),
    gsfElectronFloatValueMapOutput=cms.vstring(
        "eleEcalPFClusIso",
        "eleHcalPFClusIso",
    ))

from RecoEgamma.EgammaPhotonProducers.reducedEgamma_tools import calibrateReducedEgamma
from Configuration.Eras.Modifier_run2_miniAOD_94XFall17_cff import run2_miniAOD_94XFall17
from Configuration.Eras.Modifier_run2_miniAOD_80XLegacy_cff import run2_miniAOD_80XLegacy
from Configuration.ProcessModifiers.run2_miniAOD_UL_cff import run2_miniAOD_UL
modifyReducedEGammaRun2MiniAOD = (
    run2_miniAOD_94XFall17 | run2_miniAOD_80XLegacy
    | run2_miniAOD_UL).makeProcessModifier(calibrateReducedEgamma)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(reducedEgamma, ootPhotons=cms.InputTag(""))
Ejemplo n.º 42
0
    # arbitration cleaning
    runArbitrationCleaner=cms.bool(True),
    arbitrationCleanerOptions=cms.PSet(
        ME1a=cms.bool(True),
        Overlap=cms.bool(True),
        Clustering=cms.bool(True),
        OverlapDPhi=cms.double(0.0786),  # 4.5 degrees
        OverlapDTheta=cms.double(0.02),  # 1.14 degrees
        ClusterDPhi=cms.double(0.6),  # 34 degrees
        ClusterDTheta=cms.double(0.02)  # 1.14
    ),

    # tracker muon arbitration
    arbitrateTrackerMuons=cms.bool(True))

from Configuration.Eras.Modifier_run3_GEM_cff import run3_GEM
run3_GEM.toModify(muons1stStep, TrackAssociatorParameters=dict(useGEM=True))
from Configuration.Eras.Modifier_phase2_muon_cff import phase2_muon
phase2_muon.toModify(muons1stStep, TrackAssociatorParameters=dict(useME0=True))
from Configuration.Eras.Modifier_phase2_GE0_cff import phase2_GE0
phase2_GE0.toModify(muons1stStep, TrackAssociatorParameters=dict(useME0=False))

muonEcalDetIds = cms.EDProducer("InterestingEcalDetIdProducer",
                                inputCollection=cms.InputTag("muons1stStep"))

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(muons1stStep, minPt=0.8)

from Configuration.ProcessModifiers.recoFromReco_cff import recoFromReco
recoFromReco.toModify(muons1stStep, fillShowerDigis=False)
Ejemplo n.º 43
0
_fastSim_reducedEcalRecHitsTask = reducedEcalRecHitsTask.copyAndExclude(
    seldigisTask)
from Configuration.Eras.Modifier_fastSim_cff import fastSim
fastSim.toReplaceWith(reducedEcalRecHitsTask, _fastSim_reducedEcalRecHitsTask)

_pp_on_AA_reducedEcalRecHitsTask = reducedEcalRecHitsTask.copy()
_pp_on_AA_reducedEcalRecHitsTask.remove(interestingEcalDetIdOOTPFEB)
_pp_on_AA_reducedEcalRecHitsTask.remove(interestingEcalDetIdOOTPFEE)
_pp_on_AA_reducedEcalRecHitsTask.remove(interestingEcalDetIdOOTPFES)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toReplaceWith(reducedEcalRecHitsTask,
                            _pp_on_AA_reducedEcalRecHitsTask)

pp_on_AA_2018.toModify(
    reducedEcalRecHitsEB.interestingDetIdCollections,
    func=lambda list: list.remove(cms.InputTag("interestingEcalDetIdOOTPFEB")))
pp_on_AA_2018.toModify(
    reducedEcalRecHitsEB.interestingDetIdCollections,
    func=lambda list: list.remove(cms.InputTag("interestingOotGamIsoDetIdEB")))
pp_on_AA_2018.toModify(
    reducedEcalRecHitsEE.interestingDetIdCollections,
    func=lambda list: list.remove(cms.InputTag("interestingEcalDetIdOOTPFEE")))
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(
Ejemplo n.º 44
0
from PhysicsTools.PatAlgos.selectionLayer1.jetSelector_cfi import *
#from PhysicsTools.PatAlgos.producersLayer1.hemisphereProducer_cfi import *

# One module to count objects
selectedPatCandidateSummary = cms.EDAnalyzer("CandidateSummaryTable",
    logName = cms.untracked.string("selectedPatCanddiates|PATSummaryTables"),
    candidates = cms.VInputTag(
        cms.InputTag("selectedPatElectrons"),
        cms.InputTag("selectedPatMuons"),
        cms.InputTag("selectedPatTaus"),
        cms.InputTag("selectedPatPhotons"),
        cms.InputTag("selectedPatOOTPhotons"),
        cms.InputTag("selectedPatJets"),
    )
)

selectedPatCandidatesTask = cms.Task(
    selectedPatElectrons,
    selectedPatMuons,
    selectedPatTaus,
    selectedPatPhotons,
    selectedPatOOTPhotons,
    selectedPatJets
)

selectedPatCandidates = cms.Sequence(selectedPatCandidateSummary, selectedPatCandidatesTask)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toReplaceWith(selectedPatCandidatesTask, selectedPatCandidatesTask.copyAndExclude([selectedPatOOTPhotons]))
pp_on_AA_2018.toModify(selectedPatCandidateSummary.candidates, func = lambda list: list.remove(cms.InputTag("selectedPatOOTPhotons")) )
Ejemplo n.º 45
0
from RecoTracker.TkSeedGenerator.trackerClusterCheckDefault_cfi import trackerClusterCheckDefault as _trackerClusterCheckDefault
trackerClusterCheck = _trackerClusterCheckDefault.clone()

from Configuration.Eras.Modifier_phase1Pixel_cff import phase1Pixel
from Configuration.Eras.Modifier_phase2_tracker_cff import phase2_tracker
# Disable too many clusters check until we have an updated cut string for phase1 and phase2
phase1Pixel.toModify(trackerClusterCheck, doClusterCheck=False) # FIXME
phase2_tracker.toModify(trackerClusterCheck, doClusterCheck=False) # FIXME

from Configuration.Eras.Modifier_peripheralPbPb_cff import peripheralPbPb
peripheralPbPb.toModify(trackerClusterCheck,
                        doClusterCheck=True,  #FIXMETOO
                        cut = "strip < 400000 && pixel < 40000 && (strip < 60000 + 7.0*pixel) && (pixel < 8000 + 0.14*strip)"
                        )
from Configuration.Eras.Modifier_pp_on_XeXe_2017_cff import pp_on_XeXe_2017
pp_on_XeXe_2017.toModify(trackerClusterCheck,
               doClusterCheck=True, #FIXMETOO
               cut = "strip < 1000000 && pixel < 100000 && (strip < 50000 + 10*pixel) && (pixel < 5000 + strip/2.)",
               MaxNumberOfPixelClusters = 100000
               )

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(trackerClusterCheck,
               doClusterCheck=True, 
               cut = "strip < 1000000 && pixel < 150000 && (strip < 50000 + 10*pixel) && (pixel < 5000 + strip/2.)",
               MaxNumberOfPixelClusters = 150000,
               MaxNumberOfCosmicClusters = 500000
               )
Ejemplo n.º 46
0
import FWCore.ParameterSet.Config as cms

##____________________________________________________________________________||
from RecoMET.METProducers.PFMET_cfi import *
from RecoMET.METProducers.pfChMet_cfi import *

##____________________________________________________________________________||
recoPFMETTask = cms.Task(pfMet , particleFlowForChargedMET , pfChMet)
recoPFMET = cms.Sequence(recoPFMETTask)

##____________________________________________________________________________||
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(pfMet,  globalThreshold = 999.)
pp_on_AA_2018.toModify(pfChMet, globalThreshold = 999.)
Ejemplo n.º 47
0
#ALCARECODtCalibHLTFilter.andOr = True ## choose logical OR between Triggerbits
#ALCARECODtCalibHLTFilter.HLTPaths = ['HLT_L1MuOpen*', 'HLT_L1Mu*']
ALCARECODtCalibHLTFilter.throw = False  ## dont throw on unknown path names
ALCARECODtCalibHLTFilter.eventSetupPathsKey = 'DtCalib'

import RecoLocalMuon.DTSegment.dt4DSegments_CombPatternReco4D_LinearDriftFromDB_cfi as dt4DSegmentsCfiRef
dt4DSegmentsNoWire = dt4DSegmentsCfiRef.dt4DSegments.clone()
dt4DSegmentsNoWire.Reco4DAlgoConfig.recAlgoConfig.tTrigModeConfig.doWirePropCorrection = False
dt4DSegmentsNoWire.Reco4DAlgoConfig.Reco2DAlgoConfig.recAlgoConfig.tTrigModeConfig.doWirePropCorrection = False

#this is to select collisions
from RecoMET.METFilters.metFilters_cff import primaryVertexFilter, noscraping

# Short-term workaround to preserve the "run for every event" while removing the use of convertToUnscheduled()
# To be reverted in a subsequent PR
seqALCARECODtCalibTask = cms.Task(dt4DSegmentsNoWire)
seqALCARECODtCalib = cms.Sequence(
    primaryVertexFilter * noscraping * ALCARECODtCalibHLTFilter *
    DTCalibMuonSelection, seqALCARECODtCalibTask)

## customizations for the pp_on_AA_2018 eras
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(ALCARECODtCalibHLTFilter,
                       eventSetupPathsKey='DtCalibHI')

seqALCARECODtCalibHI = cms.Sequence(ALCARECODtCalibHLTFilter,
                                    seqALCARECODtCalibTask)

#Specify to use HI sequence for the pp_on_AA_2018 eras
pp_on_AA_2018.toReplaceWith(seqALCARECODtCalib, seqALCARECODtCalibHI)
Ejemplo n.º 48
0
from Configuration.Eras.Modifier_trackingPhase1_cff import trackingPhase1
trackingPhase1.toReplaceWith(tobTecStep, tobTecStepClassifier1.clone(
     mva = dict(GBRForestLabel = 'MVASelectorTobTecStep_Phase1'),
     qualityCuts = [-0.6,-0.45,-0.3]
))

from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(tobTecStep, TrackLwtnnClassifier.clone(
     src = 'tobTecStepTracks',
     qualityCuts = [-0.4, -0.25, -0.1]
))
(trackdnn & fastSim).toModify(tobTecStep,vertices = "firstStepPrimaryVerticesBeforeMixing")

pp_on_AA_2018.toModify(tobTecStep, qualityCuts = [-0.6,-0.3,0.7])

import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
trackingLowPU.toReplaceWith(tobTecStep, RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src = 'tobTecStepTracks',
    useAnyMVA = cms.bool(False),
    GBRForestLabel = cms.string('MVASelectorIter6'),
    trackSelectors = [
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name = 'tobTecStepLoose',
            chi2n_par = 0.4,
            res_par = ( 0.003, 0.001 ),
            minNumberLayers = 5,
            maxNumberLostLayers = 1,
            minNumber3DLayers = 2,
            d0_par1 = ( 2.0, 4.0 ),
Ejemplo n.º 49
0
    lowPtTripletStep.clone(
        mva=dict(GBRForestLabel='MVASelectorLowPtTripletStep_Phase1'),
        qualityCuts=[-0.4, 0.0, 0.3],
    ))

from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(
    lowPtTripletStep,
    TrackLwtnnClassifier.clone(src='lowPtTripletStepTracks',
                               qualityCuts=[0.2, 0.5, 0.8]))

highBetaStar_2018.toModify(lowPtTripletStep, qualityCuts=[-0.7, -0.3, -0.1])
pp_on_AA_2018.toModify(
    lowPtTripletStep,
    mva=dict(GBRForestLabel='HIMVASelectorLowPtTripletStep_Phase1'),
    qualityCuts=[-0.8, -0.4, 0.5],
)
fastSim.toModify(lowPtTripletStep,
                 vertices="firstStepPrimaryVerticesBeforeMixing")

# For LowPU and Phase2PU140
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
lowPtTripletStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='lowPtTripletStepTracks',
    useAnyMVA=cms.bool(False),
    GBRForestLabel=cms.string('MVASelectorIter1'),
    trackSelectors=[
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name='lowPtTripletStepLoose', ),  #end of pset
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
Ejemplo n.º 50
0
import FWCore.ParameterSet.Config as cms

from RecoEcal.EgammaClusterProducers.particleFlowSuperClusterECALMustache_cfi import particleFlowSuperClusterECALMustache as _particleFlowSuperClusterECALMustache

# define the default ECAL clustering (Mustache or Box)
particleFlowSuperClusterECAL = _particleFlowSuperClusterECALMustache.clone()

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
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)
candidateVertexMergerCvsL = candidateVertexMerger.clone(
   secondaryVertices = "inclusiveCandidateVertexFinderCvsL"
)

candidateVertexArbitratorCvsL = candidateVertexArbitrator.clone(
   secondaryVertices = cms.InputTag("candidateVertexMergerCvsL")
)

inclusiveCandidateSecondaryVerticesCvsL = candidateVertexMerger.clone(
   secondaryVertices = "candidateVertexArbitratorCvsL",
   maxFraction = 0.2,
   minSignificance = 10.
)

inclusiveCandidateVertexingCvsLTask = cms.Task(inclusiveCandidateVertexFinderCvsL,
                                               candidateVertexMergerCvsL,
                                               candidateVertexArbitratorCvsL,
                                               inclusiveCandidateSecondaryVerticesCvsL)
inclusiveCandidateVertexingCvsL = cms.Sequence(inclusiveCandidateVertexingCvsLTask)

from Configuration.Eras.Modifier_pp_on_XeXe_2017_cff import pp_on_XeXe_2017
pp_on_XeXe_2017.toModify(inclusiveVertexFinder, minHits = 10, minPt = 1.0)
pp_on_XeXe_2017.toModify(inclusiveCandidateVertexFinder, minHits = 10, minPt = 1.0)
pp_on_XeXe_2017.toModify(inclusiveCandidateVertexFinderCvsL, minHits = 10, minPt = 1.0)
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(inclusiveVertexFinder, minHits = 999, minPt = 999.0)
pp_on_AA_2018.toModify(inclusiveCandidateVertexFinder, minHits = 999, minPt = 999.0)
pp_on_AA_2018.toModify(inclusiveCandidateVertexFinderCvsL, minHits = 999, minPt = 999.0)


Ejemplo n.º 52
0
from PhysicsTools.PatAlgos.producersLayer1.metProducer_cff import *

## module to count objects
patCandidateSummary = cms.EDAnalyzer(
    "CandidateSummaryTable",
    logName=cms.untracked.string("patCandidates|PATSummaryTables"),
    candidates=cms.VInputTag(
        cms.InputTag("patElectrons"),
        cms.InputTag("patLowPtElectrons"),
        cms.InputTag("patMuons"),
        cms.InputTag("patTaus"),
        cms.InputTag("patPhotons"),
        cms.InputTag("patOOTPhotons"),
        cms.InputTag("patJets"),
        cms.InputTag("patMETs"),
    ))

patCandidatesTask = cms.Task(makePatElectronsTask, makePatLowPtElectronsTask,
                             makePatMuonsTask, makePatTausTask,
                             makePatPhotonsTask, makePatOOTPhotonsTask,
                             makePatJetsTask, makePatMETsTask)
patCandidates = cms.Sequence(patCandidateSummary, patCandidatesTask)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toReplaceWith(
    patCandidatesTask,
    patCandidatesTask.copyAndExclude([makePatOOTPhotonsTask]))
pp_on_AA_2018.toModify(
    patCandidateSummary.candidates,
    func=lambda list: list.remove(cms.InputTag("patOOTPhotons")))
#------------------------------------------------
#AlCaReco filtering for HCAL minbias:
#------------------------------------------------

from Calibration.HcalAlCaRecoProducers.ALCARECOHcalCalMinBiasNoise_cff import *

import HLTrigger.HLTfilters.hltHighLevel_cfi
hcalminbiasHLT = HLTrigger.HLTfilters.hltHighLevel_cfi.hltHighLevel.clone(
    #    HLTPaths = ['HLT_HcalPhiSym'],
    eventSetupPathsKey='HcalCalMinBias',
    throw=False  #dont throw except on unknown path name 
)

## customizations for the pp_on_AA_2018 eras
from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
pp_on_AA_2018.toModify(hcalminbiasHLT, eventSetupPathsKey='HcalCalMinBiasHI')

import RecoLocalCalo.HcalRecProducers.HBHEPhase1Reconstructor_cfi
hbherecoMBNZS = RecoLocalCalo.HcalRecProducers.HBHEPhase1Reconstructor_cfi.hbheprereco.clone(
    digiLabelQIE8=cms.InputTag("hcalDigiAlCaMB"),
    digiLabelQIE11=cms.InputTag("hcalDigiAlCaMB"),
    ###    tsFromDB = cms.bool(False),
    dropZSmarkedPassed=cms.bool(False),
    algorithm=dict(useMahi=cms.bool(False),
                   useM2=cms.bool(False),
                   useM3=cms.bool(False)),
    processQIE11=cms.bool(False),
    setNegativeFlagsQIE8=cms.bool(False),
    setNegativeFlagsQIE11=cms.bool(False),
    setNoiseFlagsQIE8=cms.bool(True),
    setNoiseFlagsQIE11=cms.bool(False),
Ejemplo n.º 54
0
def miniAOD_customizeCommon(process):
    process.patMuons.isoDeposits = cms.PSet()
    process.patElectrons.isoDeposits = cms.PSet()
    process.patTaus.isoDeposits = cms.PSet()
    process.patPhotons.isoDeposits = cms.PSet()
    #
    process.patMuons.embedTrack = True  # used for IDs
    process.patMuons.embedCombinedMuon = True  # used for IDs
    process.patMuons.embedMuonBestTrack = True  # used for IDs
    process.patMuons.embedStandAloneMuon = True  # maybe?
    process.patMuons.embedPickyMuon = False  # no, use best track
    process.patMuons.embedTpfmsMuon = False  # no, use best track
    process.patMuons.embedDytMuon = False  # no, use best track
    process.patMuons.addPuppiIsolation = cms.bool(True)
    process.patMuons.puppiIsolationChargedHadrons = cms.InputTag(
        "muonPUPPIIsolation", "h+-DR040-ThresholdVeto000-ConeVeto000")
    process.patMuons.puppiIsolationNeutralHadrons = cms.InputTag(
        "muonPUPPIIsolation", "h0-DR040-ThresholdVeto000-ConeVeto001")
    process.patMuons.puppiIsolationPhotons = cms.InputTag(
        "muonPUPPIIsolation", "gamma-DR040-ThresholdVeto000-ConeVeto001")
    process.patMuons.puppiNoLeptonsIsolationChargedHadrons = cms.InputTag(
        "muonPUPPINoLeptonsIsolation", "h+-DR040-ThresholdVeto000-ConeVeto000")
    process.patMuons.puppiNoLeptonsIsolationNeutralHadrons = cms.InputTag(
        "muonPUPPINoLeptonsIsolation", "h0-DR040-ThresholdVeto000-ConeVeto001")
    process.patMuons.puppiNoLeptonsIsolationPhotons = cms.InputTag(
        "muonPUPPINoLeptonsIsolation",
        "gamma-DR040-ThresholdVeto000-ConeVeto001")

    process.patMuons.computeMiniIso = True
    process.patMuons.computeMuonMVA = True
    process.patMuons.computeSoftMuonMVA = True

    process.patMuons.addTriggerMatching = True
    from Configuration.Eras.Modifier_run2_muon_2016_cff import run2_muon_2016
    from Configuration.Eras.Modifier_run2_muon_2017_cff import run2_muon_2017
    from Configuration.Eras.Modifier_run2_muon_2018_cff import run2_muon_2018
    run2_muon_2016.toModify(
        process.patMuons,
        effectiveAreaVec=[0.0735, 0.0619, 0.0465, 0.0433, 0.0577])
    run2_muon_2017.toModify(
        process.patMuons,
        effectiveAreaVec=[0.0566, 0.0562, 0.0363, 0.0119, 0.0064])
    run2_muon_2018.toModify(
        process.patMuons,
        effectiveAreaVec=[0.0566, 0.0562, 0.0363, 0.0119, 0.0064])
    run2_muon_2016.toModify(
        process.patMuons,
        mvaTrainingFile=
        "RecoMuon/MuonIdentification/data/mu_2016_BDTG.weights.xml")

    process.patMuons.computePuppiCombinedIso = True
    #
    # disable embedding of electron and photon associated objects already stored by the ReducedEGProducer
    process.patElectrons.embedGsfElectronCore = False  ## process.patElectrons.embed in AOD externally stored gsf electron core
    process.patElectrons.embedSuperCluster = False  ## process.patElectrons.embed in AOD externally stored supercluster
    process.patElectrons.embedPflowSuperCluster = False  ## process.patElectrons.embed in AOD externally stored supercluster
    process.patElectrons.embedSeedCluster = False  ## process.patElectrons.embed in AOD externally stored the electron's seedcluster
    process.patElectrons.embedBasicClusters = False  ## process.patElectrons.embed in AOD externally stored the electron's basic clusters
    process.patElectrons.embedPreshowerClusters = False  ## process.patElectrons.embed in AOD externally stored the electron's preshower clusters
    process.patElectrons.embedPflowBasicClusters = False  ## process.patElectrons.embed in AOD externally stored the electron's pflow basic clusters
    process.patElectrons.embedPflowPreshowerClusters = False  ## process.patElectrons.embed in AOD externally stored the electron's pflow preshower clusters
    process.patElectrons.embedRecHits = False  ## process.patElectrons.embed in AOD externally stored the RecHits - can be called from the PATElectronProducer
    process.patElectrons.electronSource = cms.InputTag(
        "reducedEgamma", "reducedGedGsfElectrons")
    process.patElectrons.usePfCandidateMultiMap = True
    process.patElectrons.pfCandidateMultiMap = cms.InputTag(
        "reducedEgamma", "reducedGsfElectronPfCandMap")
    process.patElectrons.electronIDSources = cms.PSet()

    from Configuration.Eras.Modifier_run2_miniAOD_80XLegacy_cff import run2_miniAOD_80XLegacy
    from Configuration.Eras.Modifier_run2_miniAOD_94XFall17_cff import run2_miniAOD_94XFall17
    (run2_miniAOD_80XLegacy | run2_miniAOD_94XFall17).toModify(
        process.patElectrons,
        addPFClusterIso=True,
        ecalPFClusterIsoMap="reducedEgamma:eleEcalPFClusIso",
        hcalPFClusterIsoMap="reducedEgamma:eleHcalPFClusIso")

    #add puppi isolation in miniAOD
    process.patElectrons.addPuppiIsolation = cms.bool(True)
    process.patElectrons.puppiIsolationChargedHadrons = cms.InputTag(
        "egmElectronPUPPIIsolation", "h+-DR030-BarVeto000-EndVeto001")
    process.patElectrons.puppiIsolationNeutralHadrons = cms.InputTag(
        "egmElectronPUPPIIsolation", "h0-DR030-BarVeto000-EndVeto000")
    process.patElectrons.puppiIsolationPhotons = cms.InputTag(
        "egmElectronPUPPIIsolation", "gamma-DR030-BarVeto000-EndVeto008")
    process.patElectrons.puppiNoLeptonsIsolationChargedHadrons = cms.InputTag(
        "egmElectronPUPPINoLeptonsIsolation", "h+-DR030-BarVeto000-EndVeto001")
    process.patElectrons.puppiNoLeptonsIsolationNeutralHadrons = cms.InputTag(
        "egmElectronPUPPINoLeptonsIsolation", "h0-DR030-BarVeto000-EndVeto000")
    process.patElectrons.puppiNoLeptonsIsolationPhotons = cms.InputTag(
        "egmElectronPUPPINoLeptonsIsolation",
        "gamma-DR030-BarVeto000-EndVeto008")

    process.patElectrons.computeMiniIso = cms.bool(True)

    process.elPFIsoDepositChargedPAT.src = cms.InputTag(
        "reducedEgamma", "reducedGedGsfElectrons")
    process.elPFIsoDepositChargedAllPAT.src = cms.InputTag(
        "reducedEgamma", "reducedGedGsfElectrons")
    process.elPFIsoDepositNeutralPAT.src = cms.InputTag(
        "reducedEgamma", "reducedGedGsfElectrons")
    process.elPFIsoDepositGammaPAT.src = cms.InputTag(
        "reducedEgamma", "reducedGedGsfElectrons")
    process.elPFIsoDepositPUPAT.src = cms.InputTag("reducedEgamma",
                                                   "reducedGedGsfElectrons")
    #
    process.patPhotons.embedSuperCluster = False  ## whether to process.patPhotons.embed in AOD externally stored supercluster
    process.patPhotons.embedSeedCluster = False  ## process.patPhotons.embed in AOD externally stored the photon's seedcluster
    process.patPhotons.embedBasicClusters = False  ## process.patPhotons.embed in AOD externally stored the photon's basic clusters
    process.patPhotons.embedPreshowerClusters = False  ## process.patPhotons.embed in AOD externally stored the photon's preshower clusters
    process.patPhotons.embedRecHits = False  ## process.patPhotons.embed in AOD externally stored the RecHits - can be called from the PATPhotonProducer

    #add puppi isolation in miniAOD
    process.patPhotons.addPuppiIsolation = cms.bool(True)
    process.patPhotons.puppiIsolationChargedHadrons = cms.InputTag(
        "egmPhotonPUPPIIsolation", "h+-DR030-")
    process.patPhotons.puppiIsolationNeutralHadrons = cms.InputTag(
        "egmPhotonPUPPIIsolation", "h0-DR030-")
    process.patPhotons.puppiIsolationPhotons = cms.InputTag(
        "egmPhotonPUPPIIsolation", "gamma-DR030-")

    (run2_miniAOD_80XLegacy | run2_miniAOD_94XFall17).toModify(
        process.patPhotons,
        addPFClusterIso=True,
        ecalPFClusterIsoMap="reducedEgamma:phoEcalPFClusIso",
        hcalPFClusterIsoMap="reducedEgamma:phoHcalPFClusIso")
    #the 80X legacy customsations are done in ootPhotonProducer for OOT photons
    run2_miniAOD_94XFall17.toModify(
        process.patOOTPhotons,
        addPFClusterIso=True,
        ecalPFClusterIsoMap="reducedEgamma:ootPhoEcalPFClusIso",
        hcalPFClusterIsoMap="reducedEgamma:ootPhoHcalPFClusIso")

    process.patPhotons.photonSource = cms.InputTag("reducedEgamma",
                                                   "reducedGedPhotons")
    process.patPhotons.electronSource = cms.InputTag("reducedEgamma",
                                                     "reducedGedGsfElectrons")

    process.phPFIsoDepositChargedPAT.src = cms.InputTag(
        "reducedEgamma", "reducedGedPhotons")
    process.phPFIsoDepositChargedAllPAT.src = cms.InputTag(
        "reducedEgamma", "reducedGedPhotons")
    process.phPFIsoDepositNeutralPAT.src = cms.InputTag(
        "reducedEgamma", "reducedGedPhotons")
    process.phPFIsoDepositGammaPAT.src = cms.InputTag("reducedEgamma",
                                                      "reducedGedPhotons")
    process.phPFIsoDepositPUPAT.src = cms.InputTag("reducedEgamma",
                                                   "reducedGedPhotons")
    #
    process.patOOTPhotons.photonSource = cms.InputTag("reducedEgamma",
                                                      "reducedOOTPhotons")
    process.patOOTPhotons.electronSource = cms.InputTag(
        "reducedEgamma", "reducedGedGsfElectrons")
    #
    process.selectedPatJets.cut = cms.string("pt > 10")
    process.selectedPatMuons.cut = cms.string(
        "pt > 5 || isPFMuon || (pt > 3 && (isGlobalMuon || isStandAloneMuon || numberOfMatches > 0 || muonID('RPCMuLoose')))"
    )

    from Configuration.Eras.Modifier_phase2_muon_cff import phase2_muon
    phase2_muon.toModify(
        process.selectedPatMuons,
        cut=
        "pt > 5 || isPFMuon || (pt > 3 && (isGlobalMuon || isStandAloneMuon || numberOfMatches > 0 || muonID('RPCMuLoose') || muonID('ME0MuonArbitrated') || muonID('GEMMuonArbitrated')) )"
    )

    from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
    from Configuration.Eras.Modifier_pp_on_PbPb_run3_cff import pp_on_PbPb_run3
    (pp_on_AA_2018 | pp_on_PbPb_run3).toModify(
        process.selectedPatMuons,
        cut=
        "pt > 5 || isPFMuon || (pt > 1.2 && (isGlobalMuon || isStandAloneMuon) )"
    )

    process.selectedPatElectrons.cut = cms.string("")
    process.selectedPatTaus.cut = cms.string(
        "pt > 18. && tauID('decayModeFindingNewDMs')> 0.5")
    process.selectedPatPhotons.cut = cms.string("")

    from PhysicsTools.PatAlgos.tools.jetTools import addJetCollection

    from PhysicsTools.PatAlgos.slimming.applySubstructure_cff import applySubstructure
    applySubstructure(process)

    #
    from PhysicsTools.PatAlgos.tools.trigTools import switchOnTriggerStandAlone
    switchOnTriggerStandAlone(process, outputModule='')
    process.patTrigger.packTriggerPathNames = cms.bool(True)
    #
    # apply type I + other PFMEt corrections to pat::MET object
    # and estimate systematic uncertainties on MET

    from PhysicsTools.PatUtils.tools.runMETCorrectionsAndUncertainties import runMetCorAndUncForMiniAODProduction
    runMetCorAndUncForMiniAODProduction(process,
                                        metType="PF",
                                        jetCollUnskimmed="patJets")

    #caloMET computation
    from PhysicsTools.PatAlgos.tools.metTools import addMETCollection
    addMETCollection(process, labelName="patCaloMet", metSource="caloMetM")

    #noHF pfMET =========

    task = getPatAlgosToolsTask(process)

    process.noHFCands = cms.EDFilter(
        "GenericPFCandidateSelector",
        src=cms.InputTag("particleFlow"),
        cut=cms.string("abs(pdgId)!=1 && abs(pdgId)!=2 && abs(eta)<3.0"))
    task.add(process.noHFCands)

    runMetCorAndUncForMiniAODProduction(
        process,
        pfCandColl=cms.InputTag("noHFCands"),
        recoMetFromPFCs=True,  #needed for HF removal
        jetSelection="pt>15 && abs(eta)<3.",
        postfix="NoHF")

    process.load('PhysicsTools.PatAlgos.slimming.slimmedMETs_cfi')
    task.add(process.slimmedMETs)
    process.slimmedMETs.addDeepMETs = True

    addToProcessAndTask('slimmedMETsNoHF', process.slimmedMETs.clone(),
                        process, task)
    process.slimmedMETsNoHF.src = cms.InputTag("patMETsNoHF")
    process.slimmedMETsNoHF.rawVariation = cms.InputTag("patPFMetNoHF")
    process.slimmedMETsNoHF.t1Uncertainties = cms.InputTag("patPFMetT1%sNoHF")
    process.slimmedMETsNoHF.t01Variation = cms.InputTag("patPFMetT0pcT1NoHF")
    process.slimmedMETsNoHF.t1SmearedVarsAndUncs = cms.InputTag(
        "patPFMetT1Smear%sNoHF")
    process.slimmedMETsNoHF.tXYUncForRaw = cms.InputTag("patPFMetTxyNoHF")
    process.slimmedMETsNoHF.tXYUncForT1 = cms.InputTag("patPFMetT1TxyNoHF")
    process.slimmedMETsNoHF.tXYUncForT01 = cms.InputTag(
        "patPFMetT0pcT1TxyNoHF")
    process.slimmedMETsNoHF.tXYUncForT1Smear = cms.InputTag(
        "patPFMetT1SmearTxyNoHF")
    process.slimmedMETsNoHF.tXYUncForT01Smear = cms.InputTag(
        "patPFMetT0pcT1SmearTxyNoHF")
    del process.slimmedMETsNoHF.caloMET
    # ================== NoHF pfMET

    #  ==================  CHSMET
    process.CHSCands = cms.EDFilter("CandPtrSelector",
                                    src=cms.InputTag("packedPFCandidates"),
                                    cut=cms.string("fromPV(0) > 0"))
    task.add(process.CHSCands)

    from RecoMET.METProducers.pfMet_cfi import pfMet
    process.pfMetCHS = pfMet.clone(src='CHSCands')
    task.add(process.pfMetCHS)

    addMETCollection(process, labelName="patCHSMet", metSource="pfMetCHS")

    process.patCHSMet.computeMETSignificance = cms.bool(False)

    #  ==================  CHSMET

    #  ==================  TrkMET
    process.TrkCands = cms.EDFilter(
        "CandPtrSelector",
        src=cms.InputTag("packedPFCandidates"),
        cut=cms.string(
            "charge()!=0 && pvAssociationQuality()>=4 && vertexRef().key()==0")
    )
    task.add(process.TrkCands)

    process.pfMetTrk = pfMet.clone(src='TrkCands')
    task.add(process.pfMetTrk)

    addMETCollection(process, labelName="patTrkMet", metSource="pfMetTrk")

    process.patTrkMet.computeMETSignificance = cms.bool(False)

    #  ==================  TrkMET

    ## PU JetID
    process.load("RecoJets.JetProducers.PileupJetID_cfi")
    task.add(process.pileUpJetIDTask)

    process.patJets.userData.userFloats.src = [
        cms.InputTag("pileupJetId:fullDiscriminant"),
    ]
    process.patJets.userData.userInts.src = [
        cms.InputTag("pileupJetId:fullId"),
    ]

    ## Quark Gluon Likelihood
    process.load('RecoJets.JetProducers.QGTagger_cfi')
    task.add(process.QGTaggerTask)

    process.patJets.userData.userFloats.src += [
        cms.InputTag('QGTagger:qgLikelihood'),
    ]

    ## DeepCSV meta discriminators (simple arithmethic on output probabilities)
    process.load('RecoBTag.Combined.deepFlavour_cff')
    task.add(process.pfDeepCSVDiscriminatorsJetTags)
    process.patJets.discriminatorSources.extend([
        cms.InputTag('pfDeepCSVDiscriminatorsJetTags:BvsAll'),
        cms.InputTag('pfDeepCSVDiscriminatorsJetTags:CvsB'),
        cms.InputTag('pfDeepCSVDiscriminatorsJetTags:CvsL'),
    ])

    ## CaloJets
    process.caloJetMap = cms.EDProducer(
        "RecoJetDeltaRValueMapProducer",
        src=process.patJets.jetSource,
        matched=cms.InputTag("ak4CaloJets"),
        distMax=cms.double(0.4),
        values=cms.vstring('pt', 'emEnergyFraction'),
        valueLabels=cms.vstring('pt', 'emEnergyFraction'),
        lazyParser=cms.bool(True))
    task.add(process.caloJetMap)
    process.patJets.userData.userFloats.src += [
        cms.InputTag("caloJetMap:pt"),
        cms.InputTag("caloJetMap:emEnergyFraction")
    ]

    #Muon object modifications
    from PhysicsTools.PatAlgos.slimming.muonIsolationsPUPPI_cfi import makeInputForPUPPIIsolationMuon
    makeInputForPUPPIIsolationMuon(process)

    #EGM object modifications
    from PhysicsTools.PatAlgos.slimming.egmIsolationsPUPPI_cfi import makeInputForPUPPIIsolationEgm
    makeInputForPUPPIIsolationEgm(process)
    from RecoEgamma.EgammaTools.egammaObjectModificationsInMiniAOD_cff import egamma_modifications
    process.slimmedElectrons.modifierConfig.modifications = egamma_modifications
    process.slimmedPhotons.modifierConfig.modifications = egamma_modifications

    #VID Electron IDs
    process.patElectrons.addElectronID = cms.bool(True)
    electron_ids = [
        'RecoEgamma.ElectronIdentification.Identification.heepElectronID_HEEPV70_cff',
        'RecoEgamma.ElectronIdentification.Identification.heepElectronID_HEEPV71_cff',
        'RecoEgamma.ElectronIdentification.Identification.cutBasedElectronID_Fall17_94X_V1_cff',
        'RecoEgamma.ElectronIdentification.Identification.cutBasedElectronID_Fall17_94X_V2_cff',
        'RecoEgamma.ElectronIdentification.Identification.mvaElectronID_Fall17_noIso_V1_cff',
        'RecoEgamma.ElectronIdentification.Identification.mvaElectronID_Fall17_iso_V1_cff',
        'RecoEgamma.ElectronIdentification.Identification.mvaElectronID_Fall17_noIso_V2_cff',
        'RecoEgamma.ElectronIdentification.Identification.mvaElectronID_Fall17_iso_V2_cff',
        'RecoEgamma.ElectronIdentification.Identification.cutBasedElectronID_Summer16_80X_V1_cff',
        'RecoEgamma.ElectronIdentification.Identification.mvaElectronID_Spring16_GeneralPurpose_V1_cff',
        'RecoEgamma.ElectronIdentification.Identification.mvaElectronID_Spring16_HZZ_V1_cff',
    ]
    switchOnVIDElectronIdProducer(process, DataFormat.MiniAOD, task)
    process.egmGsfElectronIDs.physicsObjectSrc = cms.InputTag(
        "reducedEgamma", "reducedGedGsfElectrons")
    process.electronMVAValueMapProducer.src = cms.InputTag(
        'reducedEgamma', 'reducedGedGsfElectrons')

    # To use older DataFormats, the electronMVAValueMapProducer MUST take a updated electron collection
    # such that the conversion variables are filled correctly.
    process.load("RecoEgamma.EgammaTools.gedGsfElectronsTo106X_cff")
    run2_miniAOD_80XLegacy.toModify(
        task, func=lambda t: t.add(process.gedGsfElectronsFrom80XTo106XTask))
    run2_miniAOD_80XLegacy.toModify(
        process.electronMVAValueMapProducer,
        keysForValueMaps=cms.InputTag('reducedEgamma',
                                      'reducedGedGsfElectrons'),
        src=cms.InputTag("gedGsfElectronsFrom80XTo106X"))

    run2_miniAOD_94XFall17.toModify(
        task, func=lambda t: t.add(process.gedGsfElectronsFrom94XTo106XTask))
    run2_miniAOD_94XFall17.toModify(
        process.electronMVAValueMapProducer,
        keysForValueMaps=cms.InputTag('reducedEgamma',
                                      'reducedGedGsfElectrons'),
        src=cms.InputTag("gedGsfElectronsFrom94XTo106X"))

    from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018
    pp_on_AA_2018.toModify(
        task, func=lambda t: t.add(process.gedGsfElectronsFrom94XTo106XTask))
    pp_on_AA_2018.toModify(process.electronMVAValueMapProducer,
                           keysForValueMaps=cms.InputTag(
                               'reducedEgamma', 'reducedGedGsfElectrons'),
                           src="gedGsfElectronsFrom94XTo106X")

    for idmod in electron_ids:
        setupAllVIDIdsInModule(process, idmod, setupVIDElectronSelection, None,
                               False, task)

    #VID Photon IDs
    process.patPhotons.addPhotonID = cms.bool(True)
    photon_ids = [
        'RecoEgamma.PhotonIdentification.Identification.cutBasedPhotonID_Fall17_94X_V1_TrueVtx_cff',
        'RecoEgamma.PhotonIdentification.Identification.cutBasedPhotonID_Fall17_94X_V2_cff',
        'RecoEgamma.PhotonIdentification.Identification.mvaPhotonID_Fall17_94X_V1p1_cff',
        'RecoEgamma.PhotonIdentification.Identification.mvaPhotonID_Fall17_94X_V2_cff',
        'RecoEgamma.PhotonIdentification.Identification.cutBasedPhotonID_Spring16_V2p2_cff',
        'RecoEgamma.PhotonIdentification.Identification.mvaPhotonID_Spring16_nonTrig_V1_cff'
    ]
    switchOnVIDPhotonIdProducer(process, DataFormat.AOD, task)
    process.egmPhotonIDs.physicsObjectSrc = cms.InputTag(
        "reducedEgamma", "reducedGedPhotons")
    process.photonMVAValueMapProducer.src = cms.InputTag(
        'reducedEgamma', 'reducedGedPhotons')
    for idmod in photon_ids:
        setupAllVIDIdsInModule(process, idmod, setupVIDPhotonSelection, None,
                               False, task)

    #add the cut base IDs bitmaps of which cuts passed
    from RecoEgamma.EgammaTools.egammaObjectModifications_tools import makeVIDBitsModifier
    egamma_modifications.append(
        makeVIDBitsModifier(process, "egmGsfElectronIDs", "egmPhotonIDs"))

    #-- Adding boosted taus
    from RecoTauTag.Configuration.boostedHPSPFTaus_cfi import addBoostedTaus
    addBoostedTaus(process)
    process.load("RecoTauTag.Configuration.RecoPFTauTag_cff")
    process.load("RecoTauTag.Configuration.HPSPFTaus_cff")
    #-- Adding customization for 94X 2017 legacy reMniAOD
    _makePatTausTaskWithRetrainedMVATauID = process.makePatTausTask.copy()
    _makePatTausTaskWithRetrainedMVATauID.add(
        process.hpsPFTauBasicDiscriminatorsTask,
        process.hpsPFTauDiscriminationByIsolationMVArun2v1DBoldDMwLTTask,
        process.hpsPFTauDiscriminationByIsolationMVArun2v1DBnewDMwLTTask,
        process.hpsPFTauBasicDiscriminatorsdR03Task,
        process.hpsPFTauDiscriminationByIsolationMVArun2v1DBdR03oldDMwLTTask,
        process.hpsPFTauDiscriminationByMVA6rawElectronRejection,
        process.hpsPFTauDiscriminationByMVA6ElectronRejection,
        process.hpsPFTauDiscriminationByMuonRejection3)
    from Configuration.ProcessModifiers.run2_miniAOD_UL_cff import run2_miniAOD_UL
    (run2_miniAOD_94XFall17 | run2_miniAOD_UL).toReplaceWith(
        process.makePatTausTask, _makePatTausTaskWithRetrainedMVATauID)
    #-- Adding DeepTauID
    # deepTau v2p1
    _updatedTauName = 'slimmedTausDeepIDsv2p1'
    _noUpdatedTauName = 'slimmedTausNoDeepIDs'
    import RecoTauTag.RecoTau.tools.runTauIdMVA as tauIdConfig
    tauIdEmbedder = tauIdConfig.TauIDEmbedder(process,
                                              debug=False,
                                              updatedTauName=_updatedTauName,
                                              toKeep=['deepTau2017v2p1'])
    from Configuration.Eras.Modifier_phase2_common_cff import phase2_common  #Phase2 Tau MVA
    phase2_common.toModify(
        tauIdEmbedder.toKeep,
        func=lambda t: t.append('newDMPhase2v1'))  #Phase2 Tau MVA
    tauIdEmbedder.runTauID()
    addToProcessAndTask(_noUpdatedTauName, process.slimmedTaus.clone(),
                        process, task)
    delattr(process, 'slimmedTaus')
    process.deepTau2017v2p1.taus = _noUpdatedTauName
    process.slimmedTaus = getattr(process,
                                  _updatedTauName).clone(src=_noUpdatedTauName)
    process.deepTauIDTask = cms.Task(process.deepTau2017v2p1,
                                     process.slimmedTaus)
    task.add(process.deepTauIDTask)
    if 'newDMPhase2v1' in tauIdEmbedder.toKeep:
        process.rerunDiscriminationByIsolationMVADBnewDMwLTPhase2raw.PATTauProducer = _noUpdatedTauName
        process.rerunDiscriminationByIsolationMVADBnewDMwLTPhase2.PATTauProducer = _noUpdatedTauName
        task.add(process.rerunIsolationMVADBnewDMwLTPhase2Task)

    #-- Rerun tauID against dead ECal towers to taus for the various re-MiniAOD eras
    # to enable default behoviour with leading track extrapolation to ECAL
    _makePatTausTaskWithDeadECalVeto = process.makePatTausTask.copy()
    _makePatTausTaskWithDeadECalVeto.add(
        process.hpsPFTauDiscriminationByDeadECALElectronRejection)
    _run2_miniAOD_ANY = (run2_miniAOD_80XLegacy | run2_miniAOD_94XFall17
                         | run2_miniAOD_UL)
    _run2_miniAOD_ANY.toReplaceWith(process.makePatTausTask,
                                    _makePatTausTaskWithDeadECalVeto)

    #-- Adding customization for 80X 2016 legacy reMiniAOD and 2018 heavy ions
    _makePatTausTaskWithTauReReco = process.makePatTausTask.copy()
    _makePatTausTaskWithTauReReco.add(process.PFTauTask)
    (run2_miniAOD_80XLegacy | pp_on_AA_2018).toReplaceWith(
        process.makePatTausTask, _makePatTausTaskWithTauReReco)

    # Adding puppi jets
    process.load('CommonTools.PileupAlgos.Puppi_cff')
    process.load('RecoJets.JetProducers.ak4PFJets_cfi')
    from Configuration.Eras.Modifier_pA_2016_cff import pA_2016
    _rerun_puppijets_task = task.copy()
    _rerun_puppijets_task.add(process.puppi, process.ak4PFJetsPuppi)
    (_run2_miniAOD_ANY | pA_2016 | pp_on_AA_2018).toReplaceWith(
        task, _rerun_puppijets_task)

    from RecoJets.JetAssociationProducers.j2tParametersVX_cfi import j2tParametersVX
    process.ak4PFJetsPuppiTracksAssociatorAtVertex = cms.EDProducer(
        "JetTracksAssociatorAtVertex",
        j2tParametersVX,
        jets=cms.InputTag("ak4PFJetsPuppi"))
    task.add(process.ak4PFJetsPuppiTracksAssociatorAtVertex)
    process.patJetPuppiCharge = cms.EDProducer(
        "JetChargeProducer",
        src=cms.InputTag("ak4PFJetsPuppiTracksAssociatorAtVertex"),
        var=cms.string('Pt'),
        exp=cms.double(1.0))
    task.add(process.patJetPuppiCharge)

    noDeepFlavourDiscriminators = [
        x.value() for x in process.patJets.discriminatorSources
        if not "DeepFlavour" in x.value()
    ]
    addJetCollection(process,
                     postfix="",
                     labelName='Puppi',
                     jetSource=cms.InputTag('ak4PFJetsPuppi'),
                     jetCorrections=('AK4PFPuppi',
                                     ['L2Relative', 'L3Absolute'], ''),
                     pfCandidates=cms.InputTag("particleFlow"),
                     algo='AK',
                     rParam=0.4,
                     btagDiscriminators=noDeepFlavourDiscriminators)

    process.patJetGenJetMatchPuppi.matched = 'slimmedGenJets'

    process.patJetsPuppi.jetChargeSource = cms.InputTag("patJetPuppiCharge")

    process.selectedPatJetsPuppi.cut = cms.string("pt > 15")

    from PhysicsTools.PatAlgos.slimming.applyDeepBtagging_cff import applyDeepBtagging
    applyDeepBtagging(process)

    addToProcessAndTask(
        'slimmedJetsPuppi',
        process.slimmedJetsNoDeepFlavour.clone(
            src="selectedPatJetsPuppi",
            packedPFCandidates="packedPFCandidates"), process, task)

    task.add(process.slimmedJetsPuppi)

    # Embed pixelClusterTagInfos in slimmedJets
    process.patJets.addTagInfos = True
    process.patJets.tagInfoSources = ["pixelClusterTagInfos"]
    process.slimmedJetsNoDeepFlavour.dropTagInfos = '0'
    process.updatedPatJetsTransientCorrectedSlimmedDeepFlavour.addTagInfos = True
    process.updatedPatJetsTransientCorrectedSlimmedDeepFlavour.tagInfoSources = [
        "pixelClusterTagInfos"
    ]

    _run2_miniAOD_ANY.toModify(process.patJets, addTagInfos=False)
    _run2_miniAOD_ANY.toModify(
        process.updatedPatJetsTransientCorrectedSlimmedDeepFlavour,
        addTagInfos=False)

    ## puppi met
    process.load('RecoMET.METProducers.pfMetPuppi_cfi')
    _rerun_puppimet_task = task.copy()
    _rerun_puppimet_task.add(process.puppiNoLep, process.pfMetPuppi)
    (_run2_miniAOD_ANY | pA_2016 | pp_on_AA_2018).toReplaceWith(
        task, _rerun_puppimet_task)

    runMetCorAndUncForMiniAODProduction(process,
                                        metType="Puppi",
                                        jetCollUnskimmed="slimmedJetsPuppi",
                                        recoMetFromPFCs=True,
                                        jetFlavor="AK4PFPuppi",
                                        postfix="Puppi")

    process.load('PhysicsTools.PatAlgos.slimming.slimmedMETs_cfi')
    task.add(process.slimmedMETs)
    addToProcessAndTask('slimmedMETsPuppi', process.slimmedMETs.clone(),
                        process, task)
    process.slimmedMETsPuppi.src = cms.InputTag("patMETsPuppi")
    process.slimmedMETsPuppi.rawVariation = cms.InputTag("patPFMetPuppi")
    process.slimmedMETsPuppi.t1Uncertainties = cms.InputTag(
        "patPFMetT1%sPuppi")
    process.slimmedMETsPuppi.t01Variation = cms.InputTag("patPFMetT0pcT1Puppi")
    process.slimmedMETsPuppi.t1SmearedVarsAndUncs = cms.InputTag(
        "patPFMetT1Smear%sPuppi")
    process.slimmedMETsPuppi.tXYUncForRaw = cms.InputTag("patPFMetTxyPuppi")
    process.slimmedMETsPuppi.tXYUncForT1 = cms.InputTag("patPFMetT1TxyPuppi")
    process.slimmedMETsPuppi.tXYUncForT01 = cms.InputTag(
        "patPFMetT0pcT1TxyPuppi")
    process.slimmedMETsPuppi.tXYUncForT1Smear = cms.InputTag(
        "patPFMetT1SmearTxyPuppi")
    process.slimmedMETsPuppi.tXYUncForT01Smear = cms.InputTag(
        "patPFMetT0pcT1SmearTxyPuppi")
    del process.slimmedMETsPuppi.caloMET

    process.load('RecoMET.METPUSubtraction.deepMETProducer_cfi')

    addToProcessAndTask('deepMETsResolutionTune',
                        process.deepMETProducer.clone(), process, task)
    addToProcessAndTask('deepMETsResponseTune',
                        process.deepMETProducer.clone(), process, task)
    process.deepMETsResponseTune.graph_path = 'RecoMET/METPUSubtraction/data/deepmet/deepmet_resp_v1_2018.pb'

    from Configuration.Eras.Modifier_phase2_common_cff import phase2_common
    phase2_common.toModify(
        process.deepMETsResolutionTune,
        max_n_pf=12500,
        graph_path="RecoMET/METPUSubtraction/data/deepmet/deepmet_v1_phase2.pb"
    )
    phase2_common.toModify(
        process.deepMETsResponseTune,
        max_n_pf=12500,
        graph_path=
        "RecoMET/METPUSubtraction/data/deepmet/deepmet_resp_v1_phase2.pb")

    from Configuration.Eras.Modifier_run2_jme_2016_cff import run2_jme_2016
    run2_jme_2016.toModify(
        process.deepMETsResponseTune,
        graph_path=
        "RecoMET/METPUSubtraction/data/deepmet/deepmet_resp_v1_2016.pb")
    # add DetIdAssociatorRecords to EventSetup (for isolatedTracks)
    process.load("TrackingTools.TrackAssociator.DetIdAssociatorESProducer_cff")

    # EGamma objects from HGCal are not yet in GED
    # so add companion collections for Phase-II MiniAOD production
    from Configuration.Eras.Modifier_phase2_hgcal_cff import phase2_hgcal
    process.load("RecoEgamma.EgammaTools.slimmedEgammaFromMultiCl_cff")
    phase2_hgcal.toModify(
        task, func=lambda t: t.add(process.slimmedEgammaFromMultiClTask))

    # L1 pre-firing weights for 2016 and 2017
    from Configuration.Eras.Modifier_run2_L1prefiring_cff import run2_L1prefiring
    from Configuration.Eras.Modifier_stage1L1Trigger_cff import stage1L1Trigger
    from Configuration.Eras.Modifier_stage2L1Trigger_2017_cff import stage2L1Trigger_2017
    process.load("PhysicsTools.PatUtils.L1ECALPrefiringWeightProducer_cff")
    stage1L1Trigger.toModify(process.prefiringweight, DataEra="2016BtoH")
    stage2L1Trigger_2017.toModify(process.prefiringweight, DataEra="2017BtoF")
    run2_L1prefiring.toModify(task,
                              func=lambda t: t.add(process.prefiringweight))
Ejemplo n.º 55
0
    rMinI=cms.double(
        -0.2),  ## intermediate region SC in EB and 2nd hits in PXF
    rMaxI=cms.double(0.2),  ## intermediate region SC in EB and 2nd hits in PXF

    # phi windows (dynamic)
    LowPtThreshold=cms.double(5.0),
    HighPtThreshold=cms.double(35.0),
    SizeWindowENeg=cms.double(0.675),
    DeltaPhi1Low=cms.double(0.23),
    DeltaPhi1High=cms.double(0.08),
    #    DeltaPhi2 = cms.double(0.008),
    DeltaPhi2B=cms.double(0.008),  ## barrel
    DeltaPhi2F=cms.double(0.012),  ## forward

    # phi windows (non dynamic, overwritten in case dynamic is selected)
    ePhiMin1=cms.double(-0.125),
    ePhiMax1=cms.double(0.075),
    pPhiMin1=cms.double(-0.075),
    pPhiMax1=cms.double(0.125),
    #    PhiMin2 = cms.double(-0.002),
    #    PhiMax2 = cms.double(0.002),
    PhiMin2B=cms.double(-0.002),  ## barrel
    PhiMax2B=cms.double(0.002),  ## barrel
    PhiMin2F=cms.double(-0.003),  ## forward
    PhiMax2F=cms.double(0.003),  ## forward
)

from Configuration.Eras.Modifier_pp_on_AA_2018_cff import pp_on_AA_2018

pp_on_AA_2018.toModify(ecalDrivenElectronSeedsParameters, SCEtCut=15.0)
Ejemplo n.º 56
0
    initialStepClassifier1.clone(
        mva=dict(GBRForestLabel='MVASelectorInitialStep_Phase1'),
        qualityCuts=[-0.95, -0.85, -0.75]))

from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(
    initialStep,
    TrackLwtnnClassifier.clone(src='initialStepTracks',
                               qualityCuts=[0.0, 0.3, 0.6]))
(trackdnn & fastSim).toModify(initialStep,
                              vertices="firstStepPrimaryVerticesBeforeMixing")

pp_on_AA_2018.toModify(
    initialStep,
    mva=dict(GBRForestLabel='HIMVASelectorInitialStep_Phase1'),
    qualityCuts=[-0.9, -0.5, 0.2],
)

# For LowPU and Phase2PU140
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
initialStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='initialStepTracks',
    useAnyMVA=cms.bool(False),
    GBRForestLabel=cms.string('MVASelectorIter0'),
    trackSelectors=[
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name='initialStepLoose', ),  #end of pset
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
            name='initialStepTight',
            preFilterName='initialStepLoose',
Ejemplo n.º 57
0
pixelPairStep.src = 'pixelPairStepTracks'
pixelPairStep.mva.GBRForestLabel = 'MVASelectorIter2_13TeV'
pixelPairStep.qualityCuts = [-0.2, 0.0, 0.3]

trackingPhase1.toModify(
    pixelPairStep, mva=dict(GBRForestLabel='MVASelectorPixelPairStep_Phase1'))

from RecoTracker.FinalTrackSelectors.TrackLwtnnClassifier_cfi import *
from RecoTracker.FinalTrackSelectors.trackSelectionLwtnn_cfi import *
trackdnn.toReplaceWith(
    pixelPairStep,
    TrackLwtnnClassifier.clone(src='pixelPairStepTracks',
                               qualityCuts=[-0.6, -0.1, 0.4]))

highBetaStar_2018.toModify(pixelPairStep, qualityCuts=[-0.95, 0.0, 0.3])
pp_on_AA_2018.toModify(pixelPairStep, qualityCuts=[-0.2, 0.0, 0.98])
fastSim.toModify(pixelPairStep,
                 vertices="firstStepPrimaryVerticesBeforeMixing")

# For LowPU and Phase2PU140
import RecoTracker.IterativeTracking.LowPtTripletStep_cff
import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
pixelPairStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
    src='pixelPairStepTracks',
    useAnyMVA=cms.bool(True),
    GBRForestLabel=cms.string('MVASelectorIter2'),
    trackSelectors=cms.VPSet(
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
            name='pixelPairStepLoose', ),  #end of pset
        RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
            name='pixelPairStepTight',