[Insight-users] best way to subsample/rescale a volume ?

Erkang Cheng ekyaya at gmail.com
Fri Jun 1 13:13:03 EDT 2012


Hi everyone:

I briefly summarize my questions.
What is the best way to subsample or rescale a volume? And do we need
low-pass filter to smooth the original volume?
If so, how to set sigma of RecursiveGaussianImageFilter ? Thanks.

I have tried these approaches by ITK.

1) Examples/Filtering/ResampleImageFilter1.cxx.

    only use ResampleImageFilter and not involve low-pass filter.

2) Examples/Filtering/SubsampleVolume.cxx.

   Before use ResampleImageFilter, a recursive RecursiveGaussianImageFilter
is used to smooth the original volume.
   And the parameters of guassian filter are set by:

     const double sigmaX = inputSpacing[0] * factorX;
     const double sigmaY = inputSpacing[1] * factorY;
     const double sigmaZ = inputSpacing[2] * factorZ;
     smootherX->SetSigma( sigmaX );
     smootherY->SetSigma( sigmaY );
     smootherZ->SetSigma( sigmaZ );

Which one is the appropriated way to subsample or rescale a volume.
I tried one volume by these methods. The result one the first one is much
clear than the second one which involved with low-pass filter.
The result of the second one is fuzzy in some degree.

I doubt the reason is the parameter simga  RecursiveGaussianImageFilter
affect the result.
There is a solution provided from

http://gerardus.googlecode.com/svn-history/r211/trunk/cpp/src/Resize3DImage.cxx

In there method, the parameters are set to:
        const double sigmaX = inputSpacing[0] * factorX * 0.61;
const double sigmaY = inputSpacing[1] * factorY * 0.61;
const double sigmaZ = inputSpacing[2] * factorZ * 0.61;

smootherX->SetSigma( sigmaX );
smootherY->SetSigma( sigmaY );
smootherZ->SetSigma( sigmaZ );

If we need smooth the volume and how to set the parameter
of RecursiveGaussianImageFilter? Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20120601/19723d01/attachment.htm>


More information about the Insight-users mailing list