[vtk-developers] How can I test my PolyData Algorithm?

Kilgus, Thomas t.kilgus at Dkfz-Heidelberg.de
Thu Jan 17 03:23:23 EST 2013


Hi there,

I have an algorithm generating a vtkPolyData as output. I would like to write a test, in order to make sure that my algorithm generates the same output every day (even though there might be changes to the algorithm or to surrounding classes). What is a nice way to do this?

I thought I could save a generated PolyData as "ground truth" and compare it point wise to the generated output. However, my output data contains lots of 3D floating-point points and thus I have to perform lots of comparisons between floating-point numbers and this can be difficult for different data or 32Bit/64Bit Systems.

I was wondering if there are any methods/classes already meant general testing purposes? Anything I could reuse for comparing two PolyDatas or anything to make sure my algorithm provides the same result for the same data. I tried to look into tests of other VTK classes but couldn't really find anything. Any suggestions?

Regards
Thomas

Thomas Kilgus
German Cancer Research Center (DKFZ)
Div. Medical and Biological Informatics
Junior group: Computer-assisted Interventions (E131)
Im Neuenheimer Feld 280
69120 Heidelberg, Germany
Phone: +49(0) 6221-42-3545


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtk-developers/attachments/20130117/e42beb4c/attachment.html>


More information about the vtk-developers mailing list