SimpleITK / SlicerSimpleFilters

A Module for Slicer3D to provide a simple GUI to image filters from the Insight Toolkit.
Other
1 stars 12 forks source link

2 Unknown SimpleITK classes #11

Closed jamesobutler closed 5 years ago

jamesobutler commented 5 years ago

When using Slicer 4.10.0, opening the SimpleFilters module reveals the following errors in the python interactor:

Unknown SimpleITK class "CoherenceEnhancingDiffusionImageFilter".
Unknown SimpleITK class "ObjectnessMeasureImageFilter".

This is also seen in the log of a failed SimpleFiltersModuleTest on the chiasma.queens build site, so I don't believe it is specific to my system.

blowekamp commented 5 years ago

Thanks for the report. The error/warning can safely be ignored, but it should be fixed.

The message is coming from here: https://github.com/SimpleITK/SlicerSimpleFilters/blob/92cbe91774350aca201b01de91ec1fa265173789/SimpleFilters/SimpleFilters.py#L104

These filters come from ITK modules which on not enabled currently in the Slicer configuration. The correct thing to do is to check sitk::Version::ITKModulesEnabled() for the module in the json file that is specified. If the module is not there then simply don't produce an error/warning.