@@ -737,7 +737,7 @@ def _conditional_downsampling(in_file, in_mask, zoom_th=4.0):
737
737
import nibabel as nb
738
738
import nitransforms as nt
739
739
import numpy as np
740
- from nitransforms .resampling import apply as transform
740
+ from nitransforms .resampling import apply as applyxfm
741
741
from scipy .ndimage .filters import gaussian_filter
742
742
743
743
img = nb .load (in_file )
@@ -760,13 +760,13 @@ def _conditional_downsampling(in_file, in_mask, zoom_th=4.0):
760
760
identity = nt .Affine ()
761
761
762
762
newref = nb .Nifti1Image (np .zeros (newshape , dtype = np .uint8 ), newaffine )
763
- transform (identity , img , reference = newref ).to_filename (out_file )
763
+ applyxfm (identity , img , reference = newref ).to_filename (out_file )
764
764
765
765
mask = nb .load (in_mask )
766
766
mask .set_data_dtype (float )
767
767
mdata = gaussian_filter (mask .get_fdata (dtype = float ), scaling )
768
768
floatmask = nb .Nifti1Image (mdata , mask .affine , mask .header )
769
- newmask = transform (identity , floatmask , reference = newref )
769
+ newmask = applyxfm (identity , floatmask , reference = newref )
770
770
hdr = newmask .header .copy ()
771
771
hdr .set_data_dtype (np .uint8 )
772
772
newmaskdata = (newmask .get_fdata (dtype = float ) > 0.5 ).astype (np .uint8 )
0 commit comments