Track Reconstruction in Fast Simulation

Complete: 4

Overview

In Fast Simulation, the track finding usually does not require the (very slow) pattern recognition step. Indeed, there is a unique association of each RecHit to a given simulated track, and the "pattern recognition" is made on this basis. While it allows the efficiency of the full reconstruction to be well reproduced, it does not allow any fake track to be created. It is therefore important that the track selection be such that it leads to a very small fake rate in the full reconstruction. This is the case for the "high purity" selection of the GeneralTracks collection resulting from the Iterative Tracking procedure. From CMSSW_2_0_0 all the configuration files use the python language. The examples in the following have been updated to this later version (the old is still accessible).

Seeding (from CMSSW_1_8_0 onwards)

In version 1_8_0 (and later versions) of CMSSW, the trajectory seeding (in TrajectorySeedProducer.cc) has been made generic so as to allow for as many seeding algorithms as possible (for example in the iterative tracking procedure), in contrast to the sole Global Pixel and Global Mixed seeding previously. The configuration file (TrajectorySeedProducer_cfi.py)contains tunable parameters as follows.

trajectorySeedProducer = cms.EDProducer("TrajectorySeedProducer",
 
    # The smallest number of layer crossed to create a track candidate
    minRecHits = cms.vuint32(5),
  
  # The smallest pT (true, in GeV/c) to create a track candidate 
    pTMin = cms.vdouble(0.9),
     
    # The smallest d0 and z0 (true, in cm) to create a track candidate
    maxD0 = cms.vdouble(1.0),
    maxZ0 = cms.vdouble(30.0),
    zVertexConstraint = cms.vdouble(-1.0),
  
  # The number of hits needed to make a seed
    numberOfHits = cms.vuint32(2),

    # Inputs: tracker rechits, beam spot position.
    HitProducer = cms.InputTag("siTrackerGaussianSmearingRecHits","TrackerGSMatchedRecHits"),
    beamSpot = cms.InputTag("offlineBeamSpot"),  
    seedingAlgo = cms.vstring('GlobalPixel'),     

    # The primary vertex collection
    primaryVertices = cms.VInputTag(cms.InputTag("none")),
       
 # The seed cuts for compatibility with originating from the beam axis.
    seedCleaning = cms.bool(True),
    originRadius = cms.vdouble(0.2),
    originHalfLength = cms.vdouble(15.9),
    originpTMin = cms.vdouble(1.0),

   # The possible subdetectors for the first, second and third  hit
    # No seed with more than three hits are foreseen, but the code can certainly be 
    # modified to include this possibility.
    # 1 = PXB, 2 = PXD, 3 = TIB, 4 = TID, 5 = TOB, 6 = TEC 
    firstHitSubDetectorNumber = cms.vuint32(2),
    firstHitSubDetectors = cms.vuint32(1, 2),
    secondHitSubDetectorNumber = cms.vuint32(2),
    secondHitSubDetectors = cms.vuint32(1, 2),
    thirdHitSubDetectorNumber = cms.vuint32(0),  
    thirdHitSubDetectors = cms.vuint32()
)

  • Old cfg instructions
More  Less 

module trajectorySeedProducer = TrajectorySeedProducer
{
    InputTag HitProducer = siTrackerGaussianSmearingRecHits
    
    # The smallest number of layer crossed to create a track candidate
    vuint32 minRecHits = {5}
    
    # The smallest pT (true, in GeV/c) to create a track candidate 
    vdouble pTMin = {0.9}
    
    # The smallest d0 and z0 (true, in cm) to create a track candidate
    vdouble maxD0 = {1.}
    vdouble maxZ0 = {30.}
    
    # The number of hits needed to make a seed
    vuint32 numberOfHits  = {2}

    # The possible subdetectors for the first, second and third  hit
    # No seed with more than three hits are foreseen, but the code can certainly be 
    # modified to include this possibility.
    # 1 = PXB, 2 = PXD, 3 = TIB, 4 = TID, 5 = TOB, 6 = TEC 
    vuint32 firstHitSubDetectorNumber = { 2 }
    vuint32 firstHitSubDetectors = {1,2}
    vuint32 secondHitSubDetectorNumber = { 2 }
    vuint32 secondHitSubDetectors = {1,2}
    vuint32 thirdHitSubDetectorNumber = {0}
    vuint32 thirdHitSubDetectors = {}
    
