CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Calorimetry_cff.py
Go to the documentation of this file.
2 
3 # This is used to modify parameters for Run 2 (see bottom of file)
4 from Configuration.StandardSequences.Eras import eras
5 
6 #Global fast calorimetry parameters
9 #from FastSimulation.Configuration.CommonInputs_cff import *
10 FamosCalorimetryBlock = cms.PSet(
11  Calorimetry = cms.PSet(
12  HSParameterBlock,
13  HCALResponseBlock,
14  ECAL = cms.PSet(
15  # See FastSimulation/CaloRecHitsProducer/python/CaloRecHits_cff.py
16  Digitizer = cms.untracked.bool(False),
17  # If set to true the simulation in ECAL would be done 1X0 by 1X0
18  # this is slow but more adapted to detailed studies.
19  # Otherwise roughty 5 steps are used.
20  bFixedLength = cms.bool(False),
21 
22  # For the core 10% of the spots for
23  CoreIntervals = cms.vdouble(100.0, 0.1),
24  # change the radius of the tail of the shower
25  RTFactor = cms.double(1.0),
26  # change the radius of the core of the shower
27  RCFactor = cms.double(1.0),
28  # For the tail 10% of r<1RM. 100% otherwise
29  TailIntervals = cms.vdouble(1.0, 0.1, 100.0, 1.0),
30  FrontLeakageProbability = cms.double(1.0),
31  GridSize = cms.int32(7),
32  # change globally the Moliere radius
33 
34 
35  ### changed after tuning - Feb - July - Shilpi Jain
36  #RadiusFactor = cms.double(1.096),
37  RadiusFactorEB = cms.double(1.096),
38  RadiusFactorEE = cms.double(1.25),
39  ### changed after tuning - Feb - July - Shilpi Jain
40 
41  RadiusPreshowerCorrections = cms.vdouble(0.137, 10.3), # default value for maxshower depth dependence-->works fine
42  MipsinGeV = cms.vdouble(0.0001421,0.0000812), # increase in mipsinGeV by 75% only in layer1
43  #SpotFraction < 0 <=> deactivated. In the case, CoreIntervals and
44  #TailIntervals are used
45  SpotFraction = cms.double(-1.0),
46  GapLossProbability = cms.double(0.9),
47  SimulatePreshower = cms.bool(True)
48  ),
49  ForwardCalorimeterProperties = cms.PSet(
50  HadronicCalorimeterProperties= cms.PSet(
51  HCAL_Sampling = cms.double(0.0035),
52  # Watch out ! The following two values are defined wrt the electron shower simulation
53  # There are not directly related to the detector properties
54  HCAL_PiOverE = cms.double(0.2),
55  # HCAL_PiOverE = cms.double(0.4)
56  HCALAeff= cms.double(55.845),
57  HCALZeff= cms.double(26),
58  HCALrho= cms.double(7.87),
59 
60  HCALradiationLengthIncm= cms.double(1.757),
61  HCALradLenIngcm2= cms.double(13.84),
62  HCALmoliereRadius= cms.double(1.719),
63  HCALcriticalEnergy= cms.double(21E-3),
64  HCALinteractionLength= cms.double(16.77),
65 
66  HCALetatow=cms.vdouble( 0.000, 0.087, 0.174, 0.261, 0.348, 0.435, 0.522, 0.609, 0.696, 0.783, 0.870, 0.957, 1.044, 1.131, 1.218, 1.305, 1.392, 1.479, 1.566, 1.653, 1.740, 1.830, 1.930, 2.043, 2.172, 2.322, 2.500, 2.650, 2.853, 3.000, 3.139, 3.314, 3.489, 3.664, 3.839, 4.013, 4.191, 4.363, 4.538, 4.716, 4.889, 5.191),
67 # HCALDepthLam=cms.vdouble( 8.930, 9.001, 9.132, 8.912, 8.104, 8.571, 8.852, 9.230, 9.732, 10.29, 10.95, 11.68, 12.49, 12.57, 12.63, 6.449, 5.806, 8.973, 8.934, 8.823, 8.727, 8.641, 8.565, 8.496, 8.436, 8.383, 8.346, 8.307, 8.298, 8.281, 9.442, 9.437, 9.432, 9.429, 9.432, 9.433, 9.430, 9.437, 9.442, 9.446, 9.435)
68  HCALDepthLam=cms.vdouble(8.014, 8.078, 8.195, 7.998, 7.273, 7.692, 7.944, 8.283, 8.734, 9.235, 9.827, 10.482, 11.209, 11.281, 11.335, 5.788, 5.211, 8.053, 8.018, 7.918, 7.832, 7.755, 7.687, 7.625, 7.571, 7.523, 7.490, 7.455, 7.447, 7.432, 8.474, 8.469, 8.465, 8.462, 8.465, 8.466, 8.463, 8.469, 8.474, 8.477, 8.467)
69  ),
70  ),
71  CalorimeterProperties = cms.PSet(
72  # triplet for each p value: p, k_e(p), k_h(p) ...
73  RespCorrP = cms.vdouble(1.0, 1.0, 1.0, 1000.0, 1.0, 1.0),
74  PreshowerLayer2_thickness = cms.double(0.38), # layer2 thickness back to original
75  ECALEndcap_LightCollection = cms.double(0.023),
76  PreshowerLayer1_thickness = cms.double(1.65), # increase in thickness of layer 1 by 3%
77  PreshowerLayer1_mipsPerGeV = cms.double(17.85), # 50% decrease in mipsperGeV
78  PreshowerLayer2_mipsPerGeV = cms.double(59.5),
79  ECALBarrel_LightCollection = cms.double(0.03),
80  HadronicCalorimeterProperties= cms.PSet(
81  HCAL_Sampling = cms.double(0.0035),
82  # Watch out ! The following two values are defined wrt the electron shower simulation
83  # There are not directly related to the detector properties
84  HCAL_PiOverE = cms.double(0.2),
85  # HCAL_PiOverE = cms.double(0.4)
86  HCALAeff= cms.double(63.546),
87  HCALZeff= cms.double(29.),
88  HCALrho= cms.double(8.960),
89 
90  HCALradiationLengthIncm= cms.double(1.43),
91  HCALradLenIngcm2= cms.double(12.86),
92  HCALmoliereRadius= cms.double(1.712),
93  HCALcriticalEnergy= cms.double(18.63E-3),
94  HCALinteractionLength= cms.double(15.05),
95 
96  HCALetatow=cms.vdouble( 0.000, 0.087, 0.174, 0.261, 0.348, 0.435, 0.522, 0.609, 0.696, 0.783, 0.870, 0.957, 1.044, 1.131, 1.218, 1.305, 1.392, 1.479, 1.566, 1.653, 1.740, 1.830, 1.930, 2.043, 2.172, 2.322, 2.500, 2.650, 2.853, 3.000, 3.139, 3.314, 3.489, 3.664, 3.839, 4.013, 4.191, 4.363, 4.538, 4.716, 4.889, 5.191),
97  HCALDepthLam=cms.vdouble( 8.930, 9.001, 9.132, 8.912, 8.104, 8.571, 8.852, 9.230, 9.732, 10.29, 10.95, 11.68, 12.49, 12.57, 12.63, 6.449, 5.806, 8.973, 8.934, 8.823, 8.727, 8.641, 8.565, 8.496, 8.436, 8.383, 8.346, 8.307, 8.298, 8.281, 9.442, 9.437, 9.432, 9.429, 9.432, 9.433, 9.430, 9.437, 9.442, 9.446, 9.435)
98  ),
99 
100  BarrelCalorimeterProperties = cms.PSet(
101 
102  #====== Geometrical material properties ========
103 
104  # Light Collection efficiency
105  lightColl = cms.double(0.03),
106  # Light Collection uniformity
107  lightCollUnif = cms.double(0.003),
108  # Photostatistics (photons/GeV) in the homegeneous material
109  photoStatistics = cms.double(50.E3),
110  # Thickness of the detector in cm
111  thickness = cms.double(23.0),
112 
113  #====== Global parameters of the material ========
114 
115  # Interaction length in cm
116  interactionLength = cms.double(18.5),
117  Aeff = cms.double(170.87),
118  Zeff = cms.double(68.36),
119  rho = cms.double(8.280),
120  # Radiation length in g/cm^2
121  radLenIngcm2 = cms.double(7.37),
122 
123  # ===== Those parameters might be entered by hand
124  # or calculated out of the previous ones
125 
126  # Radiation length in cm. If value set to -1, FastSim uses internally the
127  # formula radLenIngcm2/rho
128  radLenIncm = cms.double(0.89),
129  # Critical energy in GeV. If value set to -1, FastSim uses internally the
130  # formula (2.66E-3*(x0*Z/A)^1.1): 8.74E-3 for ECAL EndCap
131  criticalEnergy = cms.double(8.74E-3),
132  # Moliere Radius in cm.If value set to -1, FastSim uses internally the
133  # formula : Es/criticalEnergy*X0 with Es=sqrt(4*Pi/alphaEM)*me*c^2=0.0212 GeV
134  # This value is known to be 2.190 cm for ECAL Endcap, but the formula gives 2.159 cm
135  moliereRadius = cms.double(2.190),
136 
137  #====== Parameters for sampling ECAL ========
138 
139  # Sampling Fraction: Fs = X0eff/(da+dp) where X0eff is the average X0
140  # of the active and passive media and da/dp their thicknesses
141  Fs = cms.double(0.0),
142 
143  # e/mip for the calorimeter. May be estimated by 1./(1+0.007*(Zp-Za))
144  ehat = cms.double(0.0),
145 
146  # a rough estimate of ECAL resolution sigma/E = resE/sqrt(E)
147  # it is used to generate Nspots in radial profiles.
148  resE = cms.double(1.),
149 
150  # the width in cm of the active layer
151  da = cms.double(0.2),
152 
153  # the width in cm of the passive layer
154  dp = cms.double(0.8),
155 
156  # Is a homogenious detector?
157  bHom = cms.bool(True),
158 
159  # Activate the LogDebug
160  debug = cms.bool(False)
161 
162  ),
163 
164  EndcapCalorimeterProperties = cms.PSet(
165 
166  #====== Geometrical material properties ========
167 
168  # Light Collection efficiency
169  lightColl = cms.double(0.023),
170  # Light Collection uniformity
171  lightCollUnif = cms.double(0.003),
172  # Photostatistics (photons/GeV) in the homegeneous material
173  photoStatistics = cms.double(50.E3),
174  # Thickness of the detector in cm
175  thickness = cms.double(22.0),
176 
177  #====== Global parameters of the material ========
178 
179  # Interaction length in cm
180  interactionLength = cms.double(18.5),
181  Aeff = cms.double(170.87),
182  Zeff = cms.double(68.36),
183  rho = cms.double(8.280),
184  # Radiation length in g/cm^2
185  radLenIngcm2 = cms.double(7.37),
186 
187  # ===== Those parameters might be entered by hand
188  # or calculated out of the previous ones
189 
190  # Radiation length in cm. If value set to -1, FastSim uses internally the
191  # formula radLenIngcm2/rho
192  radLenIncm = cms.double(0.89),
193  # Critical energy in GeV. If value set to -1, FastSim uses internally the
194  # formula (2.66E-3*(x0*Z/A)^1.1): 8.74E-3 for ECAL EndCap
195  criticalEnergy = cms.double(8.74E-3),
196  # Moliere Radius in cm.If value set to -1, FastSim uses internally the
197  # formula : Es/criticalEnergy*X0 with Es=sqrt(4*Pi/alphaEM)*me*c^2=0.0212 GeV
198  # This value is known to be 2.190 cm for ECAL Endcap, but the formula gives 2.159 cm
199  moliereRadius = cms.double(2.190),
200 
201 
202  #====== Parameters for sampling ECAL ========
203 
204  # Sampling Fraction: Fs = X0eff/(da+dp) where X0eff is the average X0
205  # of the active and passive media and da/dp their thicknesses
206  Fs = cms.double(0.0),
207 
208  # e/mip for the calorimeter. May be estimated by 1./(1+0.007*(Zp-Za))
209  ehat = cms.double(0.0),
210 
211  # a rough estimate of ECAL resolution sigma/E = resE/sqrt(E)
212  # it is used to generate Nspots in radial profiles.
213  resE = cms.double(1.),
214 
215  # the width in cm of the active layer
216  da = cms.double(0.2),
217 
218  # the width in cm of the passive layer
219  dp = cms.double(0.8),
220 
221  # Is a homogenious detector?
222  bHom = cms.bool(True),
223 
224  # Activate the LogDebug
225  debug = cms.bool(False)
226 
227  )
228 
229  ),
230  Debug = cms.untracked.bool(False),
231  useDQM = cms.untracked.bool(False),
232 # EvtsToDebug = cms.untracked.vuint32(487),
233  HCAL = cms.PSet(
234  SimMethod = cms.int32(0), ## 0 - use HDShower, 1 - use HDRShower, 2 - GFLASH
235  GridSize = cms.int32(7),
236  #-- 0 - simple response, 1 - parametrized response + showering, 2 - tabulated response + showering
237  SimOption = cms.int32(2),
238  Digitizer = cms.untracked.bool(False),
239 
240  samplingHBHE = cms.vdouble(125.44, 125.54, 125.32, 125.13, 124.46,
241  125.01, 125.22, 125.48, 124.45, 125.90,
242  125.83, 127.01, 126.82, 129.73, 131.83,
243  143.52, # HB
244  210.55, 197.93, 186.12, 189.64, 189.63,
245  190.28, 189.61, 189.60, 190.12, 191.22,
246  190.90, 193.06, 188.42, 188.42), #HE
247  samplingHF = cms.vdouble(0.383, 0.368),
248  samplingHO = cms.vdouble(231.0, 231.0, 231.0, 231.0, 360.0,
249  360.0, 360.0, 360.0, 360.0, 360.0,
250  360.0, 360.0, 360.0, 360.0, 360.0),
251 
252  ietaShiftHB = cms.int32(1),
253  timeShiftHB = cms.vdouble(6.9, 6.9, 7.1, 7.1, 7.3, 7.5, 7.9, 8.3, 8.7, 9.1, 9.5, 10.3, 10.9, 11.5, 12.3, 14.1),
254  ietaShiftHE = cms.int32(16),
255  timeShiftHE = cms.vdouble(16.9, 15.7, 15.3, 15.3, 15.1, 14.9, 14.7, 14.7, 14.5, 14.5, 14.3, 14.3, 14.5, 13.9),
256  ietaShiftHO = cms.int32(1),
257  timeShiftHO = cms.vdouble(13.7, 13.7, 13.9, 14.1, 15.1, 15.7, 16.5, 17.3, 18.1, 19.1, 20.3, 21.9, 23.3, 25.5, 26.1),
258  ietaShiftHF = cms.int32(29),
259  timeShiftHF = cms.vdouble(50.7, 52.5, 52.9, 53.9, 54.5, 55.1, 55.1, 55.7, 55.9, 56.1, 56.1, 56.1, 56.5),
260  ),
261  HFShowerLibrary = cms.PSet(
262  useShowerLibrary = cms.untracked.bool(False),
263  useCorrectionSL = cms.untracked.bool(True),
264  FileName = cms.FileInPath('SimG4CMS/Calo/data/HFShowerLibrary_npmt_noatt_eta4_16en_v3.root'),
265  ProbMax = cms.double(1.0),
266  BackProbability = cms.double(0.2),
267  CFibre = cms.double(0.5),
268  TreeEMID = cms.string('emParticles'),
269  TreeHadID = cms.string('hadParticles'),
270  Verbosity = cms.untracked.bool(False),
271  ApplyFiducialCut = cms.bool(True),
272  BranchEvt = cms.untracked.string(''),
273  BranchPre = cms.untracked.string(''),
274  BranchPost = cms.untracked.string('')
275  )
276  ),
277  GFlash = cms.PSet(
278  GflashExportToFastSim = cms.bool(True),
279  GflashHadronPhysics = cms.string('QGSP_BERT'),
280  GflashEMShowerModel = cms.bool(False),
281  GflashHadronShowerModel = cms.bool(True),
282  GflashHcalOuter = cms.bool(False),
283  GflashHistogram = cms.bool(False),
284  GflashHistogramName = cms.string('gflash_histogram.root'),
285  Verbosity = cms.untracked.int32(0),
286  bField = cms.double(3.8),
287  watcherOn = cms.bool(False),
288  tuning_pList = cms.vdouble()
289  )
290 )
291 
292 FamosCalorimetryBlock.Calorimetry.ECAL.Digitizer = True
293 FamosCalorimetryBlock.Calorimetry.HCAL.Digitizer = True
294 
295 #
296 # Modify for running in Run 2
297 #
298 eras.run2_common.toModify( FamosCalorimetryBlock.Calorimetry.HFShowerLibrary, useShowerLibrary=True )