jamesdolezal / slideflow

Deep learning library for digital pathology, with both Tensorflow and PyTorch support.
https://slideflow.dev
GNU General Public License v3.0
230 stars 38 forks source link

How do I run Slideflow studio from the docker container #352

Open Phues opened 3 months ago

Phues commented 3 months ago

I have followed the installation guide and pulled an image using:

docker pull jamesdolezal/slideflow:latest-torch

then I ran the command:

docker run -it --rm \
    -e DISPLAY=$DISPLAY \
    -v /tmp/.X11-unix:/tmp/.X11-unix \
    jamesdolezal/slideflow:latest-tf

after that I ran slideflow-studio inside the container, however I'm getting an error "ModuleNotFoundError: No module named 'tkinter'"

I'm using windows 11

Phues commented 3 months ago

I was able to resolve this with the following steps:

  1. Install vcxsrv on your WIN10 from sourceforge.net/projects/vcxsrv
  2. Start server, Keep everything default in it, don’t make changes. When you complete the display settings setup by clicking on next. VcXsrv icon will appear in the system tray, and, the Application will keep running in the background.
  3. docker run -it --rm -e DISPLAY=host.docker.internal:0.0 -v /tmp/.X11-unix:/tmp/.X11-unix jamesdolezal/slideflow:latest-tf
  4. apt-get install python3-tk
  5. slideflow-studio
jamesdolezal commented 3 months ago

Thank you for finding and reporting a solution! We will add these steps into our documentation for others to see as well. We'll probably add a separate subpage within the documentation dedicated to setting up and using Docker. More to come.