    vstring seedingAlgo      = {"GlobalPixel"}  
   
    # The seed cuts for compatibility with originating from the beam axis.
    bool   seedCleaning  = true
    vdouble originRadius = {0.2}
    vdouble originHalfLength = {15.9}
    vdouble originpTMin = {1.}
}

With this configuration, a single seeding algorithm is invoked (here the "GlobalPixel" seeding algorithm), in which only the simulated charged particles with a true pT larger than 900 MeV/c, originating from within a cylinder centred around the nominal interaction point, of radius 1cm and length 60cm, and associated to at least 5 RecHits, are considered. These simulated tracks are then required to have seeds consisting of pairs of recHits (numberOfHits = 2) belonging to that very simulated track, both of which could be from two different subdetectors (firstHitSubdetectorNumber and secondHitSubDetectorNumber), namely the pixel barrel and the pixel disks (firstHitSubDetetectors and secondHitSubDetectors). An emulation of the seeding is then made for each of these charged particles by requiring that at least one seeding pair, when forced to originate from within a cylinder or radius originRadius (here 2 mm), corresponds to a transverse momentum in excess of originpTMin (here 1 GeV/c) and a z0 smaller than 15.9 cm.

The configurable variables being put in vectors, it is possible to invoke more than one seeding algorithm in a row. For example, the first step of the iterative tracking consists of two sub-step mutually exclusive that use two different seeding strategies. The example is as follows:

import FastSimulation.Tracking.TrajectorySeedProducer_cfi
iterativeFirstSeeds = FastSimulation.Tracking.TrajectorySeedProducer_cfi.trajectorySeedProducer.clone()
iterativeFirstSeeds.firstHitSubDetectorNumber = [1, 2]
iterativeFirstSeeds.firstHitSubDetectors = [1, 1, 2]
iterativeFirstSeeds.secondHitSubDetectorNumber = [2, 3]
iterativeFirstSeeds.secondHitSubDetectors = [1, 2, 1, 2, 6]
iterativeFirstSeeds.thirdHitSubDetectorNumber = [2, 0]
iterativeFirstSeeds.thirdHitSubDetectors = [1, 2]
iterativeFirstSeeds.seedingAlgo = ['FirstPixelTriplets', 'FirstMixedPairs']
iterativeFirstSeeds.minRecHits = [3, 3]
iterativeFirstSeeds.pTMin = [0.35, 0.35]
iterativeFirstSeeds.maxD0 = [1., 1.]
iterativeFirstSeeds.maxZ0 = [30., 30.]
iterativeFirstSeeds.numberOfHits = [3, 2]
iterativeFirstSeeds.originRadius = [0.2, 0.2]
iterativeFirstSeeds.originHalfLength = [15.9, 15.9]
iterativeFirstSeeds.originpTMin = [0.5, 0.9]
iterativeFirstSeeds.zVertexConstraint = [-1.0, 0.4]
iterativeFirstSeeds.primaryVertices = ['none', 'pixelVertices']
  • Old cfg instructions
More  Less 

module iterativeTrackingGSSeeds = trajectorySeedProducer from "FastSimulation/Tracking/data/TrajectorySeedProducer.cfi"

replace iterativeTrackingGSSeeds.firstHitSubDetectorNumber = { 2, 2, 3, 3}
replace iterativeTrackingGSSeeds.firstHitSubDetectors = { 1,2, 1,2, 1,2,6, 1,2,6 }
replace iterativeTrackingGSSeeds.secondHitSubDetectorNumber = { 2, 2, 3, 3 }
replace iterativeTrackingGSSeeds.secondHitSubDetectors = { 1,2, 1,2, 1,2,6, 1,2,6 }
replace iterativeTrackingGSSeeds.thirdHitSubDetectorNumber = { 2, 2, 0, 0 }
replace iterativeTrackingGSSeeds.thirdHitSubDetectors = { 1,2, 1,2 }
replace iterativeTrackingGSSeeds.seedingAlgo      = {"FirstTriplets", "SecondTriplets", "ThirdMixed", "FourthMixed"} 
replace iterativeTrackingGSSeeds.minRecHits = {5,4,5,3}
replace iterativeTrackingGSSeeds.pTMin = {0.9,0.5,0.5,0.3}
replace iterativeTrackingGSSeeds.maxD0 = {1.,1.,1.,1.}
replace iterativeTrackingGSSeeds.maxZ0 = {30.,30.,30.,30.}
replace iterativeTrackingGSSeeds.numberOfHits  = {3, 3, 2, 2}
replace iterativeTrackingGSSeeds.originRadius = {0.2, 0.2, 0.2, 0.2}
replace iterativeTrackingGSSeeds.originHalfLength = {15.9, 15.9, 15.9, 15.9}
replace iterativeTrackingGSSeeds.originpTMin = {0.9, 0.5, 0.5, 0.3}

