determine_slice_axis
- bidsaid.metadata.determine_slice_axis(nifti_file_or_img=None, nifti_header=None)[source]
Determine the slice axis.
Uses “slice_end” plus one to determine the likely slice axis.
Parameters
- nifti_file_or_img
str,Path, orNifti1Image, default=None Path to the NIfTI file or a NIfTI image. Must be specified if
nifti_headeris None.- nifti_header
Nifti1Header, default=None Path to the NIfTI file or a NIfTI image. Must be specified if
nifti_file_or_imgis None.
Returns
- int
A number representing the slice axis.
- nifti_file_or_img