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

Bradley Lowekamp blowekamp at mail.nih.gov
Tue Dec 13 16:00:20 EST 2011


Hello,

I thought I saw those methods some place!  This is exactly what is needed for the filters in the Convolution sub-module, I think almost all of them are not setting the number of required inputs.

With the new feature freeze, It's unclear when this patch can be merged?

For SimpleITK I still need to add some improvements to handle these named inputs to the code generation system.

On Dec 13, 2011, at 2:45 PM, Gaëtan Lehmann wrote:

> 
> 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
> 



More information about the Insight-developers mailing list