forked from npshub/mantid
-
Notifications
You must be signed in to change notification settings - Fork 0
/
testing.py
522 lines (509 loc) · 37.5 KB
/
testing.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
# Mantid Repository : https://github.com/mantidproject/mantid
#
# Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
# NScD Oak Ridge National Laboratory, European Spallation Source,
# Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
# SPDX - License - Identifier: GPL - 3.0 +
from mantid.simpleapi import *
import numpy as np
def create_test_ws():
"""
Creates data used for vesuvio tests
"""
###### Simulates LoadVesuvio with spectrum number 135-136 #################
tof_ws = CreateSimulationWorkspace(Instrument='Vesuvio',
BinParams=[49,2,563],
UnitX='TOF')
tof_ws = CropWorkspace(tof_ws,StartWorkspaceIndex=134,
EndWorkspaceIndex=135)
tof_ws = ConvertToPointData(tof_ws)
SetInstrumentParameter(tof_ws, ParameterName='t0',
ParameterType='Number',Value='0.5')
SetInstrumentParameter(tof_ws, ParameterName='sigma_l1',
ParameterType='Number', Value='0.021')
SetInstrumentParameter(tof_ws, ParameterName='sigma_l2',
ParameterType='Number', Value='0.023')
SetInstrumentParameter(tof_ws, ParameterName='sigma_tof',
ParameterType='Number', Value='0.3')
SetInstrumentParameter(tof_ws, ParameterName='sigma_theta',
ParameterType='Number', Value='0.028')
SetInstrumentParameter(tof_ws, ParameterName='hwhm_lorentz',
ParameterType='Number', Value='24.0')
SetInstrumentParameter(tof_ws, ParameterName='sigma_gauss',
ParameterType='Number', Value='73.0')
# Algorithm allows separate parameters for the foils
SetInstrumentParameter(tof_ws, ComponentName='foil-pos0',
ParameterName='hwhm_lorentz',
ParameterType='Number', Value='144.0')
SetInstrumentParameter(tof_ws, ComponentName='foil-pos0',
ParameterName='sigma_gauss',
ParameterType='Number', Value='20.0')
SetInstrumentParameter(tof_ws, ComponentName='foil-pos1',
ParameterName='hwhm_lorentz',
ParameterType='Number', Value='144.0')
SetInstrumentParameter(tof_ws, ComponentName='foil-pos1',
ParameterName='sigma_gauss',
ParameterType='Number', Value='20.0')
arr_y_0 = np.asarray([0.0279822, 0.1587605, 0.0534081, 0.055589, 0.0154309,
-0.0137594, -0.0051854, 0.0023374, 0.131721, 0.0039364,
0.1935434, 0.0193096, -0.0062345, 0.0023902, -0.0040375,
0.0043059, 0.1577286, 0.0083578, 0.0648338, 0.0696508,
-0.0013759, 0.0033154, -0.0008886, 8.67e-05, 0.0072103,
0.0015019, 0.0259273, 0.0183395, 0.0072991, -0.0024434,
0.0057123, 0.0157501, 0.2030135, 0.3095373, 0.0234369,
0.0125052, 0.0071439, 0.0135502, 0.0175092, 0.0119797,
0.0363222, 0.0194647, 0.0244774, 0.0265381, 0.0189537,
0.0359726, 0.023707, 0.0391928, 0.0459597, 0.0392336,
0.0417778, 0.036422, 0.0568132, 0.0424851, 0.0432542,
0.0605573, 0.0496959, 0.086144, 0.2629902, 0.4663805,
0.1050775, 0.062194, 0.0530962, 0.0435767, 0.0469903,
0.0392462, 0.0307214, 0.0267018, 0.0221355, 0.0334414,
0.0352838, 0.021433, 0.0210262, 0.0356013, 0.032687,
0.0265155, 0.0271023, 0.0201944, 0.0074697, 0.0123702,
0.0073939, 0.002461, 0.0202981, 0.0226783, 0.0055991,
0.0252422, 0.0239618, 0.0101082, 0.0141603, -0.0003597,
0.0125734, 0.0037756, 0.0025411, 0.0084439, 0.0127981,
0.014032, -0.0009435, 0.0013394, 0.0173213, 0.0057206,
-0.0012773, -0.0021051, -0.0025929, 0.0089874, 0.00098,
0.0078117, 0.0112268, 0.005673, -0.0056119, 0.0092864,
0.0074909, 0.0024653, 0.012757, 0.0022201, 0.0105046,
-0.0006327, -0.0021474, 0.0156625, 0.0107478, 0.0173584,
0.0018866, 0.0131581, 0.0155948, 0.0251798, 0.0215185,
0.0133919, 0.0413915, 0.0423395, 0.0330503, 0.0457673,
0.0663854, 0.0697569, 0.0915387, 0.1078947, 0.1139649,
0.2391652, 0.3495295, 0.4186069, 0.4659951, 0.4397788,
0.4607338, 0.4232483, 0.323764, 0.2026262, 0.1889135,
0.0954193, 0.0924742, 0.1009313, 0.0522692, 0.0556634,
0.0417043, 0.0348195, 0.0520627, 0.0557692, 0.0633281,
0.0814483, 0.1032962, 0.1364041, 0.1340803, 0.1434188,
0.152608, 0.1277786, 0.0986823, 0.0789467, 0.0481237,
0.0216125, 0.0072505, 0.026356, 0.0158784, 0.005582,
0.0198579, 0.008183, -0.0040249, -0.0022096, 0.0007557,
-0.0089817, -0.0050716, 0.0113601, 0.0044671, 0.0093089,
-0.0052041, -0.0091243, -0.0009747, 0.0038765, 0.0084152,
-0.0020985, 0.0024573, -0.0080375, -0.0010825, -0.0024205,
0.0084446, 0.0002166, 0.0005044, 0.0044596, 0.0021728,
0.0001159, -0.0054755, -0.0056922, 0.0065526, -0.0036411,
-0.0138637, 0.0099348, -0.0048227, -0.0029783, -0.0002207,
-0.0125268, -0.0009914, 0.0088224, -0.0009368, 0.0055571,
0.0003298, 0.0009209, -0.0008864, 0.0058332, 0.0052585,
-0.0019276, -0.0001564, -0.005547, 0.0039876, -0.0051404,
-0.0021916, -0.0035655, -0.0018638, 0.0076461, -0.0154677,
-0.0062851, -0.0071069, 0.0076426, -0.0036411, 0.0019039,
-0.0020335, -0.0062465, -0.0115891, -0.003828, -0.0006906,
0.002403, -0.0012887, 0.0061918, -0.0079949, -0.0080552,
0.0027878, -0.0013177, -0.0021298, -0.0053362, 0.0083187,
0.0059659, -0.0048295, 0.0116407, -0.0048947, 0.0032214,
-0.0017089, 0.0018194, -0.0005464, 0.0108776, 0.0041985,
-0.0051512, 0.0063585])
arr_y_1 = np.asarray([0.0155041, 0.1536219, 0.0705738, 0.0379744, -0.0057821,
-0.0070227, -0.0102393, 0.0066189, 0.1688158, 0.0197819,
0.1805022, 0.0586206, 0.0049459, 0.0026698, -0.0096383,
-0.0107852, 0.1691328, 0.0025864, 0.0487438, 0.05435,
0.0145951, 0.0020499, -0.0044584, -0.0053, -0.0030876,
0.0028747, 0.0267385, 0.0189885, 0.0059005, -0.0013181,
0.0028342, 0.0130067, 0.1728085, 0.2307516, 0.0278331,
0.0088497, 0.0067179, 0.0080358, 0.0030305, 0.0046967,
0.0096459, 0.0047008, 0.0084455, 0.0120191, 0.0270126,
0.0182201, 0.0163271, 0.0191555, 0.023674, 0.0235553,
0.0255388, 0.0318359, 0.0324973, 0.0471974, 0.0322757,
0.0376968, 0.0561852, 0.054098, 0.2902402, 0.4723219,
0.1265552, 0.0613737, 0.0608245, 0.0510366, 0.0562233,
0.0589178, 0.0472395, 0.0248228, 0.0298321, 0.0521667,
0.050088, 0.0486207, 0.0417202, 0.0361827, 0.0307559,
0.0290634, 0.0443114, 0.032456, 0.0544284, 0.0362842,
0.0349844, 0.033014, 0.0214423, 0.0276229, 0.028285,
0.0313363, 0.02097, 0.0267219, 0.0258398, 0.010141,
0.0106303, 0.0039375, 0.015176, 0.0034047, 0.0059373,
-0.004565, 0.0104247, -0.0008644, 0.0147386, 0.0124944,
0.0123692, 0.0024143, 0.0037337, 0.022632, 0.0099649,
0.0195163, 0.0047546, 0.0074703, -0.0060777, 0.0016553,
0.0069532, 0.0054889, -0.0005565, 0.0112504, 0.0040078,
0.0074051, 0.0063331, 0.0102157, 0.0047149, 0.0127409,
0.0089766, 0.0235059, 0.00578, 0.0143666, 0.0426174,
0.0173149, 0.0398941, 0.035563, 0.0175214, 0.0582518,
0.0636831, 0.04697, 0.068431, 0.1184043, 0.1461161,
0.162931, 0.3157118, 0.4525623, 0.4967857, 0.523506,
0.4821948, 0.3780588, 0.2820117, 0.207971, 0.1729326,
0.1142599, 0.0876062, 0.0766886, 0.0525184, 0.0380988,
0.0277054, 0.0357547, 0.0505474, 0.0848206, 0.0703005,
0.0717423, 0.1077341, 0.1199088, 0.1628344, 0.1448108,
0.1300938, 0.1409894, 0.1013017, 0.0803294, 0.0406706,
0.0344452, 0.0026992, 0.0173314, -0.0126389, 0.0120812,
-0.0051448, -0.0021643, -0.003559, 0.0138709, 0.0101377,
0.0098284, 0.0082292, 0.0137698, -0.0055618, 0.007306,
-0.0056595, -0.0078945, -0.0051356, -0.0072695, 0.01265,
0.0080837, -0.005344, -0.0036535, -0.0006843, 0.0050228,
-0.0080933, -0.0043142, -0.0044235, 0.0112926, 0.0010335,
-0.0113243, 0.0014798, 0.0005514, 0.0013085, -0.0028369,
-0.0065483, -0.0001666, -0.0056202, -0.0045502, 0.0086047,
-0.0072272, -0.0053373, -0.0014784, 0.0032562, 0.0008801,
0.0026446, 0.0031951, 0.0047381, 0.0085383, 0.0001579,
0.0023464, -3.99e-05, -0.0122899, -0.0036615, -0.0031306,
-0.0066083, -0.0083091, -0.0035266, 0.0042567, 0.0028019,
-0.0051763, 0.0021928, -0.0097969, 0.0021567, 0.0085299,
0.0064114, 0.0033908, -0.0043158, 0.0069325, 0.0008151,
0.0042793, 0.0013347, 0.0013185, 0.0038647, -0.0020497,
0.0123985, -0.0057112, 0.002795, -0.0045571, -0.0048399,
-0.0019391, -0.0034512, -0.0106117, 0.008804, -0.0092454,
-0.0025024, 0.0031131, -0.0067306, 0.0009606, -0.0045944,
-0.000978, -0.0070975])
arr_e_0 = np.asarray([0.0117934, 0.0232831, 0.0168164, 0.016756, 0.0112667,
0.0100075, 0.0099231, 0.0121869, 0.021429, 0.0105043,
0.025484, 0.0134925, 0.0096227, 0.0091661, 0.0091281,
0.0116373, 0.0234749, 0.0097467, 0.0149447, 0.0161787,
0.0083018, 0.0078142, 0.0077371, 0.0077135, 0.007965,
0.0080072, 0.0083331, 0.0081693, 0.0080592, 0.0081219,
0.0082476, 0.008897, 0.0250279, 0.0260982, 0.0097062,
0.0079405, 0.0075758, 0.0074112, 0.0073532, 0.0073761,
0.0074566, 0.0076131, 0.0076406, 0.0074831, 0.0074437,
0.0074479, 0.0074209, 0.0074945, 0.0074309, 0.007556,
0.0076618, 0.0079848, 0.0082724, 0.0084415, 0.0084575,
0.0085785, 0.0091171, 0.0113204, 0.0266042, 0.0351075,
0.0150392, 0.0099525, 0.0084158, 0.0078287, 0.0076499,
0.0075415, 0.0074585, 0.0073683, 0.0072875, 0.0072455,
0.0072661, 0.0072289, 0.0072093, 0.007192, 0.0071952,
0.0071795, 0.0071541, 0.007182, 0.0071747, 0.0071445,
0.0071336, 0.0071546, 0.0071329, 0.0071197, 0.007111,
0.0071184, 0.0070917, 0.0071031, 0.0071153, 0.0071178,
0.0070956, 0.0071312, 0.0071409, 0.0071443, 0.0071458,
0.0071629, 0.0071689, 0.0072234, 0.007265, 0.0072728,
0.0072859, 0.0073305, 0.0073767, 0.0074788, 0.0076235,
0.007508, 0.0074702, 0.0075216, 0.0075446, 0.0075961,
0.0076602, 0.0077166, 0.0078025, 0.0079166, 0.0079982,
0.0081365, 0.0082818, 0.0084539, 0.0086485, 0.0088334,
0.0091078, 0.0093325, 0.0096282, 0.0099459, 0.010298,
0.0107183, 0.0111722, 0.0116923, 0.0123477, 0.0131453,
0.0141059, 0.0153067, 0.0168664, 0.0188378, 0.0215785,
0.0252547, 0.0297239, 0.0341553, 0.0363284, 0.036487,
0.0359624, 0.0340507, 0.0302363, 0.0260919, 0.0226238,
0.0199234, 0.0178687, 0.0162593, 0.0149562, 0.0139467,
0.0131031, 0.0124185, 0.0119215, 0.0114997, 0.0111242,
0.0108195, 0.0105417, 0.0103237, 0.0101095, 0.0099069,
0.0096583, 0.0094356, 0.0092308, 0.0090096, 0.0088297,
0.0086338, 0.0084891, 0.0083431, 0.0082116, 0.0081362,
0.008016, 0.0079332, 0.0078449, 0.0077658, 0.0076912,
0.0076462, 0.007587, 0.0075248, 0.0074751, 0.0074872,
0.0073898, 0.0073925, 0.0073482, 0.0073209, 0.007292,
0.0072602, 0.0072301, 0.0072017, 0.007183, 0.0071619,
0.007144, 0.0071174, 0.007112, 0.00708, 0.0070853,
0.0070637, 0.0070514, 0.0070139, 0.0069797, 0.0070052,
0.0069708, 0.0069296, 0.006924, 0.0069337, 0.0069133,
0.0069052, 0.0068889, 0.0068652, 0.0068289, 0.0068375,
0.0068342, 0.0068225, 0.0068038, 0.0067748, 0.0068026,
0.0067666, 0.0067659, 0.0067589, 0.0067484, 0.0067405,
0.0067178, 0.006715, 0.0066678, 0.0066726, 0.0066721,
0.0066528, 0.006642, 0.0066683, 0.0066481, 0.0066452,
0.0066207, 0.0066431, 0.0066053, 0.0066193, 0.0066244,
0.0066009, 0.0066162, 0.0065871, 0.0065945, 0.0066129,
0.0065851, 0.0065817, 0.0065496, 0.0065723, 0.0065763,
0.0065389, 0.0065244, 0.0065359, 0.0065508, 0.0065261,
0.006513, 0.0064937, 0.0064965, 0.0065011, 0.0064914,
0.0064738, 0.005104])
arr_e_1 = np.asarray([0.0119812, 0.0235948, 0.0170881, 0.0169412, 0.0113467,
0.0100467, 0.0099591, 0.0122446, 0.021694, 0.0106207,
0.0258788, 0.0137264, 0.0098265, 0.0093254, 0.0092983,
0.0117886, 0.0238711, 0.0099137, 0.0151285, 0.0164322,
0.0084087, 0.0078611, 0.0077933, 0.0077606, 0.0080533,
0.0080753, 0.0083849, 0.0082235, 0.0080834, 0.0081785,
0.00828, 0.0089247, 0.0254183, 0.0266835, 0.0098427,
0.0079567, 0.0076163, 0.0074207, 0.0073728, 0.0073525,
0.0074369, 0.0076019, 0.0076312, 0.0074738, 0.0074779,
0.0074474, 0.00744, 0.0074944, 0.0074468, 0.0075523,
0.0076914, 0.0079919, 0.0083741, 0.0084816, 0.0085195,
0.0086432, 0.0091691, 0.0114414, 0.0271048, 0.0359963,
0.0153496, 0.0100647, 0.008485, 0.0079395, 0.0077323,
0.007629, 0.007561, 0.0074265, 0.0073354, 0.007391,
0.0073725, 0.0073246, 0.0073014, 0.007301, 0.0072968,
0.0072843, 0.0072793, 0.0072583, 0.0072565, 0.0072145,
0.0072381, 0.0072325, 0.0072183, 0.0072041, 0.0071931,
0.0072088, 0.0071794, 0.0072075, 0.0071874, 0.0071725,
0.0071942, 0.0071737, 0.0071835, 0.0072119, 0.0071954,
0.0072173, 0.0072499, 0.0072646, 0.0072882, 0.0073204,
0.0073508, 0.0073825, 0.007442, 0.0075377, 0.0076689,
0.0075563, 0.0075362, 0.0075632, 0.0075928, 0.0076414,
0.0077114, 0.0077809, 0.0078769, 0.0079524, 0.0080765,
0.0082101, 0.0083588, 0.0084939, 0.0087091, 0.008918,
0.0091502, 0.0094322, 0.0097226, 0.0100435, 0.010415,
0.0108302, 0.011312, 0.0118621, 0.0124791, 0.0132884,
0.0142738, 0.0155095, 0.0170857, 0.0191345, 0.0219161,
0.0256854, 0.0303414, 0.0348718, 0.037129, 0.0373102,
0.0367249, 0.0346941, 0.0307096, 0.0264297, 0.022881,
0.0200893, 0.0179581, 0.0163181, 0.0150394, 0.014018,
0.0132097, 0.0125433, 0.0120173, 0.0115888, 0.0112336,
0.0109438, 0.0106731, 0.0104799, 0.0102466, 0.0100184,
0.0098015, 0.0095945, 0.0093333, 0.0091293, 0.0089336,
0.0087198, 0.0085649, 0.0084356, 0.0082874, 0.0082099,
0.0080872, 0.0079842, 0.0079151, 0.0078377, 0.0077902,
0.007707, 0.007662, 0.0076153, 0.0075523, 0.0075291,
0.0074836, 0.0074488, 0.007429, 0.0073991, 0.0073745,
0.0073075, 0.0072881, 0.0072854, 0.0072833, 0.0072148,
0.0072024, 0.0072041, 0.0071856, 0.0071668, 0.0071128,
0.0071183, 0.0071181, 0.0070825, 0.0070735, 0.0070799,
0.00703, 0.0070211, 0.007016, 0.0069915, 0.0069892,
0.0069808, 0.0069451, 0.0069381, 0.0069487, 0.0069271,
0.0068951, 0.0068936, 0.0068922, 0.0068515, 0.0068546,
0.0068424, 0.0068702, 0.0068161, 0.0068288, 0.0068064,
0.0068164, 0.0067947, 0.0067576, 0.0067458, 0.0067581,
0.0067441, 0.0067195, 0.006722, 0.0067399, 0.0067166,
0.006718, 0.0067062, 0.0067045, 0.0066759, 0.0066714,
0.0066959, 0.0066707, 0.0066597, 0.0066539, 0.0066722,
0.0066292, 0.00664, 0.0066266, 0.0066505, 0.0066249,
0.0066093, 0.0066099, 0.0066379, 0.0065929, 0.0065849,
0.0065925, 0.0065547, 0.0065503, 0.0065823, 0.0065533,
0.006557, 0.005196])
tof_ws.setY(0, arr_y_0)
tof_ws.setY(1, arr_y_1)
tof_ws.setE(0, arr_e_0)
tof_ws.setE(1, arr_e_1)
return tof_ws
def create_test_container_ws():
"""
Creates data to represent a vesuvio container for testing
"""
###### Simulates LoadVesuvio with spectrum number 135-136 #################
can_ws = CreateSimulationWorkspace(Instrument='Vesuvio',
BinParams=[49,2,563],UnitX='TOF')
can_ws = CropWorkspace(can_ws,StartWorkspaceIndex=134,
EndWorkspaceIndex=135)
can_ws = ConvertToPointData(can_ws)
SetInstrumentParameter(can_ws, ParameterName='t0',
ParameterType='Number',Value='0.5')
SetInstrumentParameter(can_ws, ParameterName='sigma_l1',
ParameterType='Number', Value='0.021')
SetInstrumentParameter(can_ws, ParameterName='sigma_l2',
ParameterType='Number', Value='0.023')
SetInstrumentParameter(can_ws, ParameterName='sigma_tof',
ParameterType='Number', Value='0.3')
SetInstrumentParameter(can_ws, ParameterName='sigma_theta',
ParameterType='Number', Value='0.028')
SetInstrumentParameter(can_ws, ParameterName='hwhm_lorentz',
ParameterType='Number', Value='24.0')
SetInstrumentParameter(can_ws, ParameterName='sigma_gauss',
ParameterType='Number', Value='73.0')
# Algorithm allows separate parameters for the foils
SetInstrumentParameter(can_ws, ComponentName='foil-pos0',
ParameterName='hwhm_lorentz',
ParameterType='Number', Value='144.0')
SetInstrumentParameter(can_ws, ComponentName='foil-pos0',
ParameterName='sigma_gauss',
ParameterType='Number', Value='20.0')
SetInstrumentParameter(can_ws, ComponentName='foil-pos1',
ParameterName='hwhm_lorentz',
ParameterType='Number', Value='144.0')
SetInstrumentParameter(can_ws, ComponentName='foil-pos1',
ParameterName='sigma_gauss',
ParameterType='Number', Value='20.0')
arr_y_0 = np.asarray([-0.0064316, -0.0179638, -0.0104433, 0.0086, 0.0157299,
0.0032384, -0.0108936, -0.0051406, -0.0111891, -0.0186337,
0.0234711, 0.031463, 0.0227465, -0.0080165, -0.0040046,
0.0345261, 0.0176992, 0.009079, 0.0476342, 0.0316924,
0.015241, 0.0193196, 0.0111859, -0.0018898, 0.0339599,
0.0141428, 0.0396192, 0.0269686, 0.03091, 0.0173115,
-0.0171048, 0.0233843, 0.0509624, 0.0077161, -0.0061559,
0.0088456, 0.048873, 0.0109399, 0.0260844, 0.0507464,
0.0327567, 0.0741418, 0.0291152, 0.0560845, 0.0369916,
0.0579649, 0.0458347, 0.036699, 0.0329331, 0.0491814,
0.0728851, 0.0588705, 0.0693662, 0.0922184, 0.05289,
0.0452924, 0.0809479, 0.0596369, 0.0893579, 0.0892253,
0.0525219, 0.0937635, 0.0689257, 0.0784561, 0.0802131,
0.064883, 0.0547994, 0.0889854, 0.0434674, 0.0587243,
0.080357, 0.0368889, 0.0800238, 0.0574417, 0.0580969,
0.0534365, 0.0533057, 0.0217975, 0.0145923, 0.0636766,
0.0477083, 0.0096027, 0.0297145, 0.0384416, 0.0186823,
0.0351061, 0.010069, 0.011383, 0.0452154, 0.0356042,
0.0478847, 0.022823, 0.0532062, 0.03446, 0.0336823,
0.0582779, 0.0120418, 0.0345924, 0.0008595, 0.0313879,
0.0695951, 0.0274412, 0.028669, 0.0548636, 0.0397839,
-0.0107979, 0.055198, 0.0445078, 0.0535932, 0.0350566,
0.0742328, 0.0615778, 0.0772107, 0.0506143, 0.0599237,
0.0666392, 0.0611098, 0.0724487, 0.0837395, 0.0564134,
0.0650492, 0.038175, 0.0736518, 0.0865858, 0.0642039,
0.0276532, 0.0618787, 0.0474689, 0.0360936, 0.0191779,
0.0313978, 0.0214443, -0.0030741, 0.0175764, 0.006509,
0.0324557, 0.0314502, -0.0126514, -0.0234161, 0.0366117,
0.0275251, -0.004295, 0.0077237, 0.0156315, 0.0286153,
-0.0099457, 0.0155944, 0.0326512, 0.0473147, -0.0072659,
0.0592397, 0.0821841, 0.0807319, 0.0392619, 0.0854359,
0.0997388, 0.1179372, 0.1180594, 0.1297787, 0.1552712,
0.1363381, 0.1021708, 0.1045395, 0.0612393, 0.0427336,
0.0171585, 0.0127712, 0.040849, 0.0050523, 0.0063189,
0.0167139, 0.0179468, -0.0162102, 0.0030793, 0.0029782,
0.0102028, -8.58e-05, -0.017318, 0.0092343, -0.0146642,
-0.0244501, -0.0268491, 0.0295215, 0.0039507, 0.0036678,
0.0044288, 0.0177519, 0.0145861, 0.0090939, 0.0037256,
2.38e-05, -0.0077533, 0.0034861, -0.0052949, 0.010821,
0.0229786, 0.0047419, -0.0113241, 0.0016138, -0.0273965,
-0.0065906, 0.0139537, 0.0200601, 0.0211827, 0.006833,
-0.0170044, -0.0024626, 0.0083419, 0.00757, -0.0142494,
-0.0037699, 0.0404581, 0.0138674, -0.0060067, 0.0398204,
0.0127549, -0.046301, 0.0119001, -0.0250324, -0.0057125,
0.0089189, 0.0121784, 0.0375081, -1.91e-05, 0.0193739,
0.0242829, 0.0268932, 0.0115773, 0.0066936, -0.0208176,
-0.019704, 0.0019268, -0.0109214, -0.0153791, -0.0214004,
0.0028627, -0.0004157, 0.007054, 0.0397935, 0.0096358,
-0.0132388, 0.0209621, -0.013841, -0.0046241, -0.0151814,
0.0059456, 0.0014783, 0.019223, -0.042188, -0.0130235,
0.003799, 0.0038123, 0.0305194, 0.0005365, 0.0183533,
0.0141723, -0.0025998])
arr_y_1 = np.asarray([-0.0184444, 0.0019095, -0.0455784, -0.0145748, 0.0026701,
-0.0134154, 0.028545, -0.0648587, 0.0165036, 0.0010472,
0.0264008, -0.000845, 0.0114885, -0.00565, 0.0104464,
-0.0034481, 0.0024512, 0.037778, 0.023125, -0.0093555,
-0.0127704, -0.0066987, -0.0115083, 0.0180946, 0.0027219,
0.0111632, 0.0274628, 0.0236488, 0.0147109, 0.0229312,
-0.016507, 0.0005336, 0.0448731, 0.0203784, 0.0060545,
-0.0212516, 0.035153, 0.0302092, 0.03008, 0.0604827,
0.0566092, 0.0513835, 0.0202726, 0.0339036, 0.0151994,
0.0315787, 0.0057509, 0.0284349, 0.0286899, 0.0726158,
0.0674194, 0.0810876, 0.0671249, 0.0811294, 0.0610594,
0.0867094, 0.0695351, 0.0801913, 0.0565111, 0.0693537,
0.1103449, 0.0878698, 0.0527231, 0.0732721, 0.0923401,
0.0908683, 0.0835258, 0.0948236, 0.0650613, 0.056659,
0.0758801, 0.0626293, 0.0699271, 0.0827802, 0.0700214,
0.0765134, 0.0922516, 0.0733114, 0.049803, 0.035878,
0.0581801, 0.0323677, 0.0815313, 0.0514064, 0.0445783,
0.0562154, 0.0443888, 0.008912, 0.0606206, 0.0560397,
0.0417371, -0.0135556, 0.0534985, 0.0081161, 0.0169443,
-4.4e-05, 0.040644, 0.0104516, 0.0240633, 0.028008,
0.0371339, 0.0350788, 0.0457755, 0.0318831, -0.0005119,
0.0018598, 0.0300772, 0.0335128, 0.061657, 0.0554573,
0.0437408, 0.061889, 0.0921732, 0.0376576, 0.0988444,
0.0445555, 0.0703227, 0.0898311, 0.0733473, 0.0899112,
0.0824373, 0.0810492, 0.0714379, 0.0414468, 0.0614512,
0.0592597, 0.0360798, 0.0205073, 0.0483646, 0.0139891,
0.0882841, 0.0479525, 0.0388173, 0.0250203, 0.0384351,
0.0638443, 0.0096414, 0.0354468, 0.0316912, 0.0186341,
-0.0125283, 0.0154833, 0.00462, 0.0404921, -0.0005211,
0.029818, 0.0044235, 0.0206398, 0.0009539, 0.0005594,
0.037446, 0.0369625, 0.0683275, 0.0665141, 0.101871,
0.1093329, 0.1194542, 0.1333898, 0.1664608, 0.1649397,
0.175259, 0.118345, 0.0634636, 0.0557804, 0.0500694,
0.0280019, 0.0121106, 0.0168057, 0.0114285, 0.0031329,
0.0280022, 0.0169156, 0.0120129, -0.0279707, 0.0423801,
-0.0138001, 0.0212076, -0.0015319, 0.0054413, -0.0366226,
-0.0293535, 0.0119411, 0.0042779, -0.0012628, 0.0158553,
0.0278021, 0.028555, 0.0015432, -0.0142639, -0.0199164,
0.0290485, -0.0039975, -0.0183385, -0.0415988, -0.0253,
0.0006173, 0.0033673, 0.0167763, 0.0111136, 0.0237339,
0.0049641, -0.0069644, -0.0135646, 0.0044105, -0.0522625,
-0.0101628, -0.0150371, -0.0304262, 0.0086802, 0.0160923,
-0.0232054, -0.0138105, -0.0075974, 0.0081547, 0.0037978,
-0.0070225, -0.0260558, -0.0208546, 0.0088206, -0.0226834,
0.0007156, -0.0275574, 0.0144015, 0.0147563, -0.0020028,
0.0064436, -0.0095476, -0.0199967, 0.0040311, 0.0228361,
-0.0055117, 0.0224959, -0.0231696, 0.0102307, -0.006302,
-0.0073044, -0.0351271, 0.0071107, 0.0393013, 0.0443709,
-0.0222311, -0.0350912, -0.0018726, 0.0063499, -0.0513589,
-0.0096267, -0.0013027, -0.0024673, -0.0189589,
-0.0162803, -0.0173234, -0.0009156, -0.0005399,
-0.0043608, -0.0067056, 0.022813, 0.0284126])
arr_e_0 = np.asarray([0.0230255, 0.0285136, 0.0278016, 0.0269022, 0.0262664,
0.0258353, 0.0259937, 0.0262618, 0.0258454, 0.0248282,
0.0238628, 0.0238246, 0.0246311, 0.023901, 0.0239332,
0.0231553, 0.0225049, 0.0227407, 0.0230012, 0.0225421,
0.0209124, 0.0206623, 0.0204279, 0.0203694, 0.0211464,
0.0208934, 0.0204341, 0.0205134, 0.0199656, 0.0197581,
0.0198121, 0.019899, 0.0201708, 0.0203237, 0.0204234,
0.0202881, 0.0201209, 0.0197918, 0.0197584, 0.0200174,
0.0202669, 0.0205477, 0.0206379, 0.0202074, 0.0204441,
0.0204465, 0.0203216, 0.0202502, 0.0199544, 0.0199309,
0.0199195, 0.0204499, 0.0209561, 0.0205021, 0.0199711,
0.0200328, 0.0199275, 0.0198073, 0.0196735, 0.0197308,
0.0197267, 0.0197302, 0.0197865, 0.0196935, 0.0197985,
0.0199835, 0.0199828, 0.0197998, 0.0198703, 0.0196341,
0.0197208, 0.0195491, 0.0195935, 0.0195828, 0.0194911,
0.0195309, 0.0195855, 0.0194859, 0.0193847, 0.0194298,
0.0194951, 0.019288, 0.0193915, 0.0192903, 0.0190933,
0.0191178, 0.019358, 0.0193522, 0.019258, 0.0189404,
0.01917, 0.0194546, 0.0193987, 0.0193804, 0.0191402,
0.0191575, 0.0192531, 0.0191354, 0.0192329, 0.0192811,
0.0194866, 0.019492, 0.0194596, 0.0193178, 0.0196025,
0.0197131, 0.0196285, 0.0198129, 0.0197952, 0.0195803,
0.0196719, 0.0199433, 0.0199383, 0.0198931, 0.0198355,
0.0197274, 0.0198785, 0.0199787, 0.0199845, 0.0198012,
0.0198666, 0.0195942, 0.0198105, 0.0197628, 0.0193874,
0.0196567, 0.0195826, 0.0195638, 0.0195283, 0.0194818,
0.0196323, 0.0193939, 0.0194203, 0.01946, 0.0194142,
0.0193574, 0.0193521, 0.0194159, 0.0193695, 0.0195027,
0.0193381, 0.0194402, 0.0195899, 0.0193279, 0.0195576,
0.0192612, 0.0193962, 0.0195534, 0.0196608, 0.0197084,
0.0196138, 0.0196991, 0.019953, 0.0199974, 0.020195,
0.0202238, 0.020494, 0.0202805, 0.020242, 0.0200991,
0.0200551, 0.019844, 0.0197551, 0.0194613, 0.0193718,
0.0189254, 0.0190214, 0.0187476, 0.0187449, 0.0186371,
0.018621, 0.0185772, 0.018524, 0.0184678, 0.0184684,
0.0185374, 0.0185432, 0.0185213, 0.018265, 0.0184596,
0.0184681, 0.0184274, 0.0184251, 0.0185376, 0.0184997,
0.0183933, 0.018564, 0.0184466, 0.0185369, 0.0185825,
0.0183314, 0.0183555, 0.0184612, 0.018281, 0.0185122,
0.0185967, 0.0183728, 0.0184358, 0.0183768, 0.0183156,
0.0184472, 0.0184994, 0.0183912, 0.0183651, 0.0184242,
0.0183048, 0.0184598, 0.0184313, 0.0183639, 0.0184375,
0.0184526, 0.018531, 0.0184714, 0.0182927, 0.0183994,
0.0182822, 0.0182115, 0.018179, 0.0182282, 0.0183089,
0.0182901, 0.0182265, 0.0181894, 0.0182185, 0.018353,
0.0184154, 0.0182416, 0.0182187, 0.0183035, 0.0182682,
0.0182598, 0.0181597, 0.0182411, 0.0180839, 0.0182247,
0.0183014, 0.0182051, 0.0181903, 0.0182557, 0.0180708,
0.0182373, 0.0182055, 0.0182317, 0.0183493, 0.0180918,
0.0181887, 0.0180502, 0.0182541, 0.0180555, 0.0180123,
0.0180473, 0.0182195, 0.0180515, 0.0177164, 0.0179814,
0.0180734, 0.0143812])
arr_e_1 = np.asarray([0.023789, 0.0294311, 0.0280504, 0.0273557, 0.0265926,
0.0257798, 0.0259584, 0.0260586, 0.0261241, 0.0257214,
0.0245031, 0.0244296, 0.0248521, 0.0246276, 0.0247756,
0.0238112, 0.0231296, 0.0231833, 0.0233583, 0.0230252,
0.0213183, 0.021011, 0.0206966, 0.020729, 0.021218,
0.0209761, 0.020594, 0.0207126, 0.0199599, 0.0198765,
0.0197847, 0.0199151, 0.0200583, 0.0202125, 0.0206567,
0.0206533, 0.0204089, 0.0199888, 0.0198849, 0.0199277,
0.0201352, 0.0206807, 0.0207827, 0.0203237, 0.0204106,
0.0201915, 0.0203771, 0.0203619, 0.0201437, 0.0198691,
0.0199514, 0.0207126, 0.0212029, 0.0206547, 0.0201118,
0.0204618, 0.0203814, 0.0201323, 0.0199874, 0.0202107,
0.0202419, 0.0201038, 0.0202159, 0.0202272, 0.0203377,
0.0204234, 0.0204043, 0.020388, 0.020153, 0.0203499,
0.0202442, 0.0201723, 0.0202549, 0.0201766, 0.0201211,
0.0200602, 0.0200343, 0.0200279, 0.019925, 0.019952,
0.019614, 0.0199282, 0.0198002, 0.0197925, 0.0196108,
0.0196869, 0.0195932, 0.0196018, 0.0195817, 0.0195019,
0.019492, 0.0195958, 0.0196813, 0.019439, 0.0194971,
0.0194356, 0.0197636, 0.0195607, 0.0195493, 0.0195279,
0.0195924, 0.0196505, 0.0196284, 0.0196082, 0.0196781,
0.019746, 0.019889, 0.0201637, 0.0201219, 0.0200534,
0.0200922, 0.0200784, 0.0200024, 0.0201449, 0.020117,
0.0200801, 0.0201226, 0.0203233, 0.0201205, 0.02021,
0.0200909, 0.0200585, 0.020113, 0.0200584, 0.020128,
0.0200917, 0.0198064, 0.0197387, 0.0199648, 0.0198385,
0.0197984, 0.0198326, 0.0197822, 0.0194759, 0.0196054,
0.0197299, 0.0198596, 0.0198474, 0.0197408, 0.0196784,
0.0197141, 0.0198635, 0.0196888, 0.0196916, 0.0196915,
0.0196806, 0.0196815, 0.0199836, 0.0197445, 0.0197322,
0.0198709, 0.0201303, 0.0202369, 0.0203785, 0.0205381,
0.0206714, 0.020888, 0.0208476, 0.0208221, 0.0208354,
0.0203582, 0.0203288, 0.0198433, 0.0197333, 0.0196856,
0.0193885, 0.0191938, 0.0191046, 0.0190078, 0.0189047,
0.018783, 0.0189391, 0.0188861, 0.0188526, 0.0189847,
0.018757, 0.0188486, 0.018642, 0.0187655, 0.0186771,
0.0186561, 0.0186883, 0.0188492, 0.0188468, 0.0187125,
0.0187809, 0.0185535, 0.0188703, 0.0186958, 0.0187101,
0.0185693, 0.0188679, 0.0186083, 0.0185813, 0.0186211,
0.0185912, 0.0187011, 0.0185359, 0.0187209, 0.018684,
0.0187249, 0.018628, 0.018705, 0.0186467, 0.0187086,
0.0185878, 0.0187993, 0.0186011, 0.0187437, 0.0186582,
0.0186542, 0.0186185, 0.0186716, 0.0187768, 0.0188131,
0.0187172, 0.0185435, 0.0186035, 0.0185279, 0.0186264,
0.018595, 0.0186832, 0.0186239, 0.0186979, 0.0185913,
0.0186193, 0.0185713, 0.0185236, 0.0184545, 0.0185148,
0.0185635, 0.0185734, 0.0184435, 0.018529, 0.0183827,
0.0185307, 0.0183904, 0.0185231, 0.0184532, 0.0185611,
0.0183944, 0.0184912, 0.0185459, 0.0184528, 0.0184027,
0.018538, 0.0185994, 0.0185306, 0.0183201, 0.0183859,
0.018441, 0.0184685, 0.0183543, 0.0183412, 0.0182257,
0.0183943, 0.0146234])
can_ws.setY(0, arr_y_0)
can_ws.setY(1, arr_y_1)
can_ws.setE(0, arr_e_0)
can_ws.setE(1, arr_e_1)
return can_ws