-
-
Notifications
You must be signed in to change notification settings - Fork 431
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Running napari from a docker container #903
Comments
Definitely an idea worth pursuing! Just cause I've been reading about it the last couple days, I would throw in the idea of building a container with virtualGl baked in. From what (little) i've learned so far, i think it might well be a good first-pass solution for many of our remote problems, but it comes with a somewhat difficult installation process (for most users). perhaps a docker container could ease that? |
Just came across this when running a gui interface from docker, as in the links above. Would love to be able to fold napari into the gui we're working on (works locally, just not on the docker image). |
tagging this with "sprint". For me, this would be a challenging task, but given the broad range of backgrounds at SciPy, there may will be someone who's got a lot of docker/container experience. The main challenge, as I see it, would be to get napari running in a docker container that also has some kind of virtualGl or other virtual frame buffer server running. See brief conversation starting around #896 (comment) When getting it running locally, I found this gist |
I wonder here if we tried using vispy's webgl backend - see here http://vispy.org/installation.html#jupyter-notebook-extension if that might open additional avenues for us. Note that they describe webgl support as experimental, and possibly not fully featured, but napari uses only a subset of vispy anyway. Could be one avenue worth pursuing |
made a PR to add docker integration, and also setup a docker organization for napari, see: |
I looked into possibilities into making the docker image more generically useful and have graphical integration, here are my thoughts: |
That all sounds reasonable to me...
It would be great to have a "getting started with remote napari over VNC" tutorial then. |
totally, I would love to chat more with people who actually have the use case to run napari remotely, or even better if we have people having done so successfully, so we can craft a tutorial from the success people had. |
Makes sense, maybe @AhmetCanSolak @talkhanz @DrLachie or others can weigh in here on what they'd like to see for running napari remotely |
throw a rock... ;) @guiwitz: https://github.com/guiwitz/napari_demo |
Hey, I noticed that slowly more and more facilities offer options (or at least some kind of support) to run singularity containers on their HPC hardware. Once a working image exists, template submitting scripts, and a decent "how to connect" would be suitable for people with a HPC background. That said, I have to admit, that I have no experience in setting up virtualgl/ singularity and only limited experience with docker images (I can spin up a remote tensorflow-backed jupyter notebook that's about it). |
Hi :) I'm basically in a position where I'm trying different tools every other week, and anything GPU based (like all the most fun stuff) I containerise so I don't break my local CUDA installation (again). A lot of these tools already come with a dockerfile or image which makes getting them up and running much more simple than trying to work out all the dependencies and which ones conflict with my system etc. So my usecase is: running locally on a linux OS. Note I don't have much experience with HPC but I believe docker is kind of frowned upon in that case due to security setups. |
My use-case is providing a way to run analysis applications with minimal requirements- the only system dependency you can guarantee people have is a web browser. I do a lot of work with Jupyter/JupyterHub where remote environments are run in Docker with all access through a browser, and many "Desktop" style applications such as VSCode and RStudio already support native remote access through the browser. |
The reason I was interested in running napari remotely (whether it be via docker or any other method) is that we will be scaling up to high-content imaging soon with multi-terabyte datasets that our university cluster can store and handle, but is difficult to both store and compute on with a local system. However, we obviously would not be visualizing the whole dataset (includes cell masks and points of segmented RNA FISH puncta generated by starfish) in one shot, so theoretically we can just chunk and transfer to a local system for visualization purposes. In this case, remote use of napari would just be a bonus to eliminate the cluster to local transfer step. |
I'm glad to read that there's interest on this topic both from napari's and the users' side! Many aspects of my use case are aligned with what has been mentioned in previous answers. I create most of my analysis applications as Jupyter notebooks, and eventually my goal is to completely avoid local installations for end-users by having them run on a HPC cluster or cloud resources (e.g. GCE) and making them accessible simply via the browser. At the moment if I want to integrate napari in that approach I I get away with using the Jupyter Desktop Server (https://github.com/yuvipanda/jupyter-desktop-server) and displaying the napari window still in the browser through a remote desktop. This is fine for smaller projects, but as I understand, that approach cannot exploit a GPU and doesn't work well for large datasets. It sounds like VirtualGL mentioned by @tlambert03 could be a solution for this, so if there was a step-by-step installation guide for such a solution (e.g. for a standard Ubuntu machine) it would be very helpful. Finally a Docker-based solution could be really useful to exploit a cloud resource. I really don't know enough about docker to know it this is feasible, but maybe one could use repo2docker for that to simplify then installation to a JupyterHub. However for HPC, I can confirm that in my experience Singularity is favoured, so it would be good to have that option too. |
@ziyangczi amazing work! As stated one main way to use is having napari docker running on a remote machine and being able to control from a local computer. There bunch of users at biohub looking forward to this. Another use case is being able to run napari in docker locally. As stated earlier there are certain docker images with GPU utilization for some computation packages. Those makes installation and dependency management super easy. Being able to run napari on docker would be make it easier to use those computation packages together with napari. |
On the subject of docker vs singularity, after using several cloud computing platforms it seems that clusters are more likely to favor singularity (because you don't need root access to run it) but proprietary cloud computing (AWS/GCP) are favor docker and have many features to make it very easy to use. I believe you can generate a singularity container from a docker container though, so docker is probably the better use case to support |
Hi all, note that we have now merge #1496 which adds a dockerfile. I'm sure there's probably much more to discuss, but unless there are more things people want to bring up here I'll close this issue in a bit. We can always make new ones or reopen as people docker needs evolve |
🚀 Feature
Running napari from a docker container. Simple idea but not that simple to implement.
Motivation
Could be nice to be able to run napari from a docker container at least on same machine. There are certain software pieces delivered as a docker image only, we can help users of such software pieces by letting them starting napari from docker container. So people will not try to map files/folders and keep switching between terminals.
Pitch
This is not easy to implement. There are some previous work for limited experiences with X11 forwarding: https://github.com/jozo/docker-pyqt5 . Here another related discussion: https://stackoverflow.com/questions/24095968/docker-for-gui-based-environments. Possibly future-napari-webviewer can address this issue as well.
Additional context
I just wanted to put this idea out there and see if there are any creative solutions.
The text was updated successfully, but these errors were encountered: