Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:52:45

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 from Configuration.StandardSequences.Reconstruction_cff import *
0004 
0005 # muons with trigger info
0006 import PhysicsTools.PatAlgos.producersLayer1.muonProducer_cfi
0007 oniaPATMuonsWithoutTrigger = PhysicsTools.PatAlgos.producersLayer1.muonProducer_cfi.patMuons.clone(
0008     muonSource = 'muons',
0009     embedTrack          = True,
0010     embedCombinedMuon   = True,
0011     embedStandAloneMuon = True,
0012     embedPFCandidate    = False,
0013     embedCaloMETMuonCorrs = cms.bool(False),
0014     embedTcMETMuonCorrs   = cms.bool(False),
0015     embedPfEcalEnergy     = cms.bool(False),
0016     embedPickyMuon = False,
0017     embedTpfmsMuon = False, 
0018     userIsolation = cms.PSet(),   # no extra isolation beyond what's in reco::Muon itself
0019     isoDeposits = cms.PSet(),     # no heavy isodeposits
0020     addGenMatch = False,          # no mc
0021     addTriggerMatching = cms.bool(False)
0022 )
0023 
0024 oniaSelectedMuons = cms.EDFilter('PATMuonSelector',
0025    src = cms.InputTag('oniaPATMuonsWithoutTrigger'),
0026    cut = cms.string('muonID(\"TMOneStationTight\")'
0027                     ' && abs(innerTrack.dxy) < 0.3'
0028                     ' && abs(innerTrack.dz)  < 20.'
0029                     ' && innerTrack.hitPattern.trackerLayersWithMeasurement > 5'
0030                     ' && innerTrack.hitPattern.pixelLayersWithMeasurement > 0'
0031                     ' && innerTrack.quality(\"highPurity\")'
0032                     ' && ((abs(eta) <= 0.9 && pt > 2.5) || (0.9 < abs(eta) <= 2.4 && pt > 1.5))'
0033    ),
0034    filter = cms.bool(True)
0035 )
0036 
0037 # tracks
0038 oniaSelectedTracks=cms.EDFilter("TrackSelector",
0039      src = cms.InputTag("generalTracks"),
0040      cut = cms.string('pt > 0.7 && abs(eta) <= 3.0'
0041                       '&& charge !=0'
0042                       '&& quality(\"highPurity\")')     
0043 )
0044 
0045 # dimuon = Onia2MUMU
0046 from HeavyFlavorAnalysis.Onia2MuMu.onia2MuMuPAT_cfi import *
0047 onia2MuMuPAT.muons=cms.InputTag('oniaSelectedMuons')
0048 onia2MuMuPAT.primaryVertexTag=cms.InputTag('offlinePrimaryVertices')
0049 onia2MuMuPAT.beamSpotTag=cms.InputTag('offlineBeamSpot')
0050 onia2MuMuPAT.dimuonSelection=cms.string("0.2 < mass && abs(daughter('muon1').innerTrack.dz - daughter('muon2').innerTrack.dz) < 25")
0051 onia2MuMuPAT.addMCTruth = cms.bool(False)
0052 
0053 onia2MuMuPATCounter = cms.EDFilter('CandViewCountFilter',
0054       src = cms.InputTag('onia2MuMuPAT'),
0055       minNumber = cms.uint32(1),
0056    )
0057 
0058 # make photon candidate conversions for P-wave studies
0059 from HeavyFlavorAnalysis.Onia2MuMu.OniaPhotonConversionProducer_cfi import PhotonCandidates as oniaPhotonCandidates
0060 
0061 # add v0 with tracks embed
0062 from HeavyFlavorAnalysis.Onia2MuMu.OniaAddV0TracksProducer_cfi import *
0063 
0064 # Pick branches you want to keep
0065 BPHSkim_EventContent = cms.PSet(
0066      outputCommands = cms.untracked.vstring(
0067                      'drop *',
0068                      'keep recoVertexs_offlinePrimaryVertices_*_*',
0069                      'keep *_offlineBeamSpot_*_*',
0070                      'keep *_TriggerResults_*_HLT',
0071                      'keep *_hltGtStage2ObjectMap_*_HLT',
0072                      'keep *_hltTriggerSummaryAOD_*_HLT',
0073                      'keep *_gmtStage2Digis_Muon_RECO',
0074                      'keep *_gtDigis_*_RECO',
0075                      'keep *_oniaSelectedTracks_*_*',
0076                      'keep *_oniaPhotonCandidates_*_*',
0077                      'keep *_onia2MuMuPAT_*_*',
0078                      'keep *_oniaV0Tracks_*_*',
0079                      'keep PileupSummaryInfos_*_*_*'
0080      )
0081 )
0082 
0083 BPHSkimSequence = cms.Sequence(
0084             oniaPATMuonsWithoutTrigger *
0085         oniaSelectedMuons *
0086             onia2MuMuPAT *
0087         onia2MuMuPATCounter *
0088         oniaPhotonCandidates *
0089         oniaV0Tracks *
0090         oniaSelectedTracks
0091 )