Name

resample - Resample image by an arbitrary factor - both 'pixel size' and image size are changed.

Usage

output = resample(input, ratio)

Input

input
image to be resampled or a filename containing the image to be resampled. The input image can be either 2D image or 3D volume.
ratio

resampling ratio  `r`; if <1, the output image is reduced; if =1, the output image is a copy of input image; if >1, the output image is blown up. In terms of pixel size, if the original pixel size is  `p` Angstroms, pixel size in the resampled image is  `p/r`

Output

output
image with modified size.

Description

This function is used to change the 'physical pixel size'.

Method

Input image is low-passed filtered using a Butterworth low-pass filter to the limiting fequency calculated from the decimatio ratio and subsequently is resampled using non-uniform FFT technique. The method yields virtually perfect results, i.e., the power spectrum of resampled image is the same as the power spectrum of the output image. Output image size depends on the decimation ratio.

Author / Maintainer

Pawel A. Penczek

Keywords

category 1
FUNDAMENTALS

Files

fundamentals.py

See also

image_decimate

Maturity

alpha
works

Bugs

None. It is perfect.

resample (last edited 2013-07-01 13:12:24 by localhost)