[Insight-developers] Ctest --compare fails on vector images

Luis Ibanez luis.ibanez at kitware.com
Sat Nov 20 12:55:04 EST 2010


Hi Danielle,

Thanks for pointing this out.

Yeap, that's the case.

The --compare option is implemented in

    ITK/Code/Common/itkMainTest.h

The implementation of RegressionTestImage() in

    ITK/Code/Common/itkMainTest.h

is not appropriate for VectorImages.
It uses by default an image of type

typedef itk::Image< double, ITK_TEST_DIMENSION_MAX > ImageType;


with #define ITK_TEST_DIMENSION_MAX 6


When reading an image of multiple components,
only the first component will be seen in this filter.

I have now enter this as a feature request in:
http://public.kitware.com/Bug/view.php?id=11489


The implementation will require to discover at
run time whether the input image is a vector image,
and... to define a metric for comparing vector images.


Would you be interested in giving it a shot at
implementing a fix ?


     Thanks


          Luis


-----------------------------------------------------------------
On Fri, Nov 19, 2010 at 5:08 PM, Danielle Pace <danielle.pace at kitware.com>wrote:

> Hi all,
>
> Is it well-known that using ctest's add_test( ... --compare ... )
> functionality will fail with vector images?
>
> I've tried it on two vector images (.mhd) which I know to be different, and
> the comparison passes.  This is obviously not correct behavior.
>
> Thanks very much,
>
> Danielle
>
> --
> Danielle Pace, M.ESc.
> Research and Development Engineer
> Kitware Inc.,
> North Carolina Office
>
> www.kitware.com
> 919-969-6990 X 319
>
>
> _______________________________________________
> 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://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-developers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/mailman/private/insight-developers/attachments/20101120/faa8531e/attachment.htm>


More information about the Insight-developers mailing list