1A: Introduction to Deep Learning
Episodes
Code and Jupyter notebooks
Note
The files are added here content/se/deep-learning-intro/notebooks
Access them by doing:
git clone https://github.com/ENCCS/castiel-multi-gpu-ai
cd castiel-multi-gpu-ai/content/se/deep-learning-intro/notebooks
To launch jupyter start with instructions here and then use the notebooks/start_jupyter_for_deep_learning_intro.sh shown below:
Warning
To avoid wasting resources, remember to save (using the Jupyter interface) and cancel (using scancel --me) the jobs at the end of the session.
#! /bin/bash
#SBATCH -A tra26_castiel2
#SBATCH -N 1
#SBATCH -n 1
#SBATCH -c 4
#SBATCH --gres=gpu:1
#SBATCH --mem=100000
#SBATCH --time=03:30:00
#SBATCH -p boost_usr_prod
#SBATCH -J jupyter
##SBATCH --reservation=
#FIXME: (optional) If you have a reservation, write above and remove the extra # symbol
module load profile/deeplrn
module load cineca-ai/4.3.0
python 1_DL_test.py
# jupyter notebook --no-browser
# Get the worker list associated to this slurm job
worker_list=($(scontrol show hostnames "$SLURM_JOB_NODELIST"))
# Set the first worker as the head node and get his ip
head_node=${worker_list[0]}
head_node_ip=$(srun --nodes=1 --ntasks=1 -w "$head_node" hostname --ip-address)
# Open a SSH tunnel to the login node and then to the compute node from another shell on your local machine, copying and pasting the following instructions printed in the .out file.
# Print ssh tunnel instruction
jupyter_port=$(($RANDOM%(64511-50000+1)+50000))
jupyter_token=${USER}_${jupyter_port}
echo ===================================================
echo
echo [INFO]: To access the Jupyter server, remember to open a ssh tunnel from your local machine with:
echo ssh -L $jupyter_port:$head_node_ip:$jupyter_port ${USER}@login02-ext.leonardo.cineca.it -N
echo then you can connect to the jupyter server at http://127.0.0.1:$jupyter_port/lab?token=$jupyter_token
echo
echo ===================================================
# Start the head node
echo [INFO]: Starting jupyter notebook server on $head_node
# Note that the jupyter notebook command is available only because we have enabled the venv
command="jupyter lab --ip=0.0.0.0 --port=${jupyter_port} --NotebookApp.token=${jupyter_token}"
echo [INFO]: $command
$command &
echo [INFO]: Your env is up and running.
sleep infinity
notebooks/2-Classification-NN-Keras-PenguinsClassification.ipynbnotebooks/3-Monitor-training-process-WeatherPrediction.ipynb
Reference
Schedule
All times in CET.
Time |
Topic |
Instructor |
|---|---|---|
14:00 |
YW |
|
14:15 |
YW |
|
15:15 |
Exercises (10 min) |
|
15:25 |
YW |
|
15:45 |
Coffee Break (15 min) |
|
16:00 |
AM |
|
16:35 |
Exercises (10 min) |
|
16:45 |
AM |
|
17:15 |
Exercises (15 min) |
|
17:30 |
End of day 1 |