VS Code
You can connect to Fabian from VS Code. The important thing to keep in mind is NOT to connect to the head/login node if you are running anything computationally or memory hungry. Users accidentally doing so has led to the cluster becoming unstable and we are putting in place protections to stop this from happening.
Creating a VS Code tunnel
Use any of the means of connecting to fabian and use srun to get an interactive session on a compute node e.g.
srun --ntasks=1 --nodes=1 --partition=small --time=6:00:00 --pty bash
Load the vscode module and authenticate to your LSE Microsoft Account (should you wish to you could also use your github account by obmitting the --provider option below)
module add apps/vscode
code tunnel user login --provider microsoft
and follow the instructions. Note that while the authentication lasts for sometime but you will have to re-authenticate to your accout from time to time. You do not have to run this step eveytime.
Next create a tunnel server and give it a name, e.g.
code tunnel --name fabian-compute
Ignore the instruction to open https://vscode.dev/tunnel/fabian-compute/zfs/... (unless you want to run vscode in your web browser)
In VS Code on your machine use the >< Icon bottom left of VS Code to 'Connect to Tunnel...', select 'Microsoft Account', and authenticate if nessecary, after a short delay the tunnel will be listed and once you choose it it will install the remote server
You'll see a message..
You are about to connect to an OS version that is unsupported by Visual Studio Code.
This can be ignored and will go away once we upgrade the operating system the Fabian Cluster users.
You should now be able to use VSCode as you normally would.
Many extenstions will need to be installed on the tunnel server (the extensions menu will offer you a 'Install in fabian-compute' option)
Jupyter
Now that you have vscode remoting to a tunnel you can use jupyter displayed within VSCode but running on the compute server.
Install the Jupyter extension on the tunnel server. From VS Code Extensions find Jupyter and 'Install in fabian-compute'
You can open a folder and create a new Jupyter Notebook and select a kernel.
Adding your own kernels
Python
After creating a virtualenv or venv and activating it install the ipykernel package and run
python -m ipykernel install --name nameofenvironment --display-name "name of environment" --user
A fuller example follows...
- conda
module add apps/miniconda/py312_25.1.1-2
conda create --name project_name
conda install numpy
conda install ipykernel
python -m ipykernel install --user --name my-project-name --display-name "my project name"
The kernel "my project name" will be available when you next select a kernel