[Insight-developers] Requiring a named input, problem with Convolution filter

Gaëtan Lehmann gaetan.lehmann at jouy.inra.fr
Tue Dec 13 14:45:53 EST 2011


Le 13 déc. 11 à 16:50, Bradley Lowekamp a écrit :

> Hello,
>
> I just seg-faulted the ConvolutionImageFilter, by apparently not  
> setting the Kernel.
>
> Looking at the Code it appears that the KernelInput is one of these  
> new fangled Named inputs. So, the way I think I see it now this  
> filter is not correctly setting that is has 2 required inputs. I am  
> not sure how to mark a named input as required, or quite what the  
> interaction of the indexed and named inputs when setting the number  
> of required inputs are.
>
> So,  I actually encountered this problem while trying to wrap this  
> filter for simpleITK. We are still using the "filter->SetInput( 1,  
> kernelImage )" method to set the indexed inputs. We don't  currently  
> have a good approach to deal with variable number of inputs, and  
> named inputs.

Hi Brad,

I've proposed a patch to deal with that issue:

   http://review.source.kitware.com/#change,3161

There are some inconsistencies in the naming caused by the  
preservation of the backward compatibility that should probably be  
addressed, but I think the functionalities are there.

Would that help to add the filter in SimpleITK?

Gaëtan



-- 
Gaëtan Lehmann
Biologie du Développement et de la Reproduction
INRA de Jouy-en-Josas (France)
tel: +33 1 34 65 29 66    fax: 01 34 65 29 09
http://mima2.jouy.inra.fr  http://www.itk.org
http://www.bepo.fr

-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 203 bytes
Desc: Ceci est une signature ?lectronique PGP
URL: <http://www.itk.org/mailman/private/insight-developers/attachments/20111213/cdc7e60b/attachment.pgp>


More information about the Insight-developers mailing list