-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcaffe-gpu-0.3.def
29 lines (24 loc) · 1.25 KB
/
caffe-gpu-0.3.def
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
Bootstrap: docker
From: bvlc/caffe:gpu
%post
mkdir -p /global/home/users
mkdir -p /global/scratch
apt-get install -y strace
pip install -U scikit-image
pip install opencv-contrib-python
# not clear why DCV stuff is now needed on Savio, but this allows dcv-related .so file to be found; need to bind mount these in at container run time
mkdir /etc/dcv
mkdir /var/lib/dcv-gl
mkdir /usr/lib64
# /bin/nvidia-smi is a binary on the GPU nodes. Singularity with --nv seems to mount /bin/nvidia-smi and fails unless the file already exists in the container. As of 2019-03-10 or so, same issue for the /usr/bin/ files here
touch /bin/nvidia-smi
touch /usr/bin/nvidia-smi
touch /usr/bin/nvidia-debugdump
touch /usr/bin/nvidia-persistenced
touch /usr/bin/nvidia-cuda-mps-control
touch /usr/bin/nvidia-cuda-mps-server
%runscript
python "$@"
%startscript
# Not working because can't figure out how to write to a directory accessible to user and instance.start seems to execute without reference to the user
# if [ "${SLURM_JOB_ID}" != "" ]; then jupyter notebook --no-browser --ip=${SLURMD_NODENAME} 2>> slurm-${SLURM_JOB_ID}.out; else env && jupyter notebook --no-browser --ip="localhost" 2> jupyter-tf-gpu.out; fi