nnUNET failed to load segmentation in DentalSegmentator & totalSegmentator

chz31
Mon, 16 Jun 2025 20:22:24 +0000
Support

I am using Ubuntu 22.04 and Slicer 5.9.0. The DentalSegmentator showed “failed to load segmentation; something is wrong with nnUnet processing”

Here is the error log:

[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Session start time .......: 20250616_150812
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Slicer version ...........: 5.9.0-2025-06-14 (revision 33686 / 7a97a67) linux-amd64 - installed release
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Operating system .........: Linux / 6.8.0-60-generic / #63~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Apr 22 19:00:15 UTC 2 / UTF-8 - 64-bit
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Memory ...................: 256950 MB physical, 2047 MB virtual
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - CPU ......................: GenuineIntel Intel(R) Xeon(R) w9-3575X, 44 cores, 88 logical processors
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - VTK configuration ........: OpenGL2 rendering, TBB threading
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Qt configuration .........: version 5.15.2, with SSL, requested OpenGL 3.2 (core profile)
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - DCMTK configuration ......: version 3.6.8, no SSL
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Internationalization .....: disabled, language=
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Developer mode ...........: enabled
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Application path .........: /home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin
[DEBUG][Qt] 16.06.2025 15:08:12 [] (unknown:0) - Additional module paths ..: slicer.org/Extensions-33686/NNUNet/lib/Slicer-5.9/qt-scripted-modules, slicer.org/Extensions-33686/PyTorch/lib/Slicer-5.9/qt-scripted-modules, slicer.org/Extensions-33686/DentalSegmentator/lib/Slicer-5.9/qt-scripted-modules, slicer.org/Extensions-33686/SlicerPythonTestRunner/lib/Slicer-5.9/qt-scripted-modules
[DEBUG][Python] 16.06.2025 15:08:15 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Slicer-5.9/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:40) - Scripted subject hierarchy plugin registered: SegmentEditor
[DEBUG][Python] 16.06.2025 15:08:15 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Slicer-5.9/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:40) - Scripted subject hierarchy plugin registered: SegmentStatistics
[DEBUG][Qt] 16.06.2025 15:08:15 [] (unknown:0) - Switch to module:  "Welcome"
[DEBUG][Qt] 16.06.2025 15:08:24 [] (unknown:0) - Switch to module:  "PyTorchUtils"
[DEBUG][Qt] 16.06.2025 15:08:33 [] (unknown:0) - Switch to module:  "DentalSegmentator"
[DEBUG][Qt] 16.06.2025 15:08:39 [] (unknown:0) - Switch to module:  "SampleData"
[DEBUG][Python] 16.06.2025 15:08:41 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../lib/Slicer-5.9/qt-scripted-modules/SampleData.py:408) - Verifying checksum
[DEBUG][Python] 16.06.2025 15:08:41 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../lib/Slicer-5.9/qt-scripted-modules/SampleData.py:408) - File already exists and checksum is OK - reusing it.
[DEBUG][Python] 16.06.2025 15:08:41 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../lib/Slicer-5.9/qt-scripted-modules/SampleData.py:408) - Requesting load PreDentalSurgery from /home/zhang/.cache/slicer.org/Slicer/SlicerIO/PreDentalSurgery.gipl.gz ...
[DEBUG][Qt] 16.06.2025 15:08:41 [] (unknown:0) - "Volume" Reader has successfully read the file "/home/zhang/.cache/slicer.org/Slicer/SlicerIO/PreDentalSurgery.gipl.gz" "[0.34s]"
[DEBUG][Python] 16.06.2025 15:08:41 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../lib/Slicer-5.9/qt-scripted-modules/SampleData.py:408) - Load finished
[DEBUG][Python] 16.06.2025 15:08:41 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../lib/Slicer-5.9/qt-scripted-modules/SampleData.py:408) - Verifying checksum
[DEBUG][Python] 16.06.2025 15:08:41 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../lib/Slicer-5.9/qt-scripted-modules/SampleData.py:408) - File already exists and checksum is OK - reusing it.
[DEBUG][Python] 16.06.2025 15:08:41 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../lib/Slicer-5.9/qt-scripted-modules/SampleData.py:408) - Requesting load PostDentalSurgery from /home/zhang/.cache/slicer.org/Slicer/SlicerIO/PostDentalSurgery.gipl.gz ...
[DEBUG][Qt] 16.06.2025 15:08:42 [] (unknown:0) - "Volume" Reader has successfully read the file "/home/zhang/.cache/slicer.org/Slicer/SlicerIO/PostDentalSurgery.gipl.gz" "[0.35s]"
[DEBUG][Python] 16.06.2025 15:08:42 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../lib/Slicer-5.9/qt-scripted-modules/SampleData.py:408) - Load finished
[DEBUG][Qt] 16.06.2025 15:08:46 [] (unknown:0) - Switch to module:  "DentalSegmentator"
[INFO][Python] 16.06.2025 15:08:50 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/slicer.org/Extensions-33686/NNUNet/lib/Slicer-5.9/qt-scripted-modules/SlicerNNUNetLib/InstallLogic.py:56) - nnUNet is already installed (2.6.2) and compatible with requested version (nnunetv2).
[DEBUG][Python] 16.06.2025 15:08:50 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/lib/python3.12/site-packages/urllib3/connectionpool.py:1049) - Starting new HTTPS connection (1): www.google.com:443
[DEBUG][Python] 16.06.2025 15:08:50 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/lib/python3.12/site-packages/urllib3/connectionpool.py:544) - https://www.google.com:443 "GET / HTTP/1.1" 200 None
[DEBUG][Python] 16.06.2025 15:08:50 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/lib/python3.12/site-packages/urllib3/connectionpool.py:1049) - Starting new HTTPS connection (1): api.github.com:443
[DEBUG][Python] 16.06.2025 15:08:50 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/lib/python3.12/site-packages/urllib3/connectionpool.py:544) - https://api.github.com:443 "GET /repos/gaudot/SlicerDentalSegmentator HTTP/1.1" 200 1477
[DEBUG][Python] 16.06.2025 15:08:50 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/lib/python3.12/site-packages/urllib3/connectionpool.py:1049) - Starting new HTTPS connection (1): api.github.com:443
[DEBUG][Python] 16.06.2025 15:08:50 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/lib/python3.12/site-packages/urllib3/connectionpool.py:544) - https://api.github.com:443 "GET /repos/gaudot/SlicerDentalSegmentator/releases HTTP/1.1" 200 817
[DEBUG][Python] 16.06.2025 15:08:51 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/lib/python3.12/site-packages/urllib3/connectionpool.py:1049) - Starting new HTTPS connection (1): api.github.com:443
[DEBUG][Python] 16.06.2025 15:08:51 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/lib/python3.12/site-packages/urllib3/connectionpool.py:544) - https://api.github.com:443 "GET /repos/gaudot/SlicerDentalSegmentator/releases/147040025/assets HTTP/1.1" 200 603
[ERROR][Python] 16.06.2025 15:08:54 [Python] (/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/Python/slicer/util.py:3146) - Failed to load the segmentation.
Something went wrong during the nnUNet processing.
Please check the logs for potential errors and contact the library maintainers.

