SlicerRt / SlicerRT

Open-source toolkit for radiation therapy research, an extension of 3D Slicer. Features include DICOM-RT import/export, dose volume histogram, dose accumulation, external beam planning (TPS), structure comparison and morphology, isodose line/surface generation, etc.
https://slicerrt.org
128 stars 60 forks source link

Automatic tests failing due to ITK errors about inability to load seg.vtm file #125

Closed cpinter closed 4 years ago

cpinter commented 4 years ago

23 automatic tests have been failing since October 29 due to error messages about seg.vtm files. These are the first failures: http://slicer.cdash.org/viewTest.php?onlyfailed&buildid=1734159

These failing tests prevent us from seeing any regressions in DVH and segment comparisons modules, so these would need to be fixed asap. I don't find any commit obviously suspicious from that time. There is one that is related to segmentation storage, but it seems to be unrelated after a quick glance.

This is the actual error:

ERROR: In D:\D\P\Slicer-0\Libs\vtkITK\vtkITKArchetypeImageSeriesReader.cxx, line 622
vtkITKArchetypeImageSeriesVectorReaderFile (0000000003BFEFD0): vtkITKArchetypeImageSeriesReader::ExecuteInformation: Cannot open D:/D/P/S-0-E-b/SlicerRT/Testing/Data/EclipseEnt_Structures.seg.vtm. ITK exception info: error in unknown:  Could not create IO object for reading file D:/D/P/S-0-E-b/SlicerRT/Testing/Data/EclipseEnt_Structures.seg.vtm
  Tried to create one of the following:
    BMPImageIO
    BioRadImageIO
    DCMTKImageIO
    GDCMImageIO
    GiplImageIO
    JPEGImageIO
    LSMImageIO
    MGHImageIO
    MINCImageIO
    MRCImageIO
    MetaImageIO
    NiftiImageIO
    NrrdImageIO
    PNGImageIO
    StimulateImageIO
    TIFFImageIO
    VTKImageIO
    MRMLIDImageIO
  You probably failed to set a file suffix, or
    set the suffix to an unsupported type.

ERROR: In D:\D\P\Slicer-0-build\VTK\Common\ExecutionModel\vtkExecutive.cxx, line 782
vtkCompositeDataPipeline (0000000003C307E0): Algorithm vtkITKArchetypeImageSeriesVectorReaderFile(0000000003BFEFD0) returned failure for request: vtkInformation (0000000003C28A40)
  Debug: Off
  Modified Time: 4891
  Reference Count: 1
  Registered Events: (none)
  Request: REQUEST_INFORMATION
  FORWARD_DIRECTION: 0
  ALGORITHM_AFTER_FORWARD: 1

ERROR: In D:\D\P\Slicer-0\Libs\MRML\Core\vtkMRMLSegmentationStorageNode.cxx, line 537
vtkMRMLSegmentationStorageNode (0000000003BFDA30): ReadBinaryLabelmapRepresentation: Error reading image!
cpinter commented 4 years ago

Somewhat related: there is one further test that is failing due to changes in Slicer core, namely the DICOM widgets. http://slicer.cdash.org/testDetails.php?test=9814070&build=1733317

The issue here seems easy to fix: Traceback (most recent call last): File "/Volumes/Dashboards/Preview/S-0-E-b/SlicerRT/DicomRtImportExport/Testing/Python/DicomRtImportTest.py", line 37, in test_DicomRtImportTest_FullTest1 self.TestSection_OpenTempDatabase() File "/Volumes/Dashboards/Preview/S-0-E-b/SlicerRT/DicomRtImportExport/Testing/Python/DicomRtImportTest.py", line 87, in TestSection_OpenTempDatabase self.dicomWidget.onDatabaseDirectoryChanged(self.dicomDatabaseDir) AttributeError: 'DICOMWidget' object has no attribute 'onDatabaseDirectoryChanged'

Sunderlandkyl commented 4 years ago

Copied from email:

The first issue has to do with loading polydata segmentations, and the WIP fix is in this pull request: https://github.com/Slicer/Slicer/pull/1269 I haven't looked into the DICOM error yet, but I will look at it soon.

cpinter commented 4 years ago

Thanks! Do you know why the tests started failing on Oct 29 though? There does not seem to be any related change (neither an ITK update nor any change around vtkITKArchetype...).

Sunderlandkyl commented 4 years ago

This commit: https://github.com/Slicer/Slicer/commit/81b762a373dedec6572b64228ade3f5a25b5dd75. We didn't use vtkITKArchetypeImageSeriesVectorReaderFile prior to this.

cpinter commented 4 years ago

Ah, not having used the archetype reader is the reason! Thanks.

Having 22 out of 70 tests failing because of this is very bad, so please if you have the chance finish the pull request. It will be very hard to track down regressions like this, especially that now we have an active contributor.

Sunderlandkyl commented 4 years ago

Updated the pull request, Tests should pass again once it is integrated.

cpinter commented 4 years ago

Thank you very much, @Sunderlandkyl, I really appreciate the quick action!

cpinter commented 4 years ago

@Sunderlandkyl's fix is integrated in https://github.com/Slicer/Slicer/commit/8ea69453690690cee3de21e61e97122622c51e5d

Sunderlandkyl commented 4 years ago

All tests related to the vtkITKArchetype reader are now passing. Only py_DicomRtImportTest is now failing.

cpinter commented 4 years ago

Indeed, thank you very much!