The number of hits requested to create a seed are 3, 3, 2 and 2 in each of the four steps. The triplets are made of hits coming from the pixel detector (barrel or disks), while the pairs may also contain hits from the TEC layers (enforced in the code to be in one of the first three layers, and in one of the first two inner rings). At least 5, 4, 5 and 3 tracker layers have to be crossed by tracks, and the pT is required to be in excess of 900, 500, 500, and 300 MeV/c, respectively. The output of the producer consists of four collections of TrajectorySeed's, labelled "FirstTriplets", "SecondTriplets", "ThirdMixed", "FourthMixed", respectively.

The number of hits requested to create a seed are 3 and 2 in each of the two steps (0 and 1) of the First Iterative Step. In release CMSSW_3_1_X there are five iterative steps. The seeding algorithm names used in the FastSimulation are: 'FirstPixelTriplets', 'FirstMixedPairs', 'SecondPixelTriplets', 'ThirdMixedPairs', 'FourthPixellessPairs',"TobTecLayerPairs'.

Track Candidates

From CMSSW_1_8_0 onwards

The Track Candidate producer (TrackCandidateProducer.cc) starts from the seed collection produced as described above, and associate to each seed all the RecHit's belonging to the same simulated track found from the seeding RecHits towards the outside of the tracker. A track candidate is made of this vector of TrackingRecHit's and of the true momentum/vertex/charge of the simulated particle, taken as the initial state for the later fitting of the track parameters. (See section Tracking below.)

The default configuration file (TrackCandidateProducer_cfi.py) looks as follows.

trackCandidateProducer = cms.EDProducer("TrackCandidateProducer",
    HitProducer = cms.InputTag("siTrackerGaussianSmearingRecHits","TrackerGSMatchedRecHits"),
    # The smallest number of crossed layers to make a candidate
    MinNumberOfCrossedLayers = cms.uint32(5),
    # The number of crossed layers needed before stopping tracking
    MaxNumberOfCrossedLayers = cms.uint32(999),
    SeedProducer = cms.InputTag("globalPixelSeeds","GlobalPixel"),
    # If true, keep the tracks fitted in the previous collection
    # Just ignore them otherwise
    KeepFittedTracks = cms.bool(True),
    # Reject overlapping hits? (GroupedTracking from 170pre2 onwards)
    OverlapCleaning = cms.bool(False),
    # Reject copies of tracks from several seeds - take the first seed in that case
    SeedCleaning = cms.bool(True),
    # The tracks already fitted - no need to fit them already !
    TrackProducers = cms.VInputTag(cms.InputTag("generalTracks")),
    # Split matched hits? 
    SplitHits = cms.bool(True)
)

  • Old cfg instructions
More  Less 

module trackCandidateProducer = TrackCandidateProducer
{   
    InputTag HitProducer = siTrackerGaussianSmearingRecHits

    InputTag SeedProducer = globalPixelGSSeeds:GlobalPixel

    # The smallest number of crossed layers to make a candidate
    uint32 MinNumberOfCrossedLayers = 5

    InputTag TrackProducer = ctfGSWithMaterialTracks
    
    # Reject overlapping hits? (GroupedTracking from 170pre2 onwards)
    bool overlapCleaning = false
}

