KitwareMedical / CourseInBiomedicalImageAnalysisAndVisualization

Kitware Course in Biomedical Image Analysis and Visualization: ITK
https://mybinder.org/v2/gh/KitwareMedical/2019-03-13-KRSCourseInBiomedicalImageAnalysisAndVisualization/master
Apache License 2.0
15 stars 8 forks source link

Both `conda` and `jupyter lab` instructions fail #31

Closed hjmjohnson closed 5 years ago

hjmjohnson commented 5 years ago

The conda instructions with jupyter notebook produce an environment that does not show view(image). (i.e. only a string shows up, but no display of an image).

The conda instructions with jupyter lab causes the kernel to restart everytime the view(img) function is called.

You may want to remove those instructions because they lead to much frustration. The only option that allowed local running of the environments was a system python3 venv with jupyter notebooks.

hjmjohnson commented 5 years ago

@thewtex Hi matt. I was hoping to use some of this content to teach students how to ITK python in my class. Unfortunately, I can not get the image viewer (a critical part of teaching) to work in our conda environment. I'm going to use the simple ITK examples for the next 2 weeks, and then try to go back to ITK python if I can get the viewers working.

I've tried recompiling, but that does not work either. Every time I try to view an image, I get a kernel restart.

thewtex commented 5 years ago

Thanks for the note, Hans.

I will take a look at the conda environment.

hjmjohnson commented 5 years ago

FYI: I have jupyter lab working. I needed to add a few items to the envirionment requirements. I'll pass that along quickly here:

python3 -m venv  ~/miattpython3
alias miattpython="source ~/miattpython3/bin/activate"
miattpython

pip install pip --upgrade
pip install setuptools --upgrade 

python -m pip install wheel tornado==5.1.1 jupyter jupyterlab matplotlib numpy scipy ipywidgets scikit-learn cookiecutter
python -m pip install --upgrade --pre itk itk-texturefeatures
python -m pip install itkwidgets

jupyter labextension install @jupyter-widgets/jupyterlab-manager itk-jupyter-widgets
thewtex commented 5 years ago

@hjmjohnson thanks for the update.

Yes, jupyter lab requires that extra labextension step. This requires a Node.js installation, which is easier to make available across platforms with conda. I will work on the conda packages...

thewtex commented 5 years ago

I tried the conda installation instructions on both Linux and macOS, and they both worked for me.

Jupyter Lab instructions are added in #32

thewtex commented 5 years ago

@hjmjohnson please re-open if issues persist.