Loading [MathJax]/extensions/tex2jax.js
 |
ATLAS Offline Software
|
|
def | emulateITkPixelDefects (flags, cfg, ModulePatterns=[[-2, 2, 0, 99,-99, 99,-99, 99, 0, 9999, 0, 1, 0]], DefectProbabilities=[[0., 1e-2, 1e-1, 0.]], NDefectFractionsPerPattern=[[1.,-1, 1.]], NoiseProbability=[], NoiseShape=[], CornerDefectParamsPerPattern=[], NCornerDefectFractionsPerPattern=[], FillHistogramsPerPattern=False, FillEtaPhiHistogramsPerPattern=False, int MaxRandomPositionAttempts=10, str HistogramGroupName="ITkPixelDefects", str HistogramFileName="itk_pixel_defects_opt1.root", PropagateDefectsToStatus=True) |
|
def | emulatePixelDefects (flags, cfg, ModulePatterns=None, DefectProbabilities=None, NDefectFractionsPerPattern=None, FillHistogramsPerPattern=False, FillEtaPhiHistogramsPerPattern=False, str HistogramGroupName="PixelDefects", str HistogramFileName="pixel_defects.root") |
|
def | poissonFractions (cc_defect_prob=1e-1, max_n=5) |
|
def | quadProb (circuit_prob) |
|
def | fractionsForExactlyNCoreColumnDefects (ExactlyNCoreColumnDefects=1) |
|
def | makeITkDefectsParams (quad_cc_defect_prob, quad_fractions, circuit_cc_defect_prob, circuit_fractions, pixel_defect_prob=1e-2, module_defect_prob=0., cornerDefectProb=0., noiseProbability=None, noiseShape=[]) |
|
def | makeITkPixelNoise (noiseProb=0.) |
|
def | emulateITkPixelDefectsOneCC (flags, cfg, FrontEndCCDefectProb=0.1, PixelDefectProb=1e-2, NumberOfCCDefects=1, ModuleDefectProb=0., CornerDefectProb=0., NoiseProb=0., PropagateDefectsToStatus=True, HistogramFileName=None) |
|
def | emulateITkPixelDefectsPoisson (flags, cfg, FrontEndCCDefectProb=0.1, PixelDefectProb=1e-2, ModuleDefectProb=0., CornerDefectProb=0., NoiseProb=0., PropagateDefectsToStatus=True, HistogramFileName=None) |
|
def | emulateITkPixelDefectsDefault (flags, cfg, FrontEndCCDefectProb=0.1, PixelDefectProb=1e-2, ModuleDefectProb=1e-2, CornerDefectProb=15e-2, NoiseProb=0., PropagateDefectsToStatus=True, HistogramFileName=None) |
|
◆ emulateITkPixelDefects()
def PixelDefectsEmulatorPostInclude.emulateITkPixelDefects |
( |
|
flags, |
|
|
|
cfg, |
|
|
|
ModulePatterns = [[-2,2,0,99,-99,99,-99,99,0,9999,0,1,0]] , |
|
|
|
DefectProbabilities = [[0.,1e-2,1e-1,0.]] , |
|
|
|
NDefectFractionsPerPattern = [[1.,-1, 1.]] , |
|
|
|
NoiseProbability = [] , |
|
|
|
NoiseShape = [] , |
|
|
|
CornerDefectParamsPerPattern = [] , |
|
|
|
NCornerDefectFractionsPerPattern = [] , |
|
|
|
FillHistogramsPerPattern = False , |
|
|
|
FillEtaPhiHistogramsPerPattern = False , |
|
|
int |
MaxRandomPositionAttempts = 10 , |
|
|
str |
HistogramGroupName = "ITkPixelDefects" , |
|
|
str |
HistogramFileName = "itk_pixel_defects_opt1.root" , |
|
|
|
PropagateDefectsToStatus = True |
|
) |
| |
Schedule conditions algorithm for emulated ITk pixel defects, and algorithms to drop RDOs overlapping with the emulated defects.
ModulePattern: criteria to match modules, which are lists of n-tuples where every two numbers of each n-tuple define a range
to match parts of module identifiers (barrel/ec, layer/disk, eta., phi, columns, side) plus a flag (last
element of each n-tuple), which is unused for pixel.
DefectProbabilities: list of n-tuples per criterion containing 4 probabilities: module, pixel to be defect, a module
to have at least one core column defect, circuit defect.
NDefectFractionsPerPattern: Fractions of exactly n-group defects (core-column, circuit) under condition that there is at least one
such group defect. There must be one n-tuple with fractions per criterion, and each fraction
n-tuple must contain for each group defect probability a non empty set of fractions of exactly 1, ... n defects.
Fractions for different group defects are separated by -1. There should be two sequences of
positive fractions separated by -1.
NoiseProbability: Empty or probabilities of a pixel to produce a spurious hit.
NoiseShape: binned PDF (i.e. list of fractions) to create tot values for spurious hits.
CornerDefectParamsPerPattern: parameters for corner defects per pattern can be created with e.g. makeCornerDefectParam
NCornerDefectFractionsPerPattern: fractions of 1,..4 corner defects
FillHistogramsPerPattern: if True histograms are filled per module pattern
FillEtaPhiHistogramsPerPattern: if True also fill xy, and rz histograms of defects per module.
HistogramGroupName: None (disables histogramming) or the histogram group name must be unique
HistogramFileName: None (disables histogramming) or a file name for writing the histograms.
Definition at line 16 of file PixelDefectsEmulatorPostInclude.py.
18 ModulePatterns=[[-2,2,0,99,-99,99,-99,99,0,9999,0,1,0]],
19 DefectProbabilities=[[0.,1e-2,1e-1,0.]],
20 NDefectFractionsPerPattern=[[1.,-1, 1.]],
23 CornerDefectParamsPerPattern=[],
24 NCornerDefectFractionsPerPattern=[],
25 FillHistogramsPerPattern=False,
26 FillEtaPhiHistogramsPerPattern=False,
27 MaxRandomPositionAttempts: int=10,
28 HistogramGroupName: str=
"ITkPixelDefects",
29 HistogramFileName: str=
"itk_pixel_defects_opt1.root",
30 PropagateDefectsToStatus=
True) :
32 Schedule conditions algorithm for emulated ITk pixel defects, and algorithms to drop RDOs overlapping with the emulated defects.
33 ModulePattern: criteria to match modules, which are lists of n-tuples where every two numbers of each n-tuple define a range
34 to match parts of module identifiers (barrel/ec, layer/disk, eta., phi, columns, side) plus a flag (last
35 element of each n-tuple), which is unused for pixel.
36 DefectProbabilities: list of n-tuples per criterion containing 4 probabilities: module, pixel to be defect, a module
37 to have at least one core column defect, circuit defect.
38 NDefectFractionsPerPattern: Fractions of exactly n-group defects (core-column, circuit) under condition that there is at least one
39 such group defect. There must be one n-tuple with fractions per criterion, and each fraction
40 n-tuple must contain for each group defect probability a non empty set of fractions of exactly 1, ... n defects.
41 Fractions for different group defects are separated by -1. There should be two sequences of
42 positive fractions separated by -1.
43 NoiseProbability: Empty or probabilities of a pixel to produce a spurious hit.
44 NoiseShape: binned PDF (i.e. list of fractions) to create tot values for spurious hits.
45 CornerDefectParamsPerPattern: parameters for corner defects per pattern can be created with e.g. makeCornerDefectParam
46 NCornerDefectFractionsPerPattern: fractions of 1,..4 corner defects
47 FillHistogramsPerPattern: if True histograms are filled per module pattern
48 FillEtaPhiHistogramsPerPattern: if True also fill xy, and rz histograms of defects per module.
49 HistogramGroupName: None (disables histogramming) or the histogram group name must be unique
50 HistogramFileName: None (disables histogramming) or a file name for writing the histograms.
53 from InDetDefectsEmulation.PixelDefectsEmulatorConfig
import (
54 ITkPixelDefectsEmulatorCondAlgCfg,
55 ITkPixelDefectsEmulatorAlgCfg,
56 ITkPixelDefectsEmulatorToDetectorElementStatusCondAlgCfg,
61 if HistogramFileName
is None or len(HistogramFileName) ==0 :
62 HistogramGroupName =
None
63 if HistogramGroupName
is not None :
64 cfg.merge(
DefectsHistSvcCfg(flags, HistogramGroup=HistogramGroupName, FileName=HistogramFileName))
69 HistogramGroupName=f
"/{HistogramGroupName}/EmulatedDefects/" if HistogramGroupName
is not None else "",
70 ModulePatterns = ModulePatterns,
71 DefectProbabilities = DefectProbabilities,
72 NDefectFractionsPerPattern = NDefectFractionsPerPattern,
73 MaxRandomPositionAttempts=MaxRandomPositionAttempts,
74 CornerDefectParamsPerPattern=CornerDefectParamsPerPattern,
75 NCornerDefectFractionsPerPattern=NCornerDefectFractionsPerPattern,
76 FillHistogramsPerPattern=FillHistogramsPerPattern,
77 FillEtaPhiHistogramsPerPattern=FillEtaPhiHistogramsPerPattern,
78 CheckerBoardDefects=
False,
81 WriteKey=
"ITkPixelEmulatedDefects",
87 EmulatedDefectsKey=
"ITkPixelEmulatedDefects",
88 ModulePatterns = ModulePatterns,
89 NoiseProbability = NoiseProbability,
90 NoiseShape = NoiseShape,
92 HistogramGroupName=f
"/{HistogramGroupName}/RejectedRDOs/" if HistogramGroupName
is not None else "",
95 if PropagateDefectsToStatus :
98 name=
"ITkPixelDefectsEmulatorToDetectorElementStatusCondAlg",
99 EmulatedDefectsKey=
"ITkPixelEmulatedDefects",
100 WriteKey=
"ITkPixelDetectorElementStatusFromEmulatedDefects"))
101 pixel_det_el_status_cond_alg=cfg.getCondAlgo(
"ITkPixelDetectorElementStatusCondAlgNoByteStreamErrors")
102 pixel_det_el_status_cond_alg.ConditionsSummaryTool.PixelDetElStatusCondDataBaseKey=
"ITkPixelDetectorElementStatusFromEmulatedDefects"
◆ emulateITkPixelDefectsDefault()
def PixelDefectsEmulatorPostInclude.emulateITkPixelDefectsDefault |
( |
|
flags, |
|
|
|
cfg, |
|
|
|
FrontEndCCDefectProb = 0.1 , |
|
|
|
PixelDefectProb = 1e-2 , |
|
|
|
ModuleDefectProb = 1e-2 , |
|
|
|
CornerDefectProb = 15e-2 , |
|
|
|
NoiseProb = 0. , |
|
|
|
PropagateDefectsToStatus = True , |
|
|
|
HistogramFileName = None |
|
) |
| |
Enables all defects according to the current expectation.
Definition at line 378 of file PixelDefectsEmulatorPostInclude.py.
380 FrontEndCCDefectProb=0.1,
381 PixelDefectProb=1e-2,
382 ModuleDefectProb=1e-2,
383 CornerDefectProb=15e-2,
385 PropagateDefectsToStatus=True,
386 HistogramFileName=None) :
388 Enables all defects according to the current expectation.
391 FrontEndCCDefectProb,
396 PropagateDefectsToStatus,
◆ emulateITkPixelDefectsOneCC()
def PixelDefectsEmulatorPostInclude.emulateITkPixelDefectsOneCC |
( |
|
flags, |
|
|
|
cfg, |
|
|
|
FrontEndCCDefectProb = 0.1 , |
|
|
|
PixelDefectProb = 1e-2 , |
|
|
|
NumberOfCCDefects = 1 , |
|
|
|
ModuleDefectProb = 0. , |
|
|
|
CornerDefectProb = 0. , |
|
|
|
NoiseProb = 0. , |
|
|
|
PropagateDefectsToStatus = True , |
|
|
|
HistogramFileName = None |
|
) |
| |
Create exactly one core column defect per module where the probability is given
by module_prob, and create single pixel defects according to pixel_defect_prob
Definition at line 295 of file PixelDefectsEmulatorPostInclude.py.
297 FrontEndCCDefectProb=0.1,
298 PixelDefectProb=1e-2,
303 PropagateDefectsToStatus=True,
304 HistogramFileName=None) :
306 Create exactly one core column defect per module where the probability is given
307 by module_prob, and create single pixel defects according to pixel_defect_prob
311 ModulePatterns, DefectProbabilities, NDefectFractionsPerPattern, NoiseProbability, NoiseShape,cornerDefectParam,cornerDefectFractions =
makeITkDefectsParams(
312 quad_cc_defect_prob=
quadProb(FrontEndCCDefectProb),
313 quad_fractions=fractions,
314 circuit_cc_defect_prob=FrontEndCCDefectProb,
315 circuit_fractions=fractions,
316 pixel_defect_prob=PixelDefectProb,
317 module_defect_prob=ModuleDefectProb,
318 cornerDefectProb=CornerDefectProb,
319 noiseProbability=noiseProbabilitySingle,
320 noiseShape=noiseShapeSingle)
324 ModulePatterns=ModulePatterns,
325 DefectProbabilities=DefectProbabilities,
326 NDefectFractionsPerPattern=NDefectFractionsPerPattern,
327 NoiseProbability=NoiseProbability,
328 NoiseShape=NoiseShape,
329 CornerDefectParamsPerPattern=cornerDefectParam,
330 NCornerDefectFractionsPerPattern=cornerDefectFractions,
331 FillHistogramsPerPattern=
True,
332 FillEtaPhiHistogramsPerPattern=
True,
333 PropagateDefectsToStatus=PropagateDefectsToStatus,
334 HistogramFileName=HistogramFileName)
◆ emulateITkPixelDefectsPoisson()
def PixelDefectsEmulatorPostInclude.emulateITkPixelDefectsPoisson |
( |
|
flags, |
|
|
|
cfg, |
|
|
|
FrontEndCCDefectProb = 0.1 , |
|
|
|
PixelDefectProb = 1e-2 , |
|
|
|
ModuleDefectProb = 0. , |
|
|
|
CornerDefectProb = 0. , |
|
|
|
NoiseProb = 0. , |
|
|
|
PropagateDefectsToStatus = True , |
|
|
|
HistogramFileName = None |
|
) |
| |
Create Poisson distributed core column defects per module where the probability for at least one
core column defect is given by front_end_cc_defect_prob for single chip modules and larger for
quads, respectively. Single pixel defects are controlled by pixel_defect_prob
Definition at line 337 of file PixelDefectsEmulatorPostInclude.py.
339 FrontEndCCDefectProb=0.1,
340 PixelDefectProb=1e-2,
344 PropagateDefectsToStatus=True,
345 HistogramFileName=None) :
347 Create Poisson distributed core column defects per module where the probability for at least one
348 core column defect is given by front_end_cc_defect_prob for single chip modules and larger for
349 quads, respectively. Single pixel defects are controlled by pixel_defect_prob
352 quad_prob=
quadProb(FrontEndCCDefectProb)
353 ModulePatterns, DefectProbabilities, NDefectFractionsPerPattern, NoiseProbability, NoiseShape,cornerDefectParam,cornerDefectFractions =
makeITkDefectsParams(
354 quad_cc_defect_prob=quad_prob,
356 circuit_cc_defect_prob=FrontEndCCDefectProb,
358 pixel_defect_prob=PixelDefectProb,
359 module_defect_prob=ModuleDefectProb,
360 cornerDefectProb=CornerDefectProb,
361 noiseProbability=noiseProbabilitySingle,
362 noiseShape=noiseShapeSingle)
366 ModulePatterns=ModulePatterns,
367 DefectProbabilities=DefectProbabilities,
368 NDefectFractionsPerPattern=NDefectFractionsPerPattern,
369 NoiseProbability=NoiseProbability,
370 NoiseShape=NoiseShape,
371 CornerDefectParamsPerPattern=cornerDefectParam,
372 NCornerDefectFractionsPerPattern=cornerDefectFractions,
373 FillHistogramsPerPattern=
True,
374 FillEtaPhiHistogramsPerPattern=
True,
375 PropagateDefectsToStatus=PropagateDefectsToStatus,
376 HistogramFileName=HistogramFileName)
◆ emulatePixelDefects()
def PixelDefectsEmulatorPostInclude.emulatePixelDefects |
( |
|
flags, |
|
|
|
cfg, |
|
|
|
ModulePatterns = None , |
|
|
|
DefectProbabilities = None , |
|
|
|
NDefectFractionsPerPattern = None , |
|
|
|
FillHistogramsPerPattern = False , |
|
|
|
FillEtaPhiHistogramsPerPattern = False , |
|
|
str |
HistogramGroupName = "PixelDefects" , |
|
|
str |
HistogramFileName = "pixel_defects.root" |
|
) |
| |
Schedule algorithms to emulate run3 pixel defects, and algorithm to drop RDOs which overlap with these defects
Definition at line 104 of file PixelDefectsEmulatorPostInclude.py.
107 DefectProbabilities=None,
108 NDefectFractionsPerPattern=None,
109 FillHistogramsPerPattern=False,
110 FillEtaPhiHistogramsPerPattern=False,
111 HistogramGroupName: str=
"PixelDefects",
112 HistogramFileName: str=
"pixel_defects.root") :
114 Schedule algorithms to emulate run3 pixel defects, and algorithm to drop RDOs which overlap with these defects
116 from InDetDefectsEmulation.PixelDefectsEmulatorConfig
import (
117 PixelDefectsEmulatorCondAlgCfg,
118 PixelDefectsEmulatorAlgCfg,
123 if HistogramFileName
is None or len(HistogramFileName) ==0 :
124 HistogramGroupName =
None
125 if HistogramGroupName
is not None :
126 cfg.merge(
DefectsHistSvcCfg(flags, HistogramGroup=HistogramGroupName, FileName=HistogramFileName))
128 if ModulePatterns
is None and DefectProbabilities
is None and NDefectFractionsPerPattern
is None:
129 a_module_pattern_list, a_prob_list,fractions,ignore_NoiseProbability,ignore_NoiseShape, cornerDefectParam, cornerDefectFractions =
combineModuleDefects([
130 moduleDefect(bec=[-2,-2],layer=[0,99], phi_range=[-99,99],eta_range=[-99,99],
131 columns_or_strips=[0,9999],
140 ModulePatterns = a_module_pattern_list
141 DefectProbabilities = a_prob_list
142 NDefectFractionsPerPattern = fractions
146 ModulePatterns = ModulePatterns,
147 DefectProbabilities = DefectProbabilities,
148 NDefectFractionsPerPattern = NDefectFractionsPerPattern,
149 CornerDefectParamsPerPattern=cornerDefectParam,
150 NCornerDefectFractionsPerPattern=cornerDefectFractions,
151 FillHistogramsPerPattern=FillHistogramsPerPattern,
152 FillEtaPhiHistogramsPerPattern=FillEtaPhiHistogramsPerPattern,
154 HistogramGroupName=f
"/{HistogramGroupName}/EmulatedDefects/" if HistogramGroupName
is not None else "",
155 WriteKey=
"PixelEmulatedDefects",
161 EmulatedDefectsKey=
"PixelEmulatedDefects",
163 HistogramGroupName=f
"/{HistogramGroupName}/RejectedRDOs/" if HistogramGroupName
is not None else "",
◆ fractionsForExactlyNCoreColumnDefects()
def PixelDefectsEmulatorPostInclude.fractionsForExactlyNCoreColumnDefects |
( |
|
ExactlyNCoreColumnDefects = 1 | ) |
|
Create fraction n-tuple, containing zero except for the element corresponding
to exactly n defects, which is set to 1.
Definition at line 193 of file PixelDefectsEmulatorPostInclude.py.
195 Create fraction n-tuple, containing zero except for the element corresponding
196 to exactly n defects, which is set to 1.
198 return [ 0.
if idx != ExactlyNCoreColumnDefects
else 1.
for idx
in range(1,ExactlyNCoreColumnDefects+1) ]
◆ makeITkDefectsParams()
def PixelDefectsEmulatorPostInclude.makeITkDefectsParams |
( |
|
quad_cc_defect_prob, |
|
|
|
quad_fractions, |
|
|
|
circuit_cc_defect_prob, |
|
|
|
circuit_fractions, |
|
|
|
pixel_defect_prob = 1e-2 , |
|
|
|
module_defect_prob = 0. , |
|
|
|
cornerDefectProb = 0. , |
|
|
|
noiseProbability = None , |
|
|
|
noiseShape = [] |
|
) |
| |
Create different defects for quads and single chip modules, where the corresponding modules are selected by
the number of offline columns
Definition at line 200 of file PixelDefectsEmulatorPostInclude.py.
202 circuit_cc_defect_prob,
204 pixel_defect_prob=1e-2,
205 module_defect_prob=0.,
207 noiseProbability=None,
210 Create different defects for quads and single chip modules, where the corresponding modules are selected by
211 the number of offline columns
218 min_rx=2.,max_rx=8.4,
219 min_ry=2.,max_ry=4.5,
220 min_sagitta=0.,max_sagitta=2.2)
223 corner_defect_n_defect_corners=
poissonFractions(cc_defect_prob=15e-2, max_n=4)
226 moduleDefect(bec=[-2,2],layer=[0,99], phi_range=[-99,99],eta_range=[-99,99],
227 columns_or_strips=[800,800],
230 probability=[module_defect_prob,
235 fractionsOfNDefects=[quad_fractions,[1.]],
236 noiseProbability=noiseProbability,
237 noiseShape=noiseShape,
238 cornerDefectParam=[],
239 cornerDefectNCornerFractions=[]
241 moduleDefect(bec=[-2,2],layer=[0,1], phi_range=[-99,99],eta_range=[-99,99],
242 columns_or_strips=[384,384],
245 probability=[module_defect_prob,
247 circuit_cc_defect_prob,
250 fractionsOfNDefects=[circuit_fractions,[1.]],
251 noiseProbability=noiseProbability,
252 noiseShape=noiseShape,
253 cornerDefectParam=corner_defects,
254 cornerDefectNCornerFractions=corner_defect_n_defect_corners,
256 moduleDefect(bec=[-2,2],layer=[0,1], phi_range=[-99,99],eta_range=[-99,99],
257 columns_or_strips=[200,200],
260 probability=[module_defect_prob,
262 circuit_cc_defect_prob,
265 fractionsOfNDefects=[circuit_fractions,[1.]],
266 noiseProbability=noiseProbability,
267 noiseShape=noiseShape,
268 cornerDefectParam=corner_defects,
269 cornerDefectNCornerFractions=corner_defect_n_defect_corners,
◆ makeITkPixelNoise()
def PixelDefectsEmulatorPostInclude.makeITkPixelNoise |
( |
|
noiseProb = 0. | ) |
|
For NoiseProb>0. create phantasie noise tot shape, with mean at zero width of 0.7
truncated below a tot of 1.
Definition at line 273 of file PixelDefectsEmulatorPostInclude.py.
275 For NoiseProb>0. create phantasie noise tot shape, with mean at zero width of 0.7
276 truncated below a tot of 1.
282 return [elm/scale
if scale > 0.
else 0.
for elm
in dist]
283 def gaussDist(mean, width, n) :
284 scale = -1./(2*width)
285 return norm([ math.exp( scale *math.pow(i - mean,2.) )
for i
in range(0,n) ])
288 noiseShape=[ 0. ] + gaussDist(-1,0.7,4)
292 return noiseProb,noiseShape
◆ poissonFractions()
def PixelDefectsEmulatorPostInclude.poissonFractions |
( |
|
cc_defect_prob = 1e-1 , |
|
|
|
max_n = 5 |
|
) |
| |
Create fractions for exactly 1..max_n defects, under the condition that
the probability for at least one such defects is cc_defect_prob, and
assuming that the fractions are Poisson distributed.
Definition at line 168 of file PixelDefectsEmulatorPostInclude.py.
170 Create fractions for exactly 1..max_n defects, under the condition that
171 the probability for at least one such defects is cc_defect_prob, and
172 assuming that the fractions are Poisson distributed.
174 if cc_defect_prob > 0. :
175 def PoissonProb(expected, n) :
176 return math.pow(expected,n)*math.exp(-expected)/math.gamma(n+1)
177 def norm(fractions) :
178 Norm = 1./sum (fractions)
179 return [Norm*elm
for elm
in fractions ]
180 expectation=-math.log(1-cc_defect_prob)
181 return norm([ PoissonProb(expectation,i)
for i
in range(1,max_n+1) ])
◆ quadProb()
def PixelDefectsEmulatorPostInclude.quadProb |
( |
|
circuit_prob | ) |
|
Compute the defect probability for a quad module from the probabilities
of a single chip module, assuming that the defect is a "feature" of the
chip.
Definition at line 185 of file PixelDefectsEmulatorPostInclude.py.
187 Compute the defect probability for a quad module from the probabilities
188 of a single chip module, assuming that the defect is a "feature" of the
191 return 1-math.pow(1-circuit_prob,4)
ComponentAccumulator ITkPixelDefectsEmulatorToDetectorElementStatusCondAlgCfg(flags, str name="ITkPixelDefectsEmulatorToDetectorElementStatusCondAlgCfg", **dict kwargs)
ComponentAccumulator DefectsHistSvcCfg(flags, str HistogramGroup="PixelDefects", str FileName='pixel_defects.root')
def moduleDefect(bec=[-2, 2], layer=[0, 8], eta_range=[-99, 99], phi_range=[-99, 99], columns_or_strips=[0, 2000], column_or_strip_length=[0, 1000000], side_range=[0, 1], all_rows=True, probability=[1e-2], fractionsOfNDefects=[], noiseProbability=None, noiseShape=[], cornerDefectParam=None, cornerDefectNCornerFractions=None)
ComponentAccumulator PixelDefectsEmulatorCondAlgCfg(flags, str name="PixelDefectsEmulatorCondAlg", **dict kwargs)
def fractionsForExactlyNCoreColumnDefects(ExactlyNCoreColumnDefects=1)
ComponentAccumulator ITkPixelDefectsEmulatorCondAlgCfg(flags, str name="ITkPixelDefectsEmulatorCondAlg", **dict kwargs)
def emulateITkPixelDefects(flags, cfg, ModulePatterns=[[-2, 2, 0, 99,-99, 99,-99, 99, 0, 9999, 0, 1, 0]], DefectProbabilities=[[0., 1e-2, 1e-1, 0.]], NDefectFractionsPerPattern=[[1.,-1, 1.]], NoiseProbability=[], NoiseShape=[], CornerDefectParamsPerPattern=[], NCornerDefectFractionsPerPattern=[], FillHistogramsPerPattern=False, FillEtaPhiHistogramsPerPattern=False, int MaxRandomPositionAttempts=10, str HistogramGroupName="ITkPixelDefects", str HistogramFileName="itk_pixel_defects_opt1.root", PropagateDefectsToStatus=True)
def makeCornerDefectParam(probability=1e-1, min_rx=0., max_rx=4e-3, min_ry=0., max_ry=4e-3, min_sagitta=0., max_sagitta=2e-3)
def makeITkDefectsParams(quad_cc_defect_prob, quad_fractions, circuit_cc_defect_prob, circuit_fractions, pixel_defect_prob=1e-2, module_defect_prob=0., cornerDefectProb=0., noiseProbability=None, noiseShape=[])
ComponentAccumulator PixelDefectsEmulatorAlgCfg(flags, str name="PixelDefectsEmulatorAlg", **dict kwargs)
def combineModuleDefects(defects)
ComponentAccumulator ITkPixelDefectsEmulatorAlgCfg(flags, str name="ITkPixelDefectsEmulatorAlg", **dict kwargs)
some useful constants -------------------------------------------------—
def emulatePixelDefects(flags, cfg, ModulePatterns=None, DefectProbabilities=None, NDefectFractionsPerPattern=None, FillHistogramsPerPattern=False, FillEtaPhiHistogramsPerPattern=False, str HistogramGroupName="PixelDefects", str HistogramFileName="pixel_defects.root")
def quadProb(circuit_prob)
def emulateITkPixelDefectsPoisson(flags, cfg, FrontEndCCDefectProb=0.1, PixelDefectProb=1e-2, ModuleDefectProb=0., CornerDefectProb=0., NoiseProb=0., PropagateDefectsToStatus=True, HistogramFileName=None)
def emulateITkPixelDefectsOneCC(flags, cfg, FrontEndCCDefectProb=0.1, PixelDefectProb=1e-2, NumberOfCCDefects=1, ModuleDefectProb=0., CornerDefectProb=0., NoiseProb=0., PropagateDefectsToStatus=True, HistogramFileName=None)
def makeITkPixelNoise(noiseProb=0.)
def emulateITkPixelDefectsDefault(flags, cfg, FrontEndCCDefectProb=0.1, PixelDefectProb=1e-2, ModuleDefectProb=1e-2, CornerDefectProb=15e-2, NoiseProb=0., PropagateDefectsToStatus=True, HistogramFileName=None)
def poissonFractions(cc_defect_prob=1e-1, max_n=5)