Skip to content

Commit 45edaaf

Browse files
committed
fix: Sample->SampleRun
1 parent 72360c8 commit 45edaaf

File tree

2 files changed

+14
-11
lines changed

2 files changed

+14
-11
lines changed

docs/user-guide/amor/amor-reduction.ipynb

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -147,17 +147,20 @@
147147
"metadata": {},
148148
"outputs": [],
149149
"source": [
150-
"workflow[Filename[SampleRun]] = amor.data.amor_sample_run(608)\n",
151-
"workflow[SampleRotation[SampleRun]] = sc.scalar(0.85, unit='deg')\n",
152-
"ioq8 = workflow.compute(NormalizedIofQ).hist()\n",
150+
"runs = {\n",
151+
" '608': sc.scalar(0.85, unit='deg'),\n",
152+
" '609': sc.scalar(2.25, unit='deg'),\n",
153+
" '610': sc.scalar(3.65, unit='deg'),\n",
154+
" '611': sc.scalar(5.05, unit='deg'),\n",
155+
"}\n",
153156
"\n",
154-
"workflow[Filename[SampleRun]] = amor.data.amor_sample_run(609)\n",
155-
"workflow[SampleRotation[SampleRun]] = sc.scalar(2.25, unit='deg')\n",
156-
"ioq9 = workflow.compute(NormalizedIofQ).hist()\n",
157+
"results = {}\n",
158+
"for file, angle in runs.items():\n",
159+
" workflow[Filename[SampleRun]] = amor.data.amor_sample_run(file)\n",
160+
" workflow[SampleRotation[SampleRun]] = angle\n",
161+
" results[file] = workflow.compute(NormalizedIofQ).hist()\n",
157162
"\n",
158-
"workflow[Filename[SampleRun]] = amor.data.amor_sample_run(610)\n",
159-
"workflow[SampleRotation[SampleRun]] = sc.scalar(3.65, unit='deg')\n",
160-
"ioq10 = workflow.compute(NormalizedIofQ).hist()\n"
163+
"sc.plot(results, norm='log', vmin=1e-4)"
161164
]
162165
},
163166
{

src/ess/reflectometry/orso.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,8 @@ def parse_orso_sample(filename: Filename[SampleRun]) -> OrsoSample:
108108

109109

110110
def build_orso_measurement(
111-
sample_filename: Filename[Sample],
112-
reference_filename: Filename[Reference],
111+
sample_filename: Filename[SampleRun],
112+
reference_filename: Filename[ReferenceRun],
113113
instrument: OrsoInstrument,
114114
) -> OrsoMeasurement:
115115
"""Assemble ORSO measurement metadata."""

0 commit comments

Comments
 (0)