pyfai-2024.1.0 result units changed
https://gitlab.esrf.fr/workflow/ewoksapps/ewoksxrpd/-/jobs/922122
radial_units = (2th_deg, chi_deg)
def parse_units(radial_units: Any) -> Tuple[str, str]:
if isinstance(radial_units, Unit):
radial_units = radial_units.name
if isinstance(radial_units, numpy.ndarray):
radial_units = radial_units.item()
if not isinstance(radial_units, str):
> raise TypeError(type(radial_units))
E TypeError: <class 'tuple'>
src/ewoksxrpd/tasks/utils/pyfai_utils.py:34: TypeError
The above exception was the direct cause of the following exception:
ndims = 2, external = False
bliss_task_inputs = {'detector': 'Pilatus1M', 'detector_name': 'p3', 'energy': 12, 'filename': '/tmp/pytest-of-root/pytest-0/sample_dataset0/sample_dataset.h5', ...}
tmpdir = local('/tmp/pytest-of-root/pytest-0/test_batch_integrate_task_Fals1')
@pytest.mark.parametrize("ndims", [1, 2])
@pytest.mark.parametrize("external", [False, True])
def test_batch_integrate_task(ndims, external, bliss_task_inputs, tmpdir):
> assert_batch_integrate(ndims, bliss_task_inputs, tmpdir, external=external)
src/ewoksxrpd/tests/test_batch_integrate.py:12:
It seems that in the 2D case, result.unit
not only refers to the radial unit but the azimuthal unit as well. Need to investigate other changes to azimuthal dimension in case of caking:
https://github.com/silx-kit/pyFAI/blob/main/doc/source/changelog.rst#20241-18012024