Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NXmx: read data_scale_factor #756

Merged
merged 12 commits into from
Oct 30, 2024
24 changes: 24 additions & 0 deletions tests/nexus/test_mpccd_nexus.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
from __future__ import annotations

import dxtbx


def test_mpccd_nexus_gain(dials_data):
"""
Tests SACLA MPCCD image from CXI.DB 221
Includs parameter data_scale_factor, which accounts for a gain of 10
ndevenish marked this conversation as resolved.
Show resolved Hide resolved
"""

try:
h5path = (
dials_data("image_examples", pathlib=True)
/ "SACLA-MPCCD-run197287-0-nexus.h5"
)
except Exception as e:
print(type(e), str(e))
raise
img = dxtbx.load(h5path)

d = img.get_detector()

assert d[0].get_gain() == 10
Loading