CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ALCARECOPromptCalibProdSiPixelAli_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 # ------------------------------------------------------------------------------
4 # configure a filter to run only on the events selected by TkAlMinBias AlcaReco
5 import copy
7 ALCARECOTkAlMinBiasFilterForSiPixelAli = copy.deepcopy(hltHighLevel)
8 ALCARECOTkAlMinBiasFilterForSiPixelAli.HLTPaths = ['pathALCARECOTkAlMinBias']
9 ALCARECOTkAlMinBiasFilterForSiPixelAli.throw = True ## dont throw on unknown path names
10 ALCARECOTkAlMinBiasFilterForSiPixelAli.TriggerResultsTag = cms.InputTag("TriggerResults","","RECO")
11 
13 
14 
15 # Ingredient: offlineBeamSpot
16 from RecoVertex.BeamSpotProducer.BeamSpot_cfi import offlineBeamSpot
17 
18 # Ingredient: AlignmentTrackSelector
19 # track selector for HighPurity tracks
20 #-- AlignmentTrackSelector
21 from Alignment.CommonAlignmentProducer.AlignmentTrackSelector_cfi import AlignmentTrackSelector
22 SiPixelAliHighPuritySelector = AlignmentTrackSelector.clone(
23  applyBasicCuts = True,
24  #filter = True,
25  src = 'ALCARECOTkAlMinBias',
26  trackQualities = ["highPurity"],
27  pMin = 4.,
28  )
29 
30 
31 
32 # track selection for alignment
33 from Alignment.CommonAlignmentProducer.AlignmentTrackSelector_cfi import AlignmentTrackSelector
34 SiPixelAliTrackSelector = AlignmentTrackSelector.clone(
35  src = 'SiPixelAliTrackFitter',
36  applyBasicCuts = True,
37  pMin = 8.,
38  ptMin = 1.0,
39  etaMin = -999.,
40  etaMax = 999.,
41  nHitMin = 8,
42  nHitMin2D = 2,
43  chi2nMax = 9999.,
44  applyMultiplicityFilter = False,
45  maxMultiplicity = 1,
46  applyNHighestPt = False,
47  nHighestPt = 1,
48  seedOnlyFrom = 0,
49  applyIsolationCut = False,
50  minHitIsolation = 0.8,
51  applyChargeCheck = False,
52  minHitChargeStrip = 30.,
53 )
54 #Special option for PCL
55 SiPixelAliTrackSelector.minHitsPerSubDet.inPIXEL = 2
56 
57 
58 # Ingredient: SiPixelAliTrackRefitter0
59 # refitting
63 # In the following use
64 # TrackRefitter (normal tracks), TrackRefitterP5 (cosmics) or TrackRefitterBHM (beam halo)
65 
66 SiPixelAliTrackRefitter0 = TrackRefitter.clone(
67  src = 'SiPixelAliHighPuritySelector', #'ALCARECOTkAlMinBias'#'ALCARECOTkAlCosmicsCTF0T' #'ALCARECOTkAlMuonIsolated'
68  NavigationSchool = '', # to avoid filling hit pattern
69  )
70 
71 SiPixelAliTrackRefitter1 = SiPixelAliTrackRefitter0.clone(
72  src = 'SiPixelAliTrackSelector'
73 )
74 
75 #-- Alignment producer
77 from Alignment.CommonAlignmentProducer.TrackerAlignmentProducerForPCL_cff import AlignmentProducer
78 SiPixelAliMilleAlignmentProducer = copy.deepcopy(AlignmentProducer)
79 SiPixelAliMilleAlignmentProducer.ParameterBuilder.Selector = cms.PSet(
80  alignParams = cms.vstring(
81  'TrackerTPBHalfBarrel,111111',
82  'TrackerTPEHalfCylinder,111111',
83 
84  'TrackerTIBHalfBarrel,ffffff',
85  'TrackerTOBHalfBarrel,ffffff',
86  'TrackerTIDEndcap,ffffff',
87  'TrackerTECEndcap,ffffff'
88  )
89  )
90 
91 SiPixelAliMilleAlignmentProducer.doMisalignmentScenario = False #True
92 
93 
94 SiPixelAliMilleAlignmentProducer.checkDbAlignmentValidity = False
95 SiPixelAliMilleAlignmentProducer.applyDbAlignment = True
96 SiPixelAliMilleAlignmentProducer.tjTkAssociationMapTag = 'SiPixelAliTrackRefitter1'
97 
98 SiPixelAliMilleAlignmentProducer.algoConfig = MillePedeAlignmentAlgorithm
99 SiPixelAliMilleAlignmentProducer.algoConfig.mode = 'mille'
100 SiPixelAliMilleAlignmentProducer.algoConfig.mergeBinaryFiles = cms.vstring()
101 SiPixelAliMilleAlignmentProducer.algoConfig.binaryFile = 'milleBinary_0.dat'
102 SiPixelAliMilleAlignmentProducer.algoConfig.TrajectoryFactory = cms.PSet(
103  #process.BrokenLinesBzeroTrajectoryFactory
104  BrokenLinesTrajectoryFactory
105  )
106 
107 
108 
109 
110 # Ingredient: SiPixelAliTrackerTrackHitFilter
112 # Reference config at /afs/cern.ch/cms/CAF/CMSALCA/ALCA_TRACKERALIGN/MP/MPproduction/aliConfigTemplates/Cosmics38T_BL_default_cfg.py
113 SiPixelAliTrackerTrackHitFilter = HitFilter.TrackerTrackHitFilter.clone(
114  src = 'SiPixelAliTrackRefitter0', #'ALCARECOTkAlCosmicsCTF0T',
115  # this is needed only if you require some selections; but it will work even if you don't ask for them
116  useTrajectories= True,
117  minimumHits = 8,
118  replaceWithInactiveHits = True,
119  rejectBadStoNHits = True,
120  commands = cms.vstring("keep PXB","keep PXE","keep TIB","keep TID","keep TOB","keep TEC"), #,"drop TID stereo","drop TEC stereo")
121  stripAllInvalidHits = False,
122  StoNcommands = cms.vstring("ALL 12.0"),
123  rejectLowAngleHits = True,
124  TrackAngleCut = 0.17, # in rads, starting from the module surface; .35 for cosmcics ok, .17 for collision tracks
125  usePixelQualityFlag = True #False
126  )
127 
128 # Ingredient: SiPixelAliSiPixelAliTrackFitter
130 SiPixelAliTrackFitter = fitWithMaterial.ctfWithMaterialTracks.clone(
131  src = 'SiPixelAliTrackerTrackHitFilter',
132  # TTRHBuilder = 'WithAngleAndTemplate', #should already be default
133  NavigationSchool = ''
134  )
135 
136 ### Ingredient: MillePedeFileConverter
137 ##from Alignment.CommonAlignmentProducer.MillePedeFileConverter_cfi import millePedeFileConverter
138 ### We configure the input file name of the millePedeFileConverter
139 ### with the output file name of the alignmentProducer (=looper).
140 ### Like this we are sure that they are well connected.
141 ##SiPixelAliMillePedeFileConverter = millePedeFileConverter.clone(
142 ## fileDir = looper.algoConfig.fileDir,
143 ## binaryFile = looper.algoConfig.binaryFile,
144 ## )
145 
146 SiPixelAliMillePedeFileConverter = cms.EDProducer("MillePedeFileConverter",
147  #FIXME: convert to untracked?
148  fileDir = cms.string(SiPixelAliMilleAlignmentProducer.algoConfig.fileDir.value()),
149  inputBinaryFile = cms.string(SiPixelAliMilleAlignmentProducer.algoConfig.binaryFile.value()),
150  #FIXME: why was the label removed? Don't we want a label?
151  fileBlobLabel = cms.string(''),
152  )
153 
154 
155 
156 seqALCARECOPromptCalibProdSiPixelAli = cms.Sequence(ALCARECOTkAlMinBiasFilterForSiPixelAli*
157  lsNumberFilter*
158  offlineBeamSpot*
159  SiPixelAliHighPuritySelector*
160  SiPixelAliTrackRefitter0*
161  SiPixelAliTrackerTrackHitFilter*
162  SiPixelAliTrackFitter*
163  SiPixelAliTrackSelector*
164  SiPixelAliTrackRefitter1*
165  SiPixelAliMilleAlignmentProducer*
166  SiPixelAliMillePedeFileConverter)
dont throw on unknown path names
dont throw on unknown path names