CMS 3D CMS Logo

phase2TrackerDigitizer_cfi.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 PixelDigitizerAlgorithmCommon = cms.PSet(
4  ElectronPerAdc = cms.double(1500.0),
5  ReadoutNoiseInElec = cms.double(-99.9), # not used at the moment
6  ThresholdInElectrons_Barrel = cms.double(1000.0),
7  ThresholdInElectrons_Endcap = cms.double(1000.0),
8  AddThresholdSmearing = cms.bool(False),
9  ThresholdSmearing_Barrel = cms.double(0.0),
10  ThresholdSmearing_Endcap = cms.double(0.0),
11  HIPThresholdInElectrons_Barrel = cms.double(1.0e10), # very high value to avoid Over threshold bit
12  HIPThresholdInElectrons_Endcap = cms.double(1.0e10), # very high value to avoid Over threshold bit
13  NoiseInElectrons = cms.double(0.0),
14  Phase2ReadoutMode = cms.int32(3), # Flag to decide Readout Mode :Digital(0) or Analog (linear TDR (-1), dual slope with slope parameters (+1,+2,+3,+4) with threshold subtraction
15  AdcFullScale = cms.int32(15),
16  TofUpperCut = cms.double(12.5),
17  TofLowerCut = cms.double(-12.5),
18  AddNoisyPixels = cms.bool(False),
19  Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described
20  AddNoise = cms.bool(False),
21  AddXTalk = cms.bool(False), #D.B.
22  InterstripCoupling = cms.double(0.0), #D.B. # No need to be used in PixelDigitizerAlgorithm
23  Odd_row_interchannelCoupling_next_row = cms.double(0.20),
24  Even_row_interchannelCoupling_next_row = cms.double(0.0),
25  Odd_column_interchannelCoupling_next_column = cms.double(0.0),
26  Even_column_interchannelCoupling_next_column = cms.double(0.0),
27  SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo
28  SigmaCoeff = cms.double(0), #S.D: setting SigmaCoeff=0 for IT-pixel
29  ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas)
30  LorentzAngle_DB = cms.bool(True),
31  TanLorentzAnglePerTesla_Endcap = cms.double(0.106),
32  TanLorentzAnglePerTesla_Barrel = cms.double(0.106),
33  KillModules = cms.bool(False),
34  DeadModules_DB = cms.bool(False),
35  DeadModules = cms.VPSet(),
36  AddInefficiency = cms.bool(False),
37  Inefficiency_DB = cms.bool(False),
38  UseReweighting = cms.bool(False),
39  EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ),
40  EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999,
41  0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on
42  CellsToKill = cms.VPSet(),
43  ApplyTimewalk = cms.bool(False),
44  TimewalkModel = cms.PSet(
45  ThresholdValues = cms.vdouble(1000, 1200, 1500, 3000),
46  Curves = cms.VPSet(
47  cms.PSet(
48  charge = cms.vdouble(1000, 1025, 1050, 1100, 1200, 1500, 2000, 6000, 10000, 15000, 20000, 30000),
49  delay = cms.vdouble(26.8, 23.73, 21.92, 19.46, 16.52, 12.15, 8.88, 3.03, 1.69, 0.95, 0.56, 0.19)
50  ),
51  cms.PSet(
52  charge = cms.vdouble(1200, 1225, 1250, 1500, 2000, 6000, 10000, 15000, 20000, 30000),
53  delay = cms.vdouble(26.28, 23.5, 21.79, 14.92, 10.27, 3.33, 1.86, 1.07, 0.66, 0.27)
54  ),
55  cms.PSet(
56  charge = cms.vdouble(1500, 1525, 1550, 1600, 2000, 6000, 10000, 15000, 20000, 30000),
57  delay = cms.vdouble(25.36, 23.05, 21.6, 19.56, 12.94, 3.79, 2.14, 1.26, 0.81, 0.39)
58  ),
59  cms.PSet(
60  charge = cms.vdouble(3000, 3025, 3050, 3100, 3500, 6000, 10000, 15000, 20000, 30000),
61  delay = cms.vdouble(25.63, 23.63, 22.35, 20.65, 14.92, 6.7, 3.68, 2.29, 1.62, 1.02)
62  )
63  )
64  )
65 )
66 phase2TrackerDigitizer = cms.PSet(
67 # For the Digitizer
68  accumulatorType = cms.string("Phase2TrackerDigitizer"),
69  hitsProducer = cms.string('g4SimHits'),
70  ROUList = cms.vstring(
71  'TrackerHitsPixelBarrelLowTof',
72  'TrackerHitsPixelBarrelHighTof',
73  'TrackerHitsPixelEndcapLowTof',
74  'TrackerHitsPixelEndcapHighTof'),
75  GeometryType = cms.string('idealForDigi'),
76  isOTreadoutAnalog = cms.bool(False),#set this to true if you want analog readout for OT
77 # Common for Algos
78  premixStage1 = cms.bool(False),
79  AlgorithmCommon = cms.PSet(
80  DeltaProductionCut = cms.double(0.03),
81  makeDigiSimLinks = cms.untracked.bool(True),
82  ),
83 # Specific parameters
84 #Pixel Digitizer Algorithm
85  PixelDigitizerAlgorithm = PixelDigitizerAlgorithmCommon.clone(
86  UseReweighting = cms.bool(False), # will be True for realistic simulations
87  ),
88 #Pixel-3D Digitizer Algorithm
89  Pixel3DDigitizerAlgorithm = PixelDigitizerAlgorithmCommon.clone(
90  SigmaCoeff = cms.double(1.80),
91  NPColumnRadius = cms.double(4.0),
92  OhmicColumnRadius = cms.double(4.0),
93  NPColumnGap = cms.double(46.0),
94  UseReweighting = cms.bool(False), # will be True for realistic simulations
95  ),
96 #Pixel in PS Module
97  PSPDigitizerAlgorithm = cms.PSet(
98  ElectronPerAdc = cms.double(135.0),
99  ReadoutNoiseInElec = cms.double(-99.9), # not used at the moment
100  ThresholdInElectrons_Barrel = cms.double(6300.), #(0.4 MIP = 0.4 * 16000 e)
101  ThresholdInElectrons_Endcap = cms.double(6300.), #(0.4 MIP = 0.4 * 16000 e)
102  AddThresholdSmearing = cms.bool(False),
103  ThresholdSmearing_Barrel = cms.double(630.0),
104  ThresholdSmearing_Endcap = cms.double(630.0),
105  HIPThresholdInElectrons_Barrel = cms.double(1.0e10), # very high value to avoid Over threshold bit
106  HIPThresholdInElectrons_Endcap = cms.double(1.0e10), # very high value to avoid Over threshold bit
107  NoiseInElectrons = cms.double(200), # 30% of the readout noise (should be changed in future)
108  Phase2ReadoutMode = cms.int32(0), # Flag to decide Readout Mode :Digital(0) or Analog (linear TDR (-1)), dual slope with slope parameters (+1,+2,+3,+4) with threshold subtraction
109  AdcFullScale = cms.int32(255),
110  TofUpperCut = cms.double(12.5),
111  TofLowerCut = cms.double(-12.5),
112  AddNoisyPixels = cms.bool(True),
113  Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described
114  AddNoise = cms.bool(True),
115  AddXTalk = cms.bool(True), #D.B.
116  InterstripCoupling = cms.double(0.05), #D.B.
117  SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo
118  SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X
119  ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas)
120  LorentzAngle_DB = cms.bool(True),
121  TanLorentzAnglePerTesla_Endcap = cms.double(0.07),
122  TanLorentzAnglePerTesla_Barrel = cms.double(0.07),
123  KillModules = cms.bool(False),
124  DeadModules_DB = cms.bool(False),
125  DeadModules = cms.VPSet(),
126  AddInefficiency = cms.bool(False),
127  Inefficiency_DB = cms.bool(False),
128  EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ),
129  EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999,
130  0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on
131  CellsToKill = cms.VPSet(),
132  BiasRailInefficiencyFlag = cms.int32(1), # Flag to decide BiasRail inefficiency : no inefficency(0) : inefficiency with optimistic(AND) scenario(1) : inefficiency with pessimistic(OR) scenario(2)
133  UseReweighting = cms.bool(False),
134  ),
135 #Strip in PS module
136  PSSDigitizerAlgorithm = cms.PSet(
137  ElectronPerAdc = cms.double(135.0),
138 #D.B.:the noise should be a function of strip capacitance, roughly: ReadoutNoiseInElec=500+(64*Cdet[pF]) ~= 500+(64*1.5[cm])
139  ReadoutNoiseInElec = cms.double(-99.9), # not used at the moment
140  ThresholdInElectrons_Barrel = cms.double(4800.), #(0.4 MIP = 0.4 * 16000 e)
141  ThresholdInElectrons_Endcap = cms.double(4800.), #(0.4 MIP = 0.4 * 16000 e)
142  AddThresholdSmearing = cms.bool(False),
143  ThresholdSmearing_Barrel = cms.double(480.0),
144  ThresholdSmearing_Endcap = cms.double(480.0),
145  HIPThresholdInElectrons_Barrel = cms.double(21000.), # 1.4 MIP considered as HIP
146  HIPThresholdInElectrons_Endcap = cms.double(21000.), # 1.4 MIP considered as HIP
147  NoiseInElectrons = cms.double(1010), # threshold = 4800e, noise=4800e/4.75=1010 (4.75 sigma=>occupancy =1e-6)
148  Phase2ReadoutMode = cms.int32(0), # Flag to decide Readout Mode :Digital(0) or Analog (linear TDR (-1)), dual slope with slope parameters (+1,+2,+3,+4) with threshold subtraction
149  AdcFullScale = cms.int32(255),
150  TofUpperCut = cms.double(12.5),
151  TofLowerCut = cms.double(-12.5),
152  AddNoisyPixels = cms.bool(True),
153  Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described
154  AddNoise = cms.bool(True),
155  AddXTalk = cms.bool(True), #D.B.
156  InterstripCoupling = cms.double(0.05), #D.B.
157  SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo
158  SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X
159  ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas)
160  LorentzAngle_DB = cms.bool(True),
161  TanLorentzAnglePerTesla_Endcap = cms.double(0.07),
162  TanLorentzAnglePerTesla_Barrel = cms.double(0.07),
163  KillModules = cms.bool(False),
164  DeadModules_DB = cms.bool(False),
165  DeadModules = cms.VPSet(),
166  AddInefficiency = cms.bool(False),
167  Inefficiency_DB = cms.bool(False),
168  EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ),
169  EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999,
170  0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on
171  CellsToKill = cms.VPSet(),
172  UseReweighting = cms.bool(False),
173  ),
174 #Two Strip Module
175  SSDigitizerAlgorithm = cms.PSet(
176  ElectronPerAdc = cms.double(135.0),
177 #D.B.:the noise should be a function of strip capacitance, roughly: ReadoutNoiseInElec=500+(64*Cdet[pF]) ~= 500+(64*1.5[cm])
178  ReadoutNoiseInElec = cms.double(-99.9), # not used at the moment
179  ThresholdInElectrons_Barrel = cms.double(6000.),
180  ThresholdInElectrons_Endcap = cms.double(6000.),
181  AddThresholdSmearing = cms.bool(False),
182  ThresholdSmearing_Barrel = cms.double(600.0),
183  ThresholdSmearing_Endcap = cms.double(600.0),
184  HIPThresholdInElectrons_Barrel = cms.double(1.0e10), # very high value to avoid Over threshold bit
185  HIPThresholdInElectrons_Endcap = cms.double(1.0e10), # very high value to avoid Over threshold bit
186  NoiseInElectrons = cms.double(1263), # threshold = 6000e, noise=6000e/4.75=1263e (4.75 sigma=>occupancy =1e-6)
187  Phase2ReadoutMode = cms.int32(0), # Flag to decide Readout Mode :Digital(0) or Analog (linear TDR (-1)), dual slope with slope parameters (+1,+2,+3,+4) with threshold subtraction
188  AdcFullScale = cms.int32(255),
189  TofUpperCut = cms.double(12.5),
190  TofLowerCut = cms.double(-12.5),
191  AddNoisyPixels = cms.bool(True),
192  Alpha2Order = cms.bool(True), #D.B.: second order effect, does not switch off magnetic field as described
193  AddNoise = cms.bool(True),
194  AddXTalk = cms.bool(True), #D.B.
195  InterstripCoupling = cms.double(0.05), #D.B.
196  SigmaZero = cms.double(0.00037), #D.B.: 3.7um spread for 300um-thick sensor, renormalized in digitizerAlgo
197  SigmaCoeff = cms.double(1.80), #D.B.: to be confirmed with simulations in CMSSW_6.X
198  ClusterWidth = cms.double(3), #D.B.: this is used as number of sigmas for charge collection (3=+-3sigmas)
199  LorentzAngle_DB = cms.bool(True),
200  TanLorentzAnglePerTesla_Endcap = cms.double(0.07),
201  TanLorentzAnglePerTesla_Barrel = cms.double(0.07),
202  KillModules = cms.bool(False),
203  DeadModules_DB = cms.bool(False),
204  DeadModules = cms.VPSet(),
205  AddInefficiency = cms.bool(False),
206  Inefficiency_DB = cms.bool(False),
207  EfficiencyFactors_Barrel = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999 ),
208  EfficiencyFactors_Endcap = cms.vdouble(0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999, 0.999,
209  0.999, 0.999 ),#Efficiencies kept as Side2Disk1,Side1Disk1 and so on
210  CellsToKill = cms.VPSet(),
211  HitDetectionMode = cms.int32(0), # (0/1/2/3/4 => SquareWindow/SampledMode/LatchedMode/SampledOrLachedMode/HIPFindingMode)
212  PulseShapeParameters = cms.vdouble(-3.0, 16.043703, 99.999857, 40.571650, 2.0, 1.2459094),
213  CBCDeadTime = cms.double(0.0), # (2.7 ns deadtime in latched mode)
214  UseReweighting = cms.bool(False),
215  )
216 )
217 
218 # For premixing stage1
219 # - add noise as by default
220 # - do not add noisy pixels (to be done in stage2)
221 # - do not apply inefficiency (to be done in stage2)
222 # - disable threshold smearing
223 #
224 # For outer tracker
225 # - force analog readout to get the ADCs
226 #
227 # NOTE: It is currently assumed that all sub-digitizers have the same ElectronPerAdc.
228 from Configuration.ProcessModifiers.premix_stage1_cff import premix_stage1
229 _premixStage1ModifyDict = dict(
230  premixStage1 = True,
231  PixelDigitizerAlgorithm = dict(
232  AddNoisyPixels = False,
233  AddInefficiency = False,
234  AddThresholdSmearing = False,
235  ),
236  Pixel3DDigitizerAlgorithm = dict(
237  AddNoisyPixels = False,
238  AddInefficiency = False,
239  AddThresholdSmearing = False,
240  ),
241  PSPDigitizerAlgorithm = dict(
242  AddNoisyPixels = False,
243  AddInefficiency = False,
244  AddThresholdSmearing = False,
245  ),
246  PSSDigitizerAlgorithm = dict(
247  AddNoisyPixels = False,
248  AddInefficiency = False,
249  AddThresholdSmearing = False,
250  Phase2ReadoutMode = -1,
251  ),
252  SSDigitizerAlgorithm = dict(
253  AddNoisyPixels = False,
254  AddInefficiency = False,
255  AddThresholdSmearing = False,
256  ),
257 )
258 
259 premix_stage1.toModify(phase2TrackerDigitizer, **_premixStage1ModifyDict)
260 
261 from Configuration.ProcessModifiers.enableXTalkInPhase2Pixel_cff import enableXTalkInPhase2Pixel
262 _enableXTalkInPhase2PixelModifyDict = dict(
263  PixelDigitizerAlgorithm = dict(
264  AddXTalk = True,
265  Odd_row_interchannelCoupling_next_row = 0.00,
266  Even_row_interchannelCoupling_next_row = 0.06
267  )
268 )
269 
270 enableXTalkInPhase2Pixel.toModify(phase2TrackerDigitizer, **_enableXTalkInPhase2PixelModifyDict)
271 
272 
273