Ejemplo n.º 1
0
import PhysicsTools.PatAlgos.producersLayer1.muonProducer_cfi
process.patMuons = PhysicsTools.PatAlgos.producersLayer1.muonProducer_cfi.patMuons.clone(
    muonSource = 'arbMuons',
    embedTrack          = True,
    embedCombinedMuon   = True,
    embedStandAloneMuon = True,
    embedPickyMuon = False,
    embedTpfmsMuon = False, 
    userIsolation = cms.PSet(), # no extra isolation
    isoDeposits = cms.PSet(),   # no isodeposits
    addGenMatch = False,        # no mc
)

from MuonAnalysis.MuonAssociators.muonL1MatchExtended_cfi import addUserData as addMuonL1MatchExtended
addMuonL1MatchExtended(process.patMuons, addExtraInfo=True)

process.s = cms.Sequence(
    process.arbMuons +
    process.csctfDigis +
    process.muonL1MatchExtended +
    process.patMuons
)

process.p = cms.Path(
    process.s
)

process.o = cms.OutputModule("PoolOutputModule",
    fileName = cms.untracked.string("patMuons_L1MatcherExtended.root"),
    outputCommands = cms.untracked.vstring("drop *", "keep *_patMuons__*", "keep l1extraL1MuonParticles_l1extraParticles__*")
Ejemplo n.º 2
0
process.load("MuonAnalysis.MuonAssociators.muonL1MatchExtended_cfi")
import PhysicsTools.PatAlgos.producersLayer1.muonProducer_cfi
process.patMuons = PhysicsTools.PatAlgos.producersLayer1.muonProducer_cfi.patMuons.clone(
    muonSource = 'muons',
    embedTrack          = True,
    embedCombinedMuon   = True,
    embedStandAloneMuon = True,
    embedPickyMuon = False,
    embedTpfmsMuon = False, 
    userIsolation = cms.PSet(), # no extra isolation
    isoDeposits = cms.PSet(),   # no isodeposits
    addGenMatch = False,        # no mc
)

from MuonAnalysis.MuonAssociators.muonL1MatchExtended_cfi import addUserData as addMuonL1MatchExtended
addMuonL1MatchExtended(process.patMuons)

## Good Muons (very simplified selection)
process.mu4j = cms.EDFilter("PATMuonRefSelector", 
    src = cms.InputTag("patMuons"),
    cut = cms.string("muonID('TMLastStationAngTight')")
)
## Trigger matched
process.mu4jt  = process.mu4j.clone(cut = process.mu4j.cut.value() + " && userInt('muonL1MatchExtended') > 0");
## Trigger matched, geometrically
process.mu4jtg = process.mu4j.clone(cut = process.mu4j.cut.value() + " && userInt('muonL1MatchExtended') >= 10");

## Di-muons, all
process.dimu = cms.EDProducer("CandViewShallowCloneCombiner",
    decay = cms.string("mu4j@+ mu4j@-"),
    cut   = cms.string("mass > 2"),
process.load("MuonAnalysis.MuonAssociators.muonL1MatchExtended_cfi")
import PhysicsTools.PatAlgos.producersLayer1.muonProducer_cfi
process.patMuons = PhysicsTools.PatAlgos.producersLayer1.muonProducer_cfi.patMuons.clone(
    muonSource='muons',
    embedTrack=True,
    embedCombinedMuon=True,
    embedStandAloneMuon=True,
    embedPickyMuon=False,
    embedTpfmsMuon=False,
    userIsolation=cms.PSet(),  # no extra isolation
    isoDeposits=cms.PSet(),  # no isodeposits
    addGenMatch=False,  # no mc
)

from MuonAnalysis.MuonAssociators.muonL1MatchExtended_cfi import addUserData as addMuonL1MatchExtended
addMuonL1MatchExtended(process.patMuons)

## Good Muons (very simplified selection)
process.mu4j = cms.EDFilter("PATMuonRefSelector",
                            src=cms.InputTag("patMuons"),
                            cut=cms.string("muonID('TMLastStationAngTight')"))
## Trigger matched
process.mu4jt = process.mu4j.clone(cut=process.mu4j.cut.value() +
                                   " && userInt('muonL1MatchExtended') > 0")
## Trigger matched, geometrically
process.mu4jtg = process.mu4j.clone(cut=process.mu4j.cut.value() +
                                    " && userInt('muonL1MatchExtended') >= 10")

## Di-muons, all
process.dimu = cms.EDProducer(
    "CandViewShallowCloneCombiner",