While the name of the HitProducer and of the SeedProducer (here the default GlobalPixel seed producer) are the self-explanatory inputs to the producers (hits and seeds), the other parameters deserve more explanations. The MinNumberOfCrossedLayers parameter is the smallest number of layers crossed by the simulated track, from the first seeding hit onwards (hence might be tighter than the cut applied at the seeding level). When set to true, the overlapCleaning parameters retains only one hit per layer (namely, the best hit in terms of errors on its position), instead of allowing several hits arising from overlapping modules.

Finally, the TrackProducer is the most mysterious of the parameters, and deserves even more explanations. Imagine that the default CTF tracking has already been run (as an input, for example, to b tagging), and that you want to run the iterative tracking (as an input, for example, to the particle flow). About 80% of the tracks found by the iterative tracking are actually found by the default CTF tracking, and it would be a pity (i.e., a waste of CPU time) to fit their parameter twice from their RecHit's. For this reason, the tracks that are found by the iterative tracking, but were already fit by the CTF tracking (a Track Producer with name ctfGSWithMaterialTracks) are simply stored in a temporary track collection, and are merged later to the new tracks found by the iterative tracking. It goes without saying that, if the CTF TrackProducer was not run prior to the iterative tracking, all track candidates will be created and available for a later track fitting.

An example for the second step of the iterative track candidate search can be found in IterativeSecondCandidateProducer_cff.py under the following form:

import FastSimulation.Tracking.TrackCandidateProducer_cfi
iterativeSecondTrackCandidatesWithTriplets = FastSimulation.Tracking.TrackCandidateProducer_cfi.trackCandidateProducer.clone()
iterativeSecondTrackCandidates = cms.Sequence(iterativeSecondTrackCandidatesWithTriplets)
iterativeSecondTrackCandidatesWithTriplets.SeedProducer = cms.InputTag("iterativeSecondSeeds","SecondPixelTriplets")
iterativeSecondTrackCandidatesWithTriplets.TrackProducers = ['firstfilter']
iterativeSecondTrackCandidatesWithTriplets.KeepFittedTracks = False
iterativeSecondTrackCandidatesWithTriplets.MinNumberOfCrossedLayers = 3

  • Old cfg instructions
More  Less 

module secondGSTrackCandidates = trackCandidateProducer from "FastSimulation/Tracking/data/TrackCandidateProducer.cfi"

replace secondGSTrackCandidates.SeedProducer = iterativeTrackingGSSeeds:SecondTriplets
replace secondGSTrackCandidates.MinNumberOfCrossedLayers = 4

Before CMSSW_1_8_0

In an earlier version, the track-candidate maker GSTrackCandidateMaker was doing seeding (GlobalPixel and GlobalMixed only) and production of Track Candidate in a single pass, which was making the code much less modular, hence much less generic. It therefore merges configurable parameters of both the seeding and the candidating. The configuration file that contains tunable parameters is as follows.

module gsTrackCandidates = GSTrackCandidateMaker
{   

    string HitProducer = "siTrackerGaussianSmearingRecHits"
    
    # The smallest number of hits to create a track candidate
    uint32 MinRecHits = 5
    
    # The smallest pT (true, in GeV/c) to create a track candidate 
    double pTMin = 0.8
    
    # The smallest d0 and z0 (true, in cm) to create a track candidate
    double MaxD0 = 1.
    double MaxZ0 = 30.
    
    # Seed cleaning ?
    bool   seedCleaning  = true
    string seedType      = "GlobalMixed"  // Alternative is "GlobalPixel"
    // Any other name will turn off the seed cleaning.
   
    # The seed cuts for compatibility with originating from the beam axis.
    double originRadius = 0.2
    double originHalfLength = 15.
    double originpTMin = 1.
    
}

With this configuration file, only the simulated charged particles with a true pT larger than 800 MeV/c, originating from within a cylinder centred around the nominal interaction point, of radius 1cm and length 60cm, and associated to at least 5 RecHits, are considered for being track candidates. An emulation of the seeding (either from Pixel RecHits, called GlobalPixel seeding, or, by default, from Pixel + TID + TEC RecHits, called GlobalMixed seeding) is then made, requiring that at least one pair of these RecHits, when fit to a track of momentum equal to either originpTMin or 1000 times this value, has this track originate from within a cylinder centred around the nominal interaction point, and of radius 0.2cm and length 30cm.

