alibaba-damo-academy / ct-sam3d

Apache License 2.0
16 stars 2 forks source link

about the viewer #2

Closed jianjun0407 closed 1 month ago

jianjun0407 commented 2 months ago

First of all, thank you for sharing the code and models ! I installed the corresponding dependencies as you suggested,There was an error in executing the show() function in visualization.py: 3

1

I find that the problem is self.server=None, 2 My current version of the related library is as follows: numpy=1.22.4 itkwidgets=1.0a49 I suspect this problem is a library version issue, do you have any suggestions?

henguo commented 2 months ago

Hi, Jianjun,

You may troubleshoot this issue through two steps: 1) Check whether the imjoy-jupyterlab-extension has been installed successfully. The ImJoy logo should present as: image

2) Install the customized itkwidgets from https://github.com/henguo/itkwidgets.git, when this is installed, the version of itkwidgets should not be 1.0a49.

jianjun0407 commented 2 months ago

Thank you for your advice, I give it a try~

jianjun0407 commented 1 month ago

First of all, I installed the official version of itkwidgets (https://github.com/InsightSoftwareConsortium/itkwidgets), "visualization.ipynb" of CT-SAM3D can run. However, there is an error: "Viewer" object has no attribute "points". I assume that the official version of itkwidgets library does not support such interaction as adding points. I need to install the custom version of itkwidgets library as you suggested, My installation method is : "pip install git+https://github.com/henguo/itkwidgets.git"

4

Now, I have two questions: First, with this customized version of the itkwidgets library, the image display interface is gone 5

Second, the implementation of "pip install numpy = = 1.22.4", some library version are not compatible, such as: scipy, zarr, matplotlib, etc. Do you have to use numpy version 1.22.4?

6

henguo commented 1 month ago

The first issue is that the imjoy-jupyterlab-extension is not activated, as evidenced by the absence of the ImJoy logo in the toolbar. After installing the customized itkwidgets, the imjoy-jupyterlab-extension should still be activated.

The second issue can be resolved by installing a compatible version of numpy in your runtime environment. Version 1.22.4 works for us, but we have not tested other versions.