The pytorch util showed pytorch properly installed:

I also tried totalSegmentator, which showed below errors:

Traceback (most recent call last):
  File "/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/Python/slicer/util.py", line 3392, in tryWithErrorDisplay
    yield
  File "/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/slicer.org/Extensions-33686/TotalSegmentator/lib/Slicer-5.9/qt-scripted-modules/TotalSegmentator.py", line 307, in onApplyButton
    self.logic.process(self.ui.inputVolumeSelector.currentNode(), self.ui.outputSegmentationSelector.currentNode(),
  File "/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/slicer.org/Extensions-33686/TotalSegmentator/lib/Slicer-5.9/qt-scripted-modules/TotalSegmentator.py", line 1046, in process
    self.processVolume(inputFile, inputVolume,
  File "/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/slicer.org/Extensions-33686/TotalSegmentator/lib/Slicer-5.9/qt-scripted-modules/TotalSegmentator.py", line 1113, in processVolume
    self.logProcessOutput(proc)
  File "/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/slicer.org/Extensions-33686/TotalSegmentator/lib/Slicer-5.9/qt-scripted-modules/TotalSegmentator.py", line 892, in logProcessOutput
    raise CalledProcessError(retcode, proc.args, output=proc.stdout, stderr=proc.stderr)
subprocess.CalledProcessError: Command '['/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/bin/../bin/PythonSlicer', '/home/zhang/Slicer-5.9.0-2025-06-14-linux-amd64/lib/Python/bin/TotalSegmentator', '-i', '/tmp/Slicer-zhang/__SlicerTemp__2025-06-16_15+19+33.235/total-segmentator-input.nii', '-o', '/tmp/Slicer-zhang/__SlicerTemp__2025-06-16_15+19+33.235/segmentation', '--ml', '--task', 'total']' returned non-zero exit status 1.

7 posts - 2 participants