Google Colab and Cloud Shell
Open a notebook in Google Colab and run the following commands to set up the Neurodesk environment:
import osos.environ["LD_PRELOAD"] = "";os.environ["APPTAINER_BINDPATH"] = "/content"os.environ["MPLCONFIGDIR"] = "/content/matplotlib-mpldir"os.environ["LMOD_CMD"] = "/usr/share/lmod/lmod/libexec/lmod"
!curl -J -O https://raw.githubusercontent.com/neurodesk/neurocommand/main/googlecolab_setup.sh!chmod +x googlecolab_setup.sh!./googlecolab_setup.sh
os.environ["MODULEPATH"] = ':'.join(map(str, list(map(lambda x: os.path.join(os.path.abspath('/cvmfs/neurodesk.ardc.edu.au/neurodesk-modules/'), x),os.listdir('/cvmfs/neurodesk.ardc.edu.au/neurodesk-modules/')))))Once this setup is completed, you can list the available Neurodesk applications like this:
import lmodawait lmod.avail()and use applications like this:
await lmod.load('fsl/6.0.4')!betThis notebook demonstrates how to use all Neurodesk applications in Google Colab: colab.research.google.com/drive/1g5cnZxj1llRaHmOs4xSglqsXnFkQYuol.

This is a Google Colab notebook that shows how to integrate with Google Drive and contains an example for running fMRIprep in Google Colab: colab.research.google.com/drive/11wVBkjNvrzo2TkUAILtWnPumAeFAfqkl.
More examples can be found in our example library.
This also works in a Google Cloud Shell, for example for an interactive tutorial via cloudshell launch-tutorial.
First, run this:
curl -J -O https://raw.githubusercontent.com/neurodesk/neurocommand/main/googlecloudshell_setup.shchmod +x googlecloudshell_setup.sh./googlecloudshell_setup.shThen use a tutorial.md like:
# My first fsl tutorial in Cloud Shell
## Step 1: Say HelloRun the following command to print a message:
```bashmodule use /cvmfs/neurodesk.ardc.edu.au/neurodesk-modules/*ml fslbet```The tutorial can be started via:
cloudshell launch-tutorial tutorial.mdOr via a URL:
https://ssh.cloud.google.com/cloudshell/editor?cloudshell_git_repo=REPO_URL&cloudshell_tutorial=path/to/tutorial.mdwhere cloudshell_git_repo is the URL of the Git repository to clone and cloudshell_tutorial is the relative path to the markdown file inside that repo.