resample_image - Man Page


usage: resample_image (--shape|--dim|--reference) [options] input output

Resample an image to different dimensions.

positional arguments


Input image


Output image


-h, ā€‰--help

show this help message and exit

-i {nearest,linear,cubic}, --interp {nearest,linear,cubic}

Interpolation (default: linear)

-o {centre,corner}, --origin {centre,corner}

Resampling origin (default: centre)

-dt {char,short,int,float,double}, --dtype {char,short,int,float,double}

Data type (default: data type of input image)

-n, ā€‰--nosmooth

Do not smooth image when downsampling

Resampling destination

Specify the resampling destination space using one of the following options. Note that the --reference option will cause the field-of-view of the input image to be changed to that of the reference image.

-s X,Y,Z,..., --shape X,Y,Z,...

Output shape

-d X,Y,Z,..., --dim X,Y,Z,...

Output voxel dimensions

-r IMAGE, --reference IMAGE

Resample input to the space of this reference image(overrides --origin)


March 2024 resample_image 3.18.1