The surviving candidates are then assigned all the RecHit's (under the form of TrackingHit) associated to the original SimTrack, and are written to the event under the form of a TrackCandidateSelection for later fitting. (See section Tracking below.)

Full pattern recognition option

Alternatively, the full pattern recognition sequence may be used. While it is substantially slower than the fast reconstruction, it allows detailed studies (and detailed tuning) to be performed. More details can be found here

Tracking

Default CTF tracking

The tracking sequences include seeding, track candidate making and track fitting. The latter use the normal, full reconstruction, fitting algorithm. For example, the default CTF tracking is dealt with with the following configuration file (CTFDefaultTracking.cff):

# Global Mixed seeding
include "FastSimulation/Tracking/data/GlobalMixedSeedProducer.cff"

# TrackCandidates
module ctfGSTrackCandidates = trackCandidateProducer from "FastSimulation/Tracking/data/TrackCandidateProducer.cfi"
replace ctfGSTrackCandidates.SeedProducer = globalMixedGSSeeds:GlobalMixed

# reco::Tracks
module ctfGSWithMaterialTracks = ctfWithMaterialTracks from "RecoTracker/TrackProducer/data/CTFFinalFitWithMaterial.cfi"
replace  ctfGSWithMaterialTracks.src ="ctfGSTrackCandidates"   
replace ctfGSWithMaterialTracks.TTRHBuilder = "WithoutRefit"

# The sequence
sequence ctfGSTracking = {
    globalMixedGSSeeds,
    ctfGSTrackCandidates,
    ctfGSWithMaterialTracks
}
in which global mixed seeding is applied, default track candidate making from these seeds is performed, and normal fit is run, to produce a reco::Track collection named ctfGSWithMaterialTracks.

Iterative tracking

The iterative tracking sequence is a little more complex (CMS.IterativeTracking.cff) and amounts to

include "FastSimulation/Tracking/data/PixelTracksProducer.cff"
include "FastSimulation/Tracking/data/PixelVerticesProducer.cff"
include "FastSimulation/Tracking/data/IterativeTrackingSeedProducer.cff"
include "FastSimulation/Tracking/data/IterativeCandidateProducer.cff"
include "FastSimulation/Tracking/data/IterativeTrackProducer.cff"
include "FastSimulation/Tracking/data/IterativeVertexFilter.cff"
include "FastSimulation/Tracking/data/IterativeTracks.cfi"

sequence iterativeGSTracking = {
    pixelGSTracking,
    pixelGSVertexing,
    iterativeTrackingGSSeeds,
    iterativeGSTrackCandidates,
    iterativeGSTrackReco,
    iterativeGSVertexFilter,
    iterativeGSMerger,
    iterativeGSWithMaterialTracks
}
with pixel tracks and pixel vertices creation (use for later track filtering), the four-step seeding described above, the track candidates made for each of the four step, the track fitting for each of the four steps, the track filtering with conditions on their origin (compared to pixel vertices) for each of the four steps, and the track merging into a single collection named iterativeGSWithMaterialTracks.

Pixel tracking and vertexing

The pixel tracking is yet another tracking (used at HLT, in particular), where the tracks are made of only three hits, all of them belonging to the original pixel triplet seed (as the one used in the iterative tracking 1st and 2nd steps). The configuration file would be as follows. (The reader should feel free to go and look at the detailed implementation.)

include "FastSimulation/Tracking/data/PixelTripletSeedProducer.cff"
include "FastSimulation/Tracking/data/PixelTracksProducer.cfi"

sequence pixelGSTracking = { 
    pixelTripletGSSeeds,
    pixelGSTracks
}

Pixel vertices are then made from these tracks with the exact same procedure used in the full reconstruction.

Review status

Reviewer/Editor and Date (copy from screen) Comments
PatriziaAzzi - 07 May 2009 Update for 31X and py
PatrickJanot - 12 December 2007 Add seeding, track candidate and tracking documentation in 18X
PatrickJanot - 18 June 2007 Start the documentation writing
JennyWilliams - 01 May 2007 created template page

Responsible: PatriziaAzzi
Last reviewed by: Reviewer

Edit | Attach | Watch | Print version | History: r12 < r11 < r10 < r9 < r8 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r12 - 2009-08-27 - PatriziaAzzi



 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    CMSPublic All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback