Commit 7729f279 authored by Patrick Michalsky's avatar Patrick Michalsky
Browse files

updated repo

parent f6d1195e
FROM tensorflow/tensorflow:latest-gpu
FROM tensorflow/tensorflow:2.2.2-gpu
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
apt-get install -y \
python3-tk \
python3-h5py \
llvm-8 \
git
# VARIABLES--------------------------------------------------------------------------------------
ARG DEBIAN_FRONTEND=noninteractive
RUN pip3 install --upgrade pip
RUN pip3 --no-cache-dir install \
tables \
matplotlib \
google-cloud-storage \
Cython
# COPY FILES TO IMAGE----------------------------------------------------------------------------
RUN mkdir -p /opt/program/out
COPY ./code/. /opt/program/
COPY ./requirements.txt /opt/program
RUN chmod +x /opt/program/run.sh
RUN ln -s /usr/bin/python3 /usr/bin/python
ENTRYPOINT ["/bin/bash", "/opt/program/run.sh"]
\ No newline at end of file
# INSTALL BACKEND DEPENDENCIES-------------------------------------------------------------------
RUN apt-get update -y
# INSTALL PYTHON PACKAGES------------------------------------------------------------------------
RUN pip3 install --upgrade pip && \
pip3 install --no-cache-dir -r /opt/program/requirements.txt
# DEFINE ENTRYPOINT------------------------------------------------------------------------------
ENTRYPOINT ["/bin/bash", "/opt/program/run.sh"]
#!/usr/bin/env sh
# CHANGE FOLDER----------------------------------------------------------------------------------
cd /opt/program/ || exit
# RUN CODE---------------------------------------------------------------------------------------
python ./main.py
chown -R "$(stat -c "%u:%g" /opt/program/out)" /opt/program/out
\ No newline at end of file
# CHANGE FOLDER RIGHTS FROM ROOT TO USER---------------------------------------------------------
chown -R "$(stat -c "%u:%g" /opt/program/out)" /opt/program/out
wandb==0.10.19
\ No newline at end of file
......@@ -2,7 +2,6 @@
# VARIABLES--------------------------------------------------------------------------------------
IMAGE_NAME=image
CONTAINER_NAME=singularity_instance
# SAVE IMAGE TO .sif FILE------------------------------------------------------------------------
......@@ -11,5 +10,6 @@ singularity build --force "${CONTAINER_NAME}".sif docker-archive://"${IMAGE_NAME
# RUN CONTAINER----------------------------------------------------------------------------------
singularity run --nv \
--bind "$(pwd)":/opt/program/out \
${CONTAINER_NAME}.sif
--bind "$(pwd)"/shared:/opt/program/shared \
"${IMAGE_NAME}".sif
#!/usr/bin/env sh
SCRIPT=jobscript.sh
NUM_GPUS=1
sbatch -p gpu --gres=gpu:${NUM_GPUS} ${SCRIPT}
# Execute this file by running sbatch queue.sh
#SBATCH --output=./logs/%j.out
#SBATCH --error=./logs/%j.err
#SBATCH --gres=gpu:1
#SBATCH --nodes=1
#SBATCH --ntasks=1
#SBATCH --cpus-per-task=1
#SBATCH --time=01:00:00
srun ./jobscript.sh
Der Justus2 Server verwendet ein TOTP zur Authentifizierung der Nutzer. Der folgende Link beinhaltet eine Anleitung das TOTP per
Konsole abzufragen. Es empfiehlt sich die Schritte individuell anzupassen. Wenn der Server einen QR-Code anstelle eines gesonderten
2FA Keys anbietet, kann dieser mit einem handelsüblichen QR-Scanner abgescannt werden. Der Key befindet sich dann in dem übersetzten
Link.
https://www.cyberciti.biz/faq/use-oathtool-linux-command-line-for-2-step-verification-2fa/
Wichtig ist, dass das TOTP ein "One Time Password" ist und entsprechend nur einmal verwendet werden kann. Wenn mehrere ssh oder scp
Befehle hintereinander ausgeführt werden sollen, muss die Dauer bis zum nächsten TOTP abgewartet werden.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment