Skip to content
Snippets Groups Projects
Commit a7ba6c1c authored by stadtler1's avatar stadtler1
Browse files

Merge branch 'scarlet_issue#031_booster' of...

Merge branch 'scarlet_issue#031_booster' of https://gitlab.version.fz-juelich.de/toar/ambs into scarlet_issue#031_booster
parents 590a9aa1 4808678d
Branches
Tags
No related merge requests found
Pipeline #48437 failed
...@@ -41,6 +41,12 @@ ENV_DIR=${WORKING_DIR}/${ENV_NAME} ...@@ -41,6 +41,12 @@ ENV_DIR=${WORKING_DIR}/${ENV_NAME}
# !!! Expects that a template named [script_name]_template.sh exists!!! # !!! Expects that a template named [script_name]_template.sh exists!!!
if [[ "${HOST_NAME}" == jwlogin21* || "${HOST_NAME}" == jwlogin22* ]]; then if [[ "${HOST_NAME}" == jwlogin21* || "${HOST_NAME}" == jwlogin22* ]]; then
workflow_scripts=(train_model_era5_booster) workflow_scripts=(train_model_era5_booster)
# another sanity check for Juwels Booster -> ensure running singularity
if [[ -z "${SINGULARITY_NAME}" ]]; then
echo "ERROR: create_env.sh must be executed in a running singularity on Juwels Booster."
echo "Thus, execute 'singularity shell [my_docker_image]' first!"
return
fi
else else
workflow_scripts=(data_extraction_era5 preprocess_data_era5_step1 preprocess_data_era5_step2 train_model_era5 visualize_postprocess_era5 preprocess_data_moving_mnist train_model_moving_mnist visualize_postprocess_moving_mnist) workflow_scripts=(data_extraction_era5 preprocess_data_era5_step1 preprocess_data_era5_step2 train_model_era5 visualize_postprocess_era5 preprocess_data_moving_mnist train_model_moving_mnist visualize_postprocess_moving_mnist)
fi fi
...@@ -74,15 +80,26 @@ elif [[ "${HOST_NAME}" == "zam347" ]]; then ...@@ -74,15 +80,26 @@ elif [[ "${HOST_NAME}" == "zam347" ]]; then
unset PYTHONPATH unset PYTHONPATH
# Juwels Booster # Juwels Booster
elif [[ "${HOST_NAME}" == jwlogin21* || "${HOST_NAME}" == jwlogin22* ]]; then elif [[ "${HOST_NAME}" == jwlogin21* || "${HOST_NAME}" == jwlogin22* ]]; then
echo "***** Checking modules required during the workflow on Juwels Booster... *****" echo "***** Note for Juwels Booster! *****"
source ${ENV_SETUP_DIR}/modules_train.sh echo "Already checked the required modules?"
echo "To do so, run 'source modules_train.sh' after exiting the singularity."
echo "***** Note for Juwels Booster! *****"
fi fi
if [[ "$ENV_EXIST" == 0 ]]; then if [[ "$ENV_EXIST" == 0 ]]; then
# Activate virtual environmen and install additional Python packages. # Activate virtual environmen and install additional Python packages.
echo "Configuring and activating virtual environment on ${HOST_NAME}" echo "Configuring and activating virtual environment on ${HOST_NAME}"
python3 -m venv $ENV_DIR if [[ "${HOST_NAME}" == jwlogin21* || "${HOST_NAME}" == jwlogin22* ]]; then
# Horovod is part of the requirements on Booster since no binary module is available
# Additionally, venv needs access to the system site-packages of the running singularity
# Otherwise, TensorFlow would be missing
file_req_packages=requirements_booster.txt
python3 -m venv --system-site-packages $ENV_DIR
else
file_req_packages=requirements.txt
python3 -m venv --system-site-packages $ENV_DIR
fi
activate_virt_env=${ENV_DIR}/bin/activate activate_virt_env=${ENV_DIR}/bin/activate
echo ${activate_virt_env} echo ${activate_virt_env}
...@@ -93,7 +110,7 @@ if [[ "$ENV_EXIST" == 0 ]]; then ...@@ -93,7 +110,7 @@ if [[ "$ENV_EXIST" == 0 ]]; then
if [[ "${HOST_NAME}" == hdfml* || "${HOST_NAME}" == *juwels* ]]; then if [[ "${HOST_NAME}" == hdfml* || "${HOST_NAME}" == *juwels* ]]; then
# check module availability for the first time on known HPC-systems # check module availability for the first time on known HPC-systems
echo "***** Start installing additional Python modules with pip... *****" echo "***** Start installing additional Python modules with pip... *****"
pip3 install --no-cache-dir --ignore-installed -r ${ENV_SETUP_DIR}/requirements.txt pip3 install --no-cache-dir --ignore-installed -r ${ENV_SETUP_DIR}/${file_req_packages}
#pip3 install --user netCDF4 #pip3 install --user netCDF4
#pip3 install --user numpy #pip3 install --user numpy
elif [[ "${HOST_NAME}" == "zam347" ]]; then elif [[ "${HOST_NAME}" == "zam347" ]]; then
......
opencv-python-headless==4.2.0.34
horovod==0.16.2
scipy
matplotlib==3.3.0
scikit-image
pandas
hickle
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment