Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-03-17 11:14:07

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 l1tVertexNTupler = cms.EDAnalyzer('VertexNTupler',
0004   inputDataInputTag = cms.InputTag("l1tInputDataProducer","InputData"),
0005   genParticleInputTag = cms.InputTag("genParticles",""),
0006   l1TracksInputTags    = cms.VInputTag( cms.InputTag("l1tTTTracksFromTrackletEmulation", "Level1TTTracks") ),
0007   l1TracksTruthMapInputTags = cms.VInputTag( cms.InputTag("TTTrackAssociatorFromPixelDigis", "Level1TTTracks") ),
0008   l1TracksTPInputTags = cms.InputTag("l1tTPStubValueMapProducer:allMatchedTPs"),
0009   l1TracksTPValueMapInputTags = cms.InputTag("l1tTPStubValueMapProducer:TPs"),
0010   l1TracksBranchNames  = cms.vstring('hybrid'),
0011   l1VertexInputTags   = cms.VInputTag( cms.InputTag("l1tVertexProducer", "l1vertices") ),
0012   l1VertexTrackInputs = cms.vstring('hybrid'),
0013   l1VertexBranchNames = cms.vstring('fastHisto'),
0014   emulationVertexInputTags = cms.VInputTag(),
0015   emulationVertexBranchNames = cms.vstring(),
0016   extraL1VertexInputTags = cms.VInputTag(),
0017   extraL1VertexDescriptions = cms.vstring(),
0018 
0019   genJetsInputTag = cms.InputTag("ak4GenJetsNoNu"),
0020 
0021   #=== Cuts on MC truth particles (i.e., tracking particles) used for tracking efficiency measurements.
0022   GenCuts = cms.PSet(
0023      GenMinPt         = cms.double(2.0),
0024      GenMaxAbsEta     = cms.double(2.4),
0025      GenMaxVertR      = cms.double(1.0), # Maximum distance of particle production vertex from centre of CMS.
0026      GenMaxVertZ      = cms.double(30.0),
0027      GenPdgIds        = cms.vuint32(), # Only particles with these PDG codes used for efficiency measurement.
0028 
0029 
0030      # Additional cut on MC truth tracks used for algorithmic tracking efficiency measurements.
0031      # You should usually set this equal to value of L1TrackDef.MinStubLayers below, unless L1TrackDef.MinPtToReduceLayers
0032      # is < 10000, in which case, set it equal to (L1TrackDef.MinStubLayers - 1).
0033      GenMinStubLayers = cms.uint32(4)
0034   ),
0035 
0036 
0037   #=== Rules for deciding when the track finding has found an L1 track candidate
0038   L1TrackDef = cms.PSet(
0039      UseLayerID           = cms.bool(True),
0040      # Reduce this layer ID, so that it takes no more than 8 different values in any eta region (simplifies firmware).
0041      ReducedLayerID       = cms.bool(True)
0042   ),
0043 
0044   #=== Rules for deciding when a reconstructed L1 track matches a MC truth particle (i.e. tracking particle).
0045   TrackMatchDef = cms.PSet(
0046      #--- Three different ways to define if a tracking particle matches a reco track candidate. (Usually, set two of them to ultra loose).
0047      # Min. fraction of matched stubs relative to number of stubs on reco track.
0048      MinFracMatchStubsOnReco  = cms.double(-99.),
0049      # Min. fraction of matched stubs relative to number of stubs on tracking particle.
0050      MinFracMatchStubsOnTP    = cms.double(-99.),
0051      # Min. number of matched layers.
0052      MinNumMatchLayers        = cms.uint32(4),
0053      # Min. number of matched PS layers.
0054      MinNumMatchPSLayers      = cms.uint32(0),
0055      # Associate stub to TP only if the TP contributed to both its clusters? (If False, then associate even if only one cluster was made by TP).
0056      StubMatchStrict          = cms.bool(False)
0057   ),
0058 
0059 
0060   # === Vertex Reconstruction configuration
0061   VertexReconstruction = cms.PSet(
0062     # Vertex Reconstruction Algorithm
0063     Algorithm = cms.string("fastHisto"),
0064     # Vertex distance [cm]
0065     VertexDistance = cms.double(.15),
0066     # Assumed Vertex Resolution [cm]
0067     VertexResolution = cms.double(.10),
0068     # Distance Type for agglomerative algorithm (0: MaxDistance, 1: MinDistance, 2: MeanDistance, 3: CentralDistance)
0069     DistanceType  = cms.uint32(0),
0070     # Minimum number of tracks to accept vertex
0071     MinTracks   = cms.uint32(2),
0072     # Compute the z0 position of the vertex with a mean weighted with track momenta
0073     #   0 = unweighted
0074     #   1 = pT weighted
0075     #   2 = pT^2 weighted
0076     WeightedMean = cms.uint32(1),
0077     # Chi2 cut for the Adaptive Vertex Reconstruction Algorithm
0078     AVR_chi2cut = cms.double(5.),
0079     # Do track quality cuts in emulation algorithms
0080     EM_DoQualityCuts = cms.bool(False),
0081     # Track-stubs Pt compatibility cut
0082     FH_DoPtComp = cms.bool(True),
0083     # chi2dof < 5 for tracks with Pt > 10
0084     FH_DoTightChi2 = cms.bool(False),
0085     # fastHisto algorithm histogram parameters (min,max,width) [cm]
0086     # TDR settings: [-14.95, 15.0, 0.1]
0087     # L1TkPrimaryVertexProducer: [-30.0, 30.0, 0.09983361065]
0088     # Firmware: [-14.4, 14.4, 0.4]
0089     FH_HistogramParameters = cms.vdouble(-30.0, 30.0, 0.09983361065),
0090     # The number of vertixes to return (i.e. N windows with the highest combined pT)
0091     FH_NVtx = cms.uint32(10),
0092     # fastHisto algorithm assumed vertex half-width [cm]
0093     FH_VertexWidth = cms.double(.15),
0094     # Window size of the sliding window
0095     FH_WindowSize = cms.uint32(3),
0096     # Kmeans number of iterations
0097     KmeansIterations = cms.uint32(10),
0098     # Kmeans number of clusters
0099     KmeansNumClusters  = cms.uint32(18),
0100     # DBSCAN pt threshold
0101     DBSCANPtThreshold = cms.double(4.),
0102     # DBSCAN min density tracks
0103     DBSCANMinDensityTracks = cms.uint32(2),
0104     # Minimum pt of tracks used to create vertex [GeV]
0105     VxMinTrackPt = cms.double(2.0),
0106     # Maximum pt of tracks used to create vertex [GeV]
0107     VxMaxTrackPt = cms.double(127.0),
0108     # When the track pt > VxMaxTrackPt, how should the tracks be considered
0109     #   -1 = tracks are valid
0110     #   0 = tracks are mismeasured and ignored/truncated
0111     #   1 = tracks are mismeasured and saturate at VxMaxTrackPt
0112     # Option '0' was used for the TDR, but '1' is used for the firmware
0113     VxMaxTrackPtBehavior = cms.int32(1),
0114     # Maximum chi2 of tracks used to create vertex
0115     VxMaxTrackChi2 = cms.double(100.),
0116     # Minimum number of stubs associated to a track
0117     VxMinNStub = cms.uint32(4),
0118     # Minimum number of stubs in PS modules associated to a track
0119     VxMinNStubPS = cms.uint32(3),
0120   ),
0121 
0122   # Debug printout
0123   debug  = cms.uint32(0),
0124   printResults = cms.bool(False)
0125 )