On starting git-latest invesalius3 I get the message (repeated):
Traceback (most recent call last):
File "/usr/lib/python3.10/site-packages/wx/lib/agw/aui/auibar.py", line 3510, in OnPaint
self._art.DrawButton(dc, self, item, item_rect)
File "/usr/lib/python3.10/site-packages/wx/lib/agw/aui/auibar.py", line 1008, in DrawButton
bmp_rect, text_rect = self.GetToolsPosition(dc, item, rect)
File "/usr/lib/python3.10/site-packages/wx/lib/agw/aui/auibar.py", line 1508, in GetToolsPosition
bmp_rect = wx.Rect(bmp_x, bmp_y, bmp_width, bmp_height)
TypeError: Rect(): arguments did not match any overloaded call:
overload 1: too many arguments
overload 2: argument 1 has unexpected type 'float'
overload 3: argument 1 has unexpected type 'float'
overload 4: argument 1 has unexpected type 'float'
overload 5: argument 1 has unexpected type 'float'
overload 6: argument 1 has unexpected type 'float'
After loading DICOM images, I also get (repeated):
Traceback (most recent call last):
File "/usr/lib/python3.10/site-packages/invesalius/gui/widgets/canvas_renderer.py", line 189, in OnMouseMove
x, y = self.viewer.get_vtk_mouse_position()
AttributeError: 'SingleImagePreview' object has no attribute 'get_vtk_mouse_position'
The application still functions(!). I was able to import a set of CT images and export to stl, but there are gui drawing issues. I could not change any masks. Most left side wx widgets did not appear until I manually mouse-overed the expected spots to render them. Most likely I am using too new or too old of a dependency.
My versions are:
$ sudo emerge sci-libs/gdcm dev-python/pyvista dev-python/imageio sci-libs/scikit-image sci-libs/nibabel dev-python/pyacvd dev-python/wxpython -pv -1
These are the packages that would be merged, in reverse order:
Calculating dependencies ...... done!
[ebuild R ] dev-python/wxpython-4.0.7-r4:4.0::gentoo USE="-test -webkit" PYTHON_TARGETS="python3_10 -python3_8 -python3_9" 0 KiB
[ebuild R *] dev-python/pyacvd-9999::jakeogh PYTHON_TARGETS="python3_10 -python3_8 -python3_9" 0 KiB
[ebuild R ] sci-libs/nibabel-3.2.1::science USE="-dicom -doc -test" PYTHON_TARGETS="python3_10 -python3_8 -python3_9" 0 KiB
[ebuild R ] sci-libs/scikit-image-0.19.3-r1::gentoo USE="-test" PYTHON_TARGETS="python3_10 -python3_11" 0 KiB
[ebuild R ] dev-python/pyvista-0.36.1::jakeogh PYTHON_SINGLE_TARGET="python3_10 -python3_9 (-python3_8%)" 0 KiB
[ebuild R ] sci-libs/gdcm-3.0.20::jakeogh USE="python vtk -doc -test" PYTHON_SINGLE_TARGET="python3_10 -python3_9" 0 KiB
[ebuild R ] dev-python/imageio-2.23.0-r1::gentoo USE="-test" PYTHON_TARGETS="python3_10 -python3_11" 0 KiB
To get the above results, I had to make a minor change:
diff --git a/invesalius/reader/dicom_reader.py b/invesalius/reader/dicom_reader.py
index b2d6514b..69d53e9d 100644
--- a/invesalius/reader/dicom_reader.py
+++ b/invesalius/reader/dicom_reader.py
@@ -25,8 +25,8 @@ from multiprocessing import cpu_count
import gdcm
# Not showing GDCM warning and debug messages
-gdcm.Trace_DebugOff()
-gdcm.Trace_WarningOff()
+gdcm.Trace.DebugOff()
+gdcm.Trace.WarningOff()
import glob
import plistlib
Using python 3.10.9
It's user error on my end, attempting to create an ebuild for gentoo.