|
|
|||
File indexing completed on 2026-09-23 09:34:10
0001 #!/bin/bash 0002 0003 ## ============================================================================= 0004 ## Environment setup for the Physics Benchmarks CI jobs 0005 ## 0006 ## This script defines the following environment variables: 0007 ## 0008 ## - LOCAL_DATA_PATH: local storage for passing data between pipeline 0009 ## jobs (not saved as artifacts) 0010 ## 0011 ## Everything describing *what* the benchmarks compute -- the detector, its 0012 ## configuration, event counts, thread counts and RNG seeds -- lives in 0013 ## snakemake.yml instead, and is read by the workflow via Snakemake's config. 0014 ## Override those with "snakemake --config KEY=VALUE", not with environment 0015 ## variables. 0016 ## ============================================================================= 0017 0018 echo "Setting up the Physics Benchmarks environment" 0019 0020 ## Location of local data for passing data from job to job within a pipeline. 0021 ## Not saved as artifacts. 0022 ## Local /scratch directory is presumed to be writable. 0023 if [ ! -n "${LOCAL_DATA_PATH}" ] ; then 0024 if [ -w /scratch ] ; then 0025 export LOCAL_DATA_PATH="/scratch/${CI_PROJECT_NAME}_${CI_PIPELINE_ID}" 0026 else 0027 echo "/scratch not writable; using $PWD/scratch" 0028 export LOCAL_DATA_PATH="$PWD/scratch/${CI_PROJECT_NAME}_${CI_PIPELINE_ID}" 0029 fi 0030 fi 0031 mkdir -p "${LOCAL_DATA_PATH}" 0032 if [ ! -d "${LOCAL_DATA_PATH}" ]; then 0033 echo "LOCAL_DATA_PATH (${LOCAL_DATA_PATH}) does not exist!!" 0034 echo "Creating LOCAL_DATA_PATH=$(pwd)/local_data " 0035 export LOCAL_DATA_PATH="$(pwd)/local_data" 0036 mkdir -p "${LOCAL_DATA_PATH}" 0037 fi 0038 0039 # Local field maps 0040 mkdir -p ${LOCAL_DATA_PATH}/fieldmaps 0041 ln -sf ${LOCAL_DATA_PATH}/fieldmaps 0042 0043 ## ============================================================================= 0044 ## That's all! 0045 echo "Environment setup complete."
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|