Closed
Description
Hi!
Have a question regarding the behaviour of resample_to_output
and resample_from_to
functions.
After resampling of the data, the orientation changes to default RAS, even if it had other orientation previously:
vol = nib.load(path)
print("Orientation before: ", nib.orientations.aff2axcodes(vol.affine))
target_vox_dim = (1, 1, 1)
resampled = nib.processing.resample_to_output(vol, target_vox_dim, order=3, mode='nearest')
print("Orientation after: ", nib.orientations.aff2axcodes(resampled.affine))
Orientation before: ('L', 'A', 'S')
Orientation after: ('R', 'A', 'S')
Expected behaviour: orientation of the resampled data shouldn't change
Is this expected behaviour?
Now if I want LAS orientation, I need to reorient data additionally after resampling.
Metadata
Metadata
Assignees
Labels
No labels