AImageLab-HPC

CVCS 2026 - Quick Start Guide

Last updated: March 30, 2026


This guide is for students enrolled in the Computer Vision and Cognitive Systems (CVCS 2026) course. It walks you through logging into the cluster, setting up your Python environment, and running a Jupyter Notebook session on a compute node.

Step 1 - Log into the Cluster

Connect via SSH to one of the login nodes:

ssh <username>@ailb-login-02.ing.unimore.it

or

ssh <username>@ailb-login-03.ing.unimore.it

Replace <username> with your AImageLab-HPC username (which is different from your UNIMORE username - check your welcome email). You will be prompted for your UNIMORE password.

First login: If this is your first time connecting, your SSH client will ask you to confirm the host fingerprint. Type yes and press Enter.

If you need to connect from outside the UNIMORE network, copy your SSH public key to the cluster:

ssh-copy-id <username>@ailb-login-02.ing.unimore.it

Note that this does not remove the password prompt - you will still authenticate with your UNIMORE password. However, it is required to allow connections from outside the university network.

Step 2 - Create Your Python Environment

Once logged in, create a dedicated directory and virtual environment for the course:

mkdir -p /homes/<username>/cvcs2026
python -m venv /homes/<username>/cvcs2026/venv

Activate the environment and install the packages you need:

source /homes/<username>/cvcs2026/venv/bin/activate
pip install jupyterlab

Add any additional course packages (e.g. torch, torchvision, numpy, matplotlib) as needed:

pip install torch torchvision numpy matplotlib

Note: The default Python provided by the Anaconda module is sufficient for this course. If you need a specific version, load it before creating the venv: module load python/3.11.11-gcc-11.4.0.

Step 3 - Run a Jupyter Notebook on a Compute Node

Running Jupyter directly on a login node is not allowed. You must submit a SLURM job that starts JupyterLab on a compute node, then connect to it via an SSH tunnel.

3a - Write the Job Script

Create a file called jupyter_cvcs.sh in your home directory:

#!/bin/bash
#SBATCH --job-name=jupyter_cvcs
#SBATCH --partition=all_serial
#SBATCH --cpus-per-task=2
#SBATCH --mem=8G
#SBATCH --time=04:00:00
#SBATCH --output=/homes/%u/cvcs2026/jupyter_%j.out
#SBATCH --account=cvcs2026

source /homes/$USER/cvcs2026/venv/bin/activate
jupyter lab --no-browser --ip=0.0.0.0 --port=8888

3b - Submit the Job

sbatch jupyter_cvcs.sh

Wait a few seconds, then check that the job is running:

squeue --me

Note the node name shown in the NODELIST column (e.g. nico).

3c - Find the Connection Token

Once the job is running, the log file will contain the JupyterLab URL and token:

tail -f /homes/<username>/cvcs2026/jupyter_<job_id>.out

Look for a line like:

http://nico:8888/lab?token=abc123...

Note down the node name and the token.

3d - Open the SSH Tunnel

From your local machine (not the cluster), open a new terminal and run:

ssh -L 8888:<node>:8888 <username>@ailb-login-02.ing.unimore.it

Replace <node> with the node name from the previous step. Keep this terminal open for the duration of your session.

If port 8888 is already in use on your machine, use a different local port (e.g. 8889):

ssh -L 8889:<node>:8888 <username>@ailb-login-02.ing.unimore.it

3e - Open JupyterLab in Your Browser

Navigate to:

http://localhost:8888

When prompted, paste the token from the log output. You can also paste the full URL from the log, replacing the node hostname with localhost:

http://localhost:8888/lab?token=abc123...

You are now connected to a JupyterLab session running on a compute node under the cvcs2026 account.

Stopping the Session

When finished, shut down JupyterLab from the browser (File - Shut Down) or cancel the job from the cluster:

scancel <job_id>

Closing the browser tab alone does not release the compute node - the SLURM job will keep running until it is cancelled or the 4-hour walltime expires.

Step 4 - Set Up Your Group Shared Folder

Each project group has access to /work/cvcs2026 for shared data. One member of the group should create the shared folder and grant access to their partner.

4a - Create the Directory

The first member creates the directory, restricts access to everyone else, then grants their partner explicit access via ACL:

mkdir -p /work/cvcs2026/<groupname>
chmod 700 /work/cvcs2026/<groupname>
setfacl -m u:<partner_username>:rwx /work/cvcs2026/<groupname>

Replace <groupname> with a name that identifies your group (e.g. team_alpha) and <partner_username> with your partner’s AImageLab-HPC username.

For example:

mkdir -p /work/cvcs2026/team_alpha
chmod 700 /work/cvcs2026/team_alpha
setfacl -m u:bob:rwx /work/cvcs2026/team_alpha

4b - Verify the Permissions

Check that the ACLs are set correctly:

getfacl /work/cvcs2026/team_alpha

The output should look like:

# file: work/cvcs2026/team_alpha
# owner: alice
# group: cvcs2026
user::rwx
user:bob:rwx
group::---
mask::rwx
other::---

Both the owner and the partner (via ACL) have full read/write/execute access. No one else can enter the directory.

Note: Only the member who created the directory needs to run these commands. The partner will have access immediately after setfacl is executed.