Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:28:09

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 looseMTS = cms.PSet(
0004     preFilterName=cms.string(''),
0005     name= cms.string('TrkLoose'),                           
0006     
0007     # vertex selection 
0008     vtxNumber = cms.int32(-1),
0009     vertexCut = cms.string('ndof>=2&!isFake'),
0010     
0011     #untracked bool copyTrajectories = true // when doing retracking before
0012     copyTrajectories = cms.untracked.bool(False),
0013     copyExtras = cms.untracked.bool(True), ## set to false on AOD
0014     qualityBit = cms.string('loose'), ## set to '' or comment out if you dont want to set the bit
0015     
0016     # parameters for adapted optimal cuts on chi2 and primary vertex compatibility
0017     chi2n_par = cms.double(1.6),
0018     chi2n_no1Dmod_par = cms.double(9999),
0019     res_par = cms.vdouble(0.003, 0.01),
0020 #   second param is actually an int
0021     d0_par1 = cms.vdouble(0.55, 4.0),
0022     dz_par1 = cms.vdouble(0.65, 4.0),
0023     d0_par2 = cms.vdouble(0.55, 4.0),
0024     dz_par2 = cms.vdouble(0.45, 4.0),
0025     # Boolean indicating if adapted primary vertex compatibility cuts are to be applied.
0026     applyAdaptedPVCuts = cms.bool(True),
0027     
0028     # Impact parameter absolute cuts.
0029     max_d0 = cms.double(100.),
0030     max_z0 = cms.double(100.),
0031     nSigmaZ = cms.double(4.),
0032     
0033     # Cuts on numbers of layers with hits/3D hits/lost hits. 
0034     minNumberLayers = cms.uint32(0),
0035     minNumber3DLayers = cms.uint32(0),
0036     maxNumberLostLayers = cms.uint32(999),
0037     minHitsToBypassChecks = cms.uint32(20),
0038 
0039     # Absolute cuts in case of no PV. If yes, please define also max_d0NoPV and max_z0NoPV 
0040     applyAbsCutsIfNoPV = cms.bool(False),
0041     keepAllTracks= cms.bool(False),
0042 
0043     # parameters for cutting on pterror/pt and number of valid hits
0044     max_relpterr = cms.double(9999.),
0045     min_nhits = cms.uint32(0),
0046 
0047     max_minMissHitOutOrIn = cms.int32(99),
0048     max_lostHitFraction = cms.double(1.0),
0049 
0050     # parameters for cutting on eta
0051     min_eta = cms.double(-9999.),
0052     max_eta = cms.double(9999.)
0053 
0054     ) # end of pset
0055 
0056 tightMTS=looseMTS.clone(
0057     preFilterName='TrkLoose',
0058 #   second param is actually an int
0059     d0_par1 = [0.3, 4.0],
0060     dz_par1 = [0.35,4.0],
0061     d0_par2 = [0.4, 4.0],
0062     dz_par2 = [0.4, 4.0],
0063     chi2n_par = 0.7,
0064     chi2n_no1Dmod_par = 9999,
0065     name = 'TrkTight',
0066     minNumberLayers = 3,
0067     minNumber3DLayers = 3,
0068     maxNumberLostLayers = 2,
0069     qualityBit = 'tight', ## set to '' or comment out if you dont want to set the bit
0070     keepAllTracks= True
0071 )
0072 
0073 highpurityMTS= tightMTS.clone(
0074     name = 'TrkHighPurity',                           
0075     preFilterName = 'TrkTight',
0076     res_par = [0.003,0.001],
0077     qualityBit = 'highPurity' ## set to '' or comment out if you dont want to set the bit
0078 )
0079 
0080 #typical configuration is six selectors... something like this to
0081 #make cloning easier.
0082 multiTrackSelector = cms.EDProducer("MultiTrackSelector",
0083    src = cms.InputTag("generalTracks"),
0084    beamspot = cms.InputTag("offlineBeamSpot"),
0085    useVertices = cms.bool(True),
0086    useVtxError = cms.bool(False),
0087    vertices    = cms.InputTag("firstStepPrimaryVertices"),
0088    trackSelectors = cms.VPSet( looseMTS,
0089                                tightMTS,
0090                                highpurityMTS)
0091  ) 
0092 from Configuration.Eras.Modifier_trackingLowPU_cff import trackingLowPU
0093 trackingLowPU.toModify(multiTrackSelector,
0094     vertices = "pixelVertices"
0095 )