[Insight-users] Passing an image to NormalizedCorrelationImageFilter::SetTemplate

Markus Neuner neuner.markus at gmx.net
Thu Feb 3 09:52:16 EST 2011


Hi David,

You need to generate the kernel image before passing it to the operator
with:
   extractFilter->Update();
and you must generate the kernel with:
   UnsignedCharImageType::SizeType radius;
   radius[0] = 10;
   radius[1] = 10;
   kernelOperator.CreateToRadius(radius);
Then it should work.
NOTE: The radius should match your extracted image, here it is chosen to
be 10 as an example.

Attached is a working example where the VTK stuff was stripped.

Cheers, Markus

On 21.10.2010 17:56, David Doria wrote:
>
>     Yes. It uses an AnnulusOperator rather than a piece of an image.
>
>     David
>
>
> After some poking around, it looks like ImageKernelOperator is what
> should be used.
>
> However, the output of the correlation (after being rescaled to 0-255)
> is all black:
> http://www.vtk.org/Wiki/ITK/Examples/Images/NormalizedCorrelationImageFilter
>
> Any thoughts?
>
> David
>
>
> _____________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.html
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users
>   
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110203/ca1776df/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: NormalizedCorrelationImageFilter.cxx
Type: text/x-c++src
Size: 3119 bytes
Desc: not available
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110203/ca1776df/attachment.cxx>


More information about the Insight-users mailing list