[ITK] Using spatialObjects as filters

Leslie Solorzano lesolorzanov at gmail.com
Thu Apr 9 13:27:29 EDT 2015


Thanks Matt, helped a lot.

I know there are somethings I could find inside the ITK code but I'd like
to ask you a few questions:
Are the gaussians normalized during this calculus?
Can I change the maximum value?
The variances help me adjust the radius but can I actually limit it?
is the variance related to the actual radius in voxels? say: a variance of
sigma would give me a 99.7% of the values under a radius of 3*sigma?
what if I use the variance sigma but I want to limit it to a 2*sigma
raidus?
can I change the mean?

Thanks!

Leslie

2015-04-09 16:38 GMT+02:00 Matt McCormick <matt.mccormick at kitware.com>:

> On Thu, Apr 9, 2015 at 9:17 AM, Leslie Solorzano <lesolorzanov at gmail.com>
> wrote:
> > Hello world.
>
> :-)
>
>
> > I want to use a gaussianSpatialObject and a
> > SpatialObjectToImageStatisticsCalculator to filter an image and make a
> > gaussian convolution. Why not using a DiscreteGaussianImageFilter? easy,
> I
> > need a gaussian with different radii in each dimension and I need to be
> able
> > to set the size, the maximum value and the sigma, which only a
> > gaussianSpatialObject can offer me.
>
> > is there anyway I can use DiscreteGaussianImageFilter with different
> radii?
> > can I set the maximum value?
>
> Yes, DiscreteGaussianImageFilter will give much better performance.
>
> To set a different Gaussian width in each direction, something like:
>
>   typedef itk::DiscreteGaussianImageFilter< ImageType, ImageType>
> GaussianFilterType;
>   typedef GaussianFilterType::ArrayType VariancesType;
>   VariancesType variances;
>   variances[0] = 1.1;
>   variances[1] = 0.5;
>   variances[2] = 7.7;
>   GaussianFilterType::Pointer gaussianFilter = GaussianFilterType::New();
>   gaussianFilter->SetVariance( variances );
>
> would set different variances in each direction for a 3D image.
>
> HTH,
> Matt
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20150409/2e01349f/attachment.html>


More information about the Community mailing list