Skip to content

Axes Validators

Source

Axes validation utilities.

check_axes_validity(axes)

Sanity check on axes.

The constraints on the axes are the following: - must be a combination of 'STCZYX' - must not contain duplicates - must contain at least 2 contiguous axes: X and Y

Axes do not need to be in the order 'STCZYX', as this depends on the user data.

Parameters:

  • axes (str) –

    Axes to validate.

check_czi_axes_validity(axes)

Check if the provided axes string is valid for CZI files.

CZI axes is always in the "SC(Z/T)YX" format, where Z or T are optional, and S and C can be singleton dimensions, but must be provided.

Parameters:

  • axes (str) –

    The axes string to validate.

Returns:

  • bool

    True if the axes string is valid, False otherwise.