[Insight-users] itkConvolutionImageFilter

Jan Funke funke at ini.ch
Fri Jun 10 08:31:40 EDT 2011


Dear Insight-users and -developers,

I'm very glad that we have a convolution filter now in ITK-4.0.0. This is much 
more convenient than using the neighborhood iterators explicitly every time.

However, I belief that at least the documentation of this filter is incomplete.  
The points I noticed are:

• It is unclear how the filter handles the border cases where the kernel does not 
  completely overlap with the image. By looking at the source code I found that 
  there is a separation of the input image according to its faces. However, it 
  seems as if the operation applied to them is the same everywhere. I understand 
  that this is the inner product of the pixels in the respective neighborhoods.  
  Therefore I would expect an image to become darker at the borders when convolved 
  with a positive constant kernel. However, this is not the case. It would be nice 
  if the documentation could shed some light on this issue.

• It is also unclear what exactly happens if the kernel is even-sized. The 
  resolution of the output image is the same as the input image. I guess one of 
  the 2^n center pixels is just used as the center of the kernel and shifted over 
  the whole input image. Again, a note in the documentation on that would be nice.

• It should be mentioned somewhere whether the normalization of the kernel is 
  enabled or disabled by default.

By the way, I would really appreciate different border handling methods as it is 
provided by the MATLAB conv2 function (i.e., padding with zeros or cropping to 
the 'valid' convolution area). If someone could point me in the right direction 
on how to implement that using faces, I might even do it ;)

Cheers,
Jan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110610/df3e8367/attachment.pgp>


More information about the Insight-users mailing list