We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c3a6afe commit dd1b7c0Copy full SHA for dd1b7c0
src/ess/estia/load.py
@@ -27,10 +27,11 @@ def load_mcstas_events(
27
ybins = sc.linspace('y', -0.25, 0.25, 65)
28
da = da.bin(x=xbins, y=ybins).rename_dims({'y': 'stripe'})
29
da.coords['stripe'] = sc.arange('stripe', 0, 64)
30
- da.coords['z_index'] = sc.arange('x', 0, 14 * 32)
+ da.coords['z_index'] = sc.arange('x', 14 * 32 - 1, -1, -1)
31
32
# Information is not available in the mcstas output files, therefore it's hardcoded
33
da.coords['sample_position'] = sc.vector([0.264298, -0.427595, 35.0512], unit='m')
34
+ da.coords['source_position'] = sc.vector([0, 0, 0.0], unit='m')
35
da.coords['detector_position'] = sc.vector(
36
tuple(map(float, da.coords['position'].value.split(' '))), unit='m'
37
)
@@ -65,4 +66,6 @@ def load_mcstas_events(
65
66
da.coords['sample_length'].value
67
68
da.coords["beam_size"] = sc.scalar(2.0, unit='mm')
69
+
70
+ da = da.fold('x', sizes={'blade': 14, 'wire': 32})
71
return RawDetectorData[RunType](da)
0 commit comments