3D Slicer desktop VM
Last updated
Was this helpful?
Last updated
Was this helpful?
These instructions provide a reference example of how you can start up a traditional workstation desktop on a VM instance to run interactive applications like and access the desktop via a conventional web browser. Two options are shown, either with or without a GPU. Note that GPUs are significantly more expensive so only enable it if needed. For 3D Slicer the main benefit of a GPU is for rendering, so operations like dicom processing and image segmentation are quite usable without a GPU. Even volume rendering is fairly usable if you choose the CPU rendering option. Other operations such as training machine learning models may benefit from an appropriate GPU.
A motivation for using desktop applications like 3D Slicer on a VM is that their computing power close to the data, so heavy network operations such as storage bucket or dicom store access may be significantly faster than accessing the same resources from a remote machine. They are also highly configurable, so that you can easily allocate the number of cores or memory needed for a given task. Note that can even change these configurations so that, for example, you can shut down the machine, add a GPU and more memory, and then boot the same instance and pick up where you left off.
In addition, these desktops are persistent in the sense that you can start a task such as labeling data for a machine learning task, disconnect your ssh session, and reconnect later to pick up where you left off without needing to restart applications or reload data. This can be convenient when tending long-running computations, accessing your work from different computers, or working on a network that sometimes disconnects.
The instructions here are just a starting point. There are many cloud options available to manage access scopes for the service accounts, allocate disks, and configure other options.
You can launch a VM with a GPU in your project with a command like this in your local terminal (replace vm-name
with a name for your machine):
Once it boots in about 90 seconds you can type:
You can launch a VM without a GPU in your project with a command like this in your local terminal (replace vm-name
with a name for your machine):
Once it boots in about 90 seconds you can type:
On the remote machine run:
Each time you reboot the machine, run this:
Then you can open to get to your desktop.
Then you can open to get to your desktop.
This effort is a work in progress with a minimal desktop environment. Further refinement is expected and community contributions would be welcome! A description of the background and possible evolution of this work is .