Esempio n. 1
0
process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
process.load('FWCore.MessageService.MessageLogger_cfi')
process.load('Configuration.EventContent.EventContent_cff')
process.load('Configuration.StandardSequences.GeometryRecoDB_cff')
process.load('Configuration.StandardSequences.MagneticField_AutoFromDBCurrent_cff')
process.load('Configuration.StandardSequences.EndOfProcess_cff')
process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_condDBv2_cff')
process.load("TrackingTools/TransientTrack/TransientTrackBuilder_cfi")

process.CandidateSelectedTracks = cms.EDProducer( "ConcreteChargedCandidateProducer",
                src=cms.InputTag("oniaSelectedTracks::RECO"),
                particleType=cms.string('pi+')
)

from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles
process.patSelectedTracks = patGenericParticles.clone(src=cms.InputTag("CandidateSelectedTracks"))

process.MessageLogger.cerr.FwkReport.reportEvery = 100
process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(True) )
process.options.allowUnscheduled = cms.untracked.bool(True)

process.source = cms.Source("PoolSource",fileNames = cms.untracked.vstring(
#
### use this to access the nearest copy of the input file, querying the catalog
#
    '/store/data/Run2016E/Charmonium/USER/BPHSkim-PromptReco-v2/000/276/831/00000/00FD1519-714D-E611-B686-FA163E321AE0.root'
### use this to access the input file if by any reason you want to specify 
### the data server
#    'root://xrootd-cms.infn.it//store/data/Run2016E/Charmonium/USER/BPHSkim-PromptReco-v2/000/276/831/00000/00FD1519-714D-E611-B686-FA163E321AE0.root'
#
### use this to access an input file locally available
Esempio n. 2
0
patAODTrackCands.cut = 'pt > 15.'

# pat tracks
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles

allPatTracks = patGenericParticles.clone(
    src=cms.InputTag("patAODTrackCands"),
    embedTrack=cms.bool(True),
    # isolation configurables
    userIsolation=cms.PSet(
        tracker=cms.PSet(src=cms.InputTag("patAODTrackIsoDepositCtfTk"),
                         deltaR=cms.double(0.3)),
        ecal=cms.PSet(src=cms.InputTag(
            "patAODTrackIsoDepositCalByAssociatorTowers", "ecal"),
                      deltaR=cms.double(0.3)),
        hcal=cms.PSet(src=cms.InputTag(
            "patAODTrackIsoDepositCalByAssociatorTowers", "hcal"),
                      deltaR=cms.double(0.3)),
    ),
    isoDeposits=cms.PSet(
        tracker=cms.InputTag("patAODTrackIsoDepositCtfTk"),
        ecal=cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers",
                          "ecal"),
        hcal=cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers",
                          "hcal")),
    addGenMatch=cms.bool(False))

from PhysicsTools.PatAlgos.selectionLayer1.trackSelector_cfi import *
selectedPatTracks.cut = 'pt > 15. & track.dxy()<1.0'

# PAT MUONS
############################################
## -6- l1MuTkMatch - from l1muonsAnyBX and selectedLayer1TrackCands
process.l1MuTkMatch = process.muonL1Info.clone()
process.l1MuTkMatch.src     = cms.InputTag('selectedLayer1TrackCands') 
process.l1MuTkMatch.matched = cms.InputTag('l1muonsAnyBX')
process.l1MuTkMatch.resolveAmbiguitiesByMatchQuality = cms.bool(True)
process.l1MuTkMatch.sortByRes = cms.string("deltaR")
process.l1MuTkMatch.maxDeltaPhi = 0.3
process.l1MuTkMatch.maxDeltaR   = 1
process.l1MuTkMatch.maxDeltaEta = 0.4      
process.l1MuTkMatch.writeExtraInfo = cms.bool(True)
############################################
## -8- trackMuonMatch from selectedLayer1TrackCands and l1MuTkMatch
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles
process.trackMuonMatch = patGenericParticles.clone(
    src = cms.InputTag("selectedLayer1TrackCands")
)
process.trackMuonMatch.userData.userCands.src += [cms.InputTag("l1MuTkMatch") ]
############################################
## -9- tagProbesJPsi from tagMuons and trackMuonMatch => JPsi
process.tagProbesJPsi = cms.EDProducer("CandViewShallowCloneCombiner",
decay = cms.string("tagMuons@+ trackMuonMatch@-"), # charge coniugate states are implied; 'tagMuons' and 'trkProbes' should be collections of Candidates
cut   = cms.string("2.8 < mass < 3.5"),                   
)
############################################
## -10- tagProbesFilter from tagProbesMuTrk 
process.tagProbesJPsiFilter = cms.EDFilter("PATCandViewCountFilter",
minNumber = cms.uint32(1),
maxNumber = cms.uint32(999999),
src = cms.InputTag("tagProbesJPsi")
)
Esempio n. 4
0
process.patCandidates = cms.Sequence(process.makePatMuons +
                                     process.patCandidateSummary)
process.patDefaultSequence = cms.Sequence(process.patCandidates)

#--- Generic PAT tracks modules stolen from ElectroWeakAnalysis/Skimming/python ---#
process.patAODTrackCandsUnfiltered = cms.EDProducer(
    "ConcreteChargedCandidateProducer",
    src=cms.InputTag("generalTracks"),
    particleType=cms.string('mu+')  # to fix mass hypothesis
)
process.patAODTrackCands = cms.EDFilter(
    "CandViewSelector",
    src=cms.InputTag("patAODTrackCandsUnfiltered"),
    cut=cms.string('pt > 20'))
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles
process.allPatTracks = patGenericParticles.clone(
    src=cms.InputTag("patAODTrackCands"))
from PhysicsTools.PatAlgos.selectionLayer1.trackSelector_cfi import *
process.patTracksPt20 = selectedPatTracks.clone(cut='pt > 30.')

process.muFilter = cms.EDFilter(
    "MuFilter",
    muonTag=cms.InputTag("patMuons"),
    trackTag=cms.InputTag("patTracksPt20"),
    ebTag=cms.InputTag("correctedHybridSuperClusters"),
    eeTag=cms.InputTag("correctedMulti5x5SuperClustersWithPreshower"),
    minMuonPt=cms.double(35.0),
    minSCEt=cms.double(35.0),
    overlap=cms.double(0.05),
    trackPrescale=cms.int32(-1),
    trackOnly=cms.bool(False),
    trackMassLow=cms.double(40.0),
Esempio n. 5
0
process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
process.load('FWCore.MessageService.MessageLogger_cfi')
process.load('Configuration.EventContent.EventContent_cff')
process.load('Configuration.StandardSequences.GeometryRecoDB_cff')
process.load('Configuration.StandardSequences.MagneticField_AutoFromDBCurrent_cff')
process.load('Configuration.StandardSequences.EndOfProcess_cff')
process.load('Configuration.StandardSequences.FrontierConditions_GlobalTag_condDBv2_cff')
process.load("TrackingTools/TransientTrack/TransientTrackBuilder_cfi")

process.CandidateSelectedTracks = cms.EDProducer( "ConcreteChargedCandidateProducer",
                src=cms.InputTag("oniaSelectedTracks::RECO"),
                particleType=cms.string('pi+')
)

from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles
process.patSelectedTracks = patGenericParticles.clone(src=cms.InputTag("CandidateSelectedTracks"))

process.MessageLogger.cerr.FwkReport.reportEvery = 100

process.options = cms.untracked.PSet( wantSummary = cms.untracked.bool(True) )
process.options.allowUnscheduled = cms.untracked.bool(True)

process.source = cms.Source("PoolSource",fileNames = cms.untracked.vstring(
#
### use this to access the nearest copy of the input file, querying the catalog
#
   #'/store/data/Run2016E/Charmonium/USER/BPHSkim-PromptReco-v2/000/276/831/00000/00FD1519-714D-E611-B686-FA163E321AE0.root'
    'file:/home/ltsai/ReceivedFile/DATA/BPHSkim_Charmonium.root'
### use this to access the input file if by any reason you want to specify 
### the data server
#    'root://xrootd-cms.infn.it//store/data/Run2016E/Charmonium/USER/BPHSkim-PromptReco-v2/000/276/831/00000/00FD1519-714D-E611-B686-FA163E321AE0.root'
Esempio n. 6
0
 def toolCode(self, process):                
     label=self._parameters['label'].value
     input=self._parameters['input'].value
     selection=self._parameters['selection'].value
     isolation=self._parameters['isolation'].value
     isoDeposits=self._parameters['isoDeposits'].value
     mcAs=self._parameters['mcAs'].value
                                             
     ## add patTracks to the process
     from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles
     setattr(process, 'pat' + label, patGenericParticles.clone(src = input))
     ## add selectedPatTracks to the process
     setattr(process, 'selectedPat' + label, cms.EDFilter("PATGenericParticleSelector",
                                                          src = cms.InputTag("pat"+label),
                                                          cut = cms.string(selection) 
                                                          ) 
             )
     ## add cleanPatTracks to the process
     from PhysicsTools.PatAlgos.cleaningLayer1.genericTrackCleaner_cfi import cleanPatTracks
     setattr(process, 'cleanPat' + label, cleanPatTracks.clone(src = cms.InputTag('selectedPat' + label)))
     
     ## get them as variables, so we can put them in the sequences and/or configure them
     l1cands         = getattr(process, 'pat' + label)
     selectedL1cands = getattr(process, 'selectedPat' + label)
     cleanL1cands    = getattr(process, 'cleanPat' + label)
     
     ## insert them in sequence, after the electrons
     process.patCandidates.replace(process.patElectrons, l1cands + process.patElectrons)
     process.selectedPatCandidates.replace(process.selectedPatElectrons, process.selectedPatElectrons + selectedL1cands)
     process.cleanPatCandidates.replace(process.cleanPatElectrons, process.cleanPatElectrons + cleanL1cands)
 
     ## add them to the Summary Tables
     process.patCandidateSummary.candidates += [ cms.InputTag("allPat"+label) ]
     process.selectedPatCandidateSummary.candidates += [ cms.InputTag("selectedPat"+label) ]
     process.cleanPatCandidateSummary.candidates += [ cms.InputTag("cleanPat"+label) ]
 
     ## isolation: start with empty config
     if(isolation or isoDeposits):
         process.load("TrackPropagation.SteppingHelixPropagator.SteppingHelixPropagatorAlong_cfi")
         process.load("TrackPropagation.SteppingHelixPropagator.SteppingHelixPropagatorOpposite_cfi")
         process.load("TrackPropagation.SteppingHelixPropagator.SteppingHelixPropagatorAny_cfi")
     isoModules = []
     runIsoDeps = {'tracker':False, 'caloTowers':False}
 
     for source,deltaR in isolation.items():
         ## loop items in isolation
         if(source == 'tracker'):
             runIsoDeps['tracker'] = True
             l1cands.userIsolation.tracker = cms.PSet(
                 src    = cms.InputTag('pat'+label+'IsoDepositTracks'),
                 deltaR = cms.double(deltaR),
                 )
         elif(source == 'ecalTowers'):
             runIsoDeps['caloTowers'] = True
             l1cands.userIsolation.ecal = cms.PSet(
                 src    = cms.InputTag('pat'+label+'IsoDepositCaloTowers', 'ecal'),
                 deltaR = cms.double(deltaR),
                 )
         elif(source == 'hcalTowers'):
             runIsoDeps['caloTowers'] = True
             l1cands.userIsolation.hcal = cms.PSet(
                 src    = cms.InputTag('pat'+label+'IsoDepositCaloTowers', 'hcal'),
                 deltaR = cms.double(deltaR),
                 )
         
     for source in isoDeposits:
         ## loop items in isoDeposits
         if(source == 'tracker'):
             runIsoDeps['tracker'] = True
             l1cands.isoDeposits.tracker = cms.InputTag('pat'+label+'IsoDepositTracks') 
         elif(source == 'ecalTowers'):
             runIsoDeps['caloTowers'] = True
             l1cands.isoDeposits.ecal = cms.InputTag('pat'+label+'IsoDepositCaloTowers', 'ecal') 
         elif(source == 'hcalTowers'):
             runIsoDeps['caloTowers'] = True
             l1cands.isoDeposits.hcal = cms.InputTag('pat'+label+'IsoDepositCaloTowers', 'hcal')
         
     for dep in [ dep for dep,runme in runIsoDeps.items() if runme == True ]:
         if(dep == 'tracker'):
             from RecoMuon.MuonIsolationProducers.trackExtractorBlocks_cff import MIsoTrackExtractorCtfBlock
             setattr(process, 'pat'+label+'IsoDepositTracks',
                     cms.EDProducer("CandIsoDepositProducer",
                                    src                  = input,
                                    trackType            = cms.string('best'),
                                    MultipleDepositsFlag = cms.bool(False),
                                    ExtractorPSet        = cms.PSet( MIsoTrackExtractorCtfBlock )
                                    )
                     )
             isoModules.append( getattr(process, 'pat'+label+'IsoDepositTracks') )
         elif(dep == 'caloTowers'):
             from RecoMuon.MuonIsolationProducers.caloExtractorByAssociatorBlocks_cff import MIsoCaloExtractorByAssociatorTowersBlock
             setattr(process, 'pat'+label+'IsoDepositCaloTowers',
                     cms.EDProducer("CandIsoDepositProducer",
                                    src                  = input,
                                    trackType            = cms.string('best'),
                                    MultipleDepositsFlag = cms.bool(True),
                                    ExtractorPSet        = cms.PSet( MIsoCaloExtractorByAssociatorTowersBlock )
                                    )
                     )
             isoModules.append( getattr(process, 'pat'+label+'IsoDepositCaloTowers') )
     for m in isoModules:
         process.patDefaultSequence.replace(l1cands, m * l1cands)
     
     # MC
     from PhysicsTools.PatAlgos.tools.helpers import MassSearchParamVisitor
     if(type(mcAs) != type(None)):
         findMatch= []
         findMatch.append(getattr(process, mcAs+'Match'))
         
         ## clone mc matchiong module of object mcAs and add it to the path
         setattr(process, 'pat'+label+'MCMatch', findMatch[0].clone(src = input))
         process.patDefaultSequence.replace( l1cands, getattr(process, 'pat'+label+'MCMatch') * l1cands)
         l1cands.addGenMatch = True
         l1cands.genParticleMatch = cms.InputTag('pat'+label+'MCMatch')
Esempio n. 7
0
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles

allPatTracks = patGenericParticles.clone(
    src = cms.InputTag("patAODTrackCands"),
    embedTrack = cms.bool(True),
    # isolation configurables
    userIsolation = cms.PSet(
      tracker = cms.PSet(
        veto = cms.double(0.015),
        src = cms.InputTag("patAODTrackIsoDepositCtfTk"),
        deltaR = cms.double(0.3),
        threshold = cms.double(1.5)
      ),
      ecal = cms.PSet(
        src = cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers","ecal"),
        deltaR = cms.double(0.3)
      ),
      hcal = cms.PSet(
        src = cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers","hcal"),
        deltaR = cms.double(0.3)
      ),
    ),
    isoDeposits = cms.PSet(
      tracker = cms.InputTag("patAODTrackIsoDepositCtfTk"),
      ecal = cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers","ecal"),
      hcal = cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers","hcal")
    ),
    addGenMatch = cms.bool(False)
)

from PhysicsTools.PatAlgos.selectionLayer1.trackSelector_cfi import *
)


# sequence to run on AOD before PAT cleaners
process.patAODTrackCandSequence = cms.Sequence(
        process.patAODTrackCandsUnfiltered *
        process.patAODTrackCands 
)

#make track into pat::genericCnadidate
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles

process.allPatTracks = patGenericParticles.clone(
    src = cms.InputTag("patAODTrackCands"),
    # isolation configurables
    userIsolation = cms.PSet( ),
    isoDeposits = cms.PSet(  ),
    addGenMatch = cms.bool(False),
    genParticleMatch = cms.InputTag("trackMuMatch")
)

process.pfjetsNoTag  = cms.EDProducer("PATJetCleaner",
                                      src = cms.InputTag("patJetsCachedReClusterZPUL1Corr"),
                                      # preselection (any string-based cut for pat::Muon)
                                      preselection = cms.string(''),
                                      # overlap checking configurables
                                      checkOverlaps = cms.PSet(     muons = cms.PSet( src = cms.InputTag("tags"),
                                                                                                                algorithm = cms.string("byDeltaR"),
                                                                                      preselection        = cms.string(""),  # don't preselect the muons
                                                                                      deltaR              = cms.double(0.3),
                                                                                      checkRecoComponents = cms.bool(False), # don't check if they share some AOD object ref
                                                                                      pairCut             = cms.string(""),
Esempio n. 9
0
#------------------------------#
#--- Include Generic Tracks ---#
#------------------------------#
#--- Generic PAT tracks modules stolen from ElectroWeakAnalysis/Skimming/python ---#
process.patAODTrackCandsUnfiltered = cms.EDProducer("ConcreteChargedCandidateProducer",
    src          = cms.InputTag("generalTracks"),
    particleType = cms.string('mu+')   # to fix mass hypothesis
)
process.patAODTrackCands = cms.EDFilter("CandViewSelector",
    src = cms.InputTag("patAODTrackCandsUnfiltered"),
    cut = cms.string('pt > 20')
)
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles
process.allPatTracks = patGenericParticles.clone(
    src = cms.InputTag("patAODTrackCands")
)
from PhysicsTools.PatAlgos.selectionLayer1.trackSelector_cfi import *
process.patTracksPt30 = selectedPatTracks.clone(
    cut = 'pt > 30.'
)
process.patTrackSequence = cms.Sequence( 
        process.patAODTrackCandsUnfiltered *
        process.patAODTrackCands *
        process.allPatTracks *
        process.patTracksPt30
)

## ---- ##
## Btag ##
## ---- ##
# pat tracks
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles

allPatTracks = patGenericParticles.clone(
    src=cms.InputTag("patAODTrackCands"),
    # isolation configurables
    userIsolation=cms.PSet(
        tracker=cms.PSet(veto=cms.double(0.015),
                         src=cms.InputTag("patAODTrackIsoDepositCtfTk"),
                         deltaR=cms.double(0.3),
                         threshold=cms.double(1.5)),
        ecal=cms.PSet(src=cms.InputTag(
            "patAODTrackIsoDepositCalByAssociatorTowers", "ecal"),
                      deltaR=cms.double(0.3)),
        hcal=cms.PSet(src=cms.InputTag(
            "patAODTrackIsoDepositCalByAssociatorTowers", "hcal"),
                      deltaR=cms.double(0.3)),
    ),
    isoDeposits=cms.PSet(
        tracker=cms.InputTag("patAODTrackIsoDepositCtfTk"),
        ecal=cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers",
                          "ecal"),
        hcal=cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers",
                          "hcal")),
    addGenMatch=cms.bool(True),
    genParticleMatch=cms.InputTag("trackMuMatch"))

from PhysicsTools.PatAlgos.selectionLayer1.trackSelector_cfi import *
selectedPatTracks.cut = 'pt > 10.'
Esempio n. 11
0
        Chi2Ndof_Max = cms.double(1e+64),
        Pt_Min = cms.double(-1.0),
        DepositLabel = cms.untracked.string('tracker'),
        BeamlineOption = cms.string('BeamSpotFromEvent')
        )
                                )

###adding isodeposits to candidate collection
allPatTracksForPbPbZMuSkim = patGenericParticles.clone(
    src = cms.InputTag("ConcretelooseMuonsForPbPbZMuSkim"),
    # isolation configurables
    userIsolation = cms.PSet(
      tracker = cms.PSet(
        veto = cms.double(0.015),
        src = cms.InputTag("tkIsoDepositTkForPbPbZMuSkim"),
        deltaR = cms.double(0.3),
        #threshold = cms.double(1.5)
      ),
      ),
    isoDeposits = cms.PSet(
        tracker = cms.InputTag("tkIsoDepositTkForPbPbZMuSkim"),
        ),
    )




###create the "probe collection" of isolated tracks 
looseIsoMuonsForPbPbZMuSkim = cms.EDFilter("PATGenericParticleSelector",  
                             src = cms.InputTag("allPatTracksForPbPbZMuSkim"), 
                             cut = cms.string("(userIsolation('pat::TrackIso')/pt)<0.4"),
Esempio n. 12
0
##################################
#process.load('SimGeneral.HepPDTESSource.pythiapdt_cfi')
#process.load('TrackPropagation.SteppingHelixPropagator.SteppingHelixPropagatorAny_cfi')
#process.load('TrackingTools.TrackAssociator.DetIdAssociatorESProducer_cff')

process.patAODTrackCands = cms.EDFilter("CandViewSelector",
                                        src=cms.InputTag("patAODpatAODTrack"),
                                        cut=cms.string('abs(eta)<2.5'))

#make track into pat::genericCnadidate
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles

process.allPatTracks = patGenericParticles.clone(
    src=cms.InputTag("patAODTrackCands"),
    # isolation configurables
    userIsolation=cms.PSet(),
    isoDeposits=cms.PSet(),
    addGenMatch=cms.bool(False),
    genParticleMatch=cms.InputTag("trackMuMatch"))

#match to reco muons
process.passingprobestrack = cms.EDProducer(
    "PATGenericParticleCleaner",
    src=cms.InputTag("allPatTracks"),
    # preselection (any string-based cut for pat::Muon)
    preselection=cms.string(''),
    # overlap checking configurables
    checkOverlaps=jetOverlaps.clone(
        electrons=cms.PSet(
            src=cms.InputTag("EE"),
            algorithm=cms.string("byDeltaR"),
# pat tracks
from PhysicsTools.PatAlgos.producersLayer1.genericParticleProducer_cfi import patGenericParticles

allPatTracks = patGenericParticles.clone(
    src = cms.InputTag("patAODTrackCands"),
    # isolation configurables
    userIsolation = cms.PSet(
      tracker = cms.PSet(
        src = cms.InputTag("patAODTrackIsoDepositCtfTk"),
        deltaR = cms.double(0.3),
      ),
      ecal = cms.PSet(
        src = cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers","ecal"),
        deltaR = cms.double(0.3)
      ),
      hcal = cms.PSet(
        src = cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers","hcal"),
        deltaR = cms.double(0.3)
      ),
    ),
    isoDeposits = cms.PSet(
      tracker = cms.InputTag("patAODTrackIsoDepositCtfTk"),
      ecal = cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers","ecal"),
      hcal = cms.InputTag("patAODTrackIsoDepositCalByAssociatorTowers","hcal")
    ),
    addGenMatch = cms.bool(True),
    genParticleMatch = cms.InputTag("trackMuMatch")
)

from PhysicsTools.PatAlgos.selectionLayer1.trackSelector_cfi import *
selectedPatTracks.cut = 'pt > 10. & track.dxy()<1.0'
Esempio n. 14
0
        Diff_r=cms.double(0.1),
        Chi2Prob_Min=cms.double(-1.0),
        DR_Veto=cms.double(0.01),
        NHits_Min=cms.uint32(0),
        Chi2Ndof_Max=cms.double(1e+64),
        Pt_Min=cms.double(-1.0),
        DepositLabel=cms.untracked.string('tracker'),
        BeamlineOption=cms.string('BeamSpotFromEvent')))

###adding isodeposits to candidate collection
allPatTracks = patGenericParticles.clone(
    src=cms.InputTag("ConcretelooseMuonsForZMuSkim"),
    # isolation configurables
    userIsolation=cms.PSet(
        tracker=cms.PSet(
            veto=cms.double(0.015),
            src=cms.InputTag("tkIsoDepositTk"),
            deltaR=cms.double(0.3),
            #threshold = cms.double(1.5)
        ), ),
    isoDeposits=cms.PSet(tracker=cms.InputTag("tkIsoDepositTk"), ),
)

###create the "probe collection" of isolated tracks
looseIsoMuonsForZMuSkim = cms.EDFilter(
    "PATGenericParticleSelector",
    src=cms.InputTag("allPatTracks"),
    cut=cms.string("(userIsolation('pat::TrackIso')/pt)<0.4"),
    filter=cms.bool(True))

###create the "tag collection" of muon candidate, embedding the relevant infos
tightMuonsCandidateForZMuSkim = patMuons.clone(