Commit e38e0c02 authored by Sebastian Milinski's avatar Sebastian Milinski
Browse files

updated because more rcp85 experiments were moved to mh1007

parent 9205a239
......@@ -294,7 +294,7 @@ target_subdir=${target_dir}/rcp85
source_prefix=cr
source_suffix=_rcp85
ens_0=101 # first ensemble member to include
ens_n=160 # last ensemble member to include
ens_n=180 # last ensemble member to include
# source_prefix will be substituted with this
target_prefix=rcp85
......@@ -319,41 +319,41 @@ wait
fi
#####################
# RCP 8.5 61-80
if [ "$force_rcp85" = true ]; then
# path to directory where all members for the experiment are located
source_dir=/work/bm0976/m300497/MPIESM/GLENSv1/output/experiments
# directory where links to members will be created. Choose a meaningful name that starts with a letter
target_subdir=${target_dir}/rcp85
# which members should be used from source_dir? Define prefix and counter (counter is expanded to 4-digit number with leading zeros later)
source_prefix=cr
source_suffix=_rcp85
ens_0=161 # first ensemble member to include
ens_n=180 # last ensemble member to include
# source_prefix will be substituted with this
target_prefix=rcp85
# ensemble counter offset, i.e. choose -100 to change lkm0101 to hist0001
counter_offset=-100
echo creating links for RCP 8.5 runs
# Loop through each ensemble member
for rrr in $(seq $ens_0 $ens_n); do #change to 200
source_expid=${source_prefix}$(printf "%04d" $rrr)${source_suffix}
target_counter=$(expr $rrr + $counter_offset)
target_expid=${target_prefix}$(printf "%04d" $target_counter)
echo $source_expid - $target_expid
# echo copy directory structure
mkdir -p ${target_subdir}/${target_expid}
find ${source_dir}/${source_expid} -mindepth 1 -depth -type d -printf "%P\n" | while read dir; do mkdir -p "${target_subdir}/${target_expid}/${dir}"; done
# echo linking files
find ${source_dir}/${source_expid} -type f -printf "%P\n" | while read file; do ln -s ${source_dir}/${source_expid}/$file $(echo ${target_subdir}/${target_expid}/$file | sed "s/$source_expid/$target_expid/"); done &
done
wait
fi
# # RCP 8.5 61-80
# if [ "$force_rcp85" = true ]; then
# # path to directory where all members for the experiment are located
# source_dir=/work/bm0976/m300497/MPIESM/GLENSv1/output/experiments
# # directory where links to members will be created. Choose a meaningful name that starts with a letter
# target_subdir=${target_dir}/rcp85
# # which members should be used from source_dir? Define prefix and counter (counter is expanded to 4-digit number with leading zeros later)
# source_prefix=cr
# source_suffix=_rcp85
# ens_0=161 # first ensemble member to include
# ens_n=180 # last ensemble member to include
# # source_prefix will be substituted with this
# target_prefix=rcp85
# # ensemble counter offset, i.e. choose -100 to change lkm0101 to hist0001
# counter_offset=-100
# echo creating links for RCP 8.5 runs
# # Loop through each ensemble member
# for rrr in $(seq $ens_0 $ens_n); do #change to 200
# source_expid=${source_prefix}$(printf "%04d" $rrr)${source_suffix}
# target_counter=$(expr $rrr + $counter_offset)
# target_expid=${target_prefix}$(printf "%04d" $target_counter)
# echo $source_expid - $target_expid
# # echo copy directory structure
# mkdir -p ${target_subdir}/${target_expid}
# find ${source_dir}/${source_expid} -mindepth 1 -depth -type d -printf "%P\n" | while read dir; do mkdir -p "${target_subdir}/${target_expid}/${dir}"; done
# # echo linking files
# find ${source_dir}/${source_expid} -type f -printf "%P\n" | while read file; do ln -s ${source_dir}/${source_expid}/$file $(echo ${target_subdir}/${target_expid}/$file | sed "s/$source_expid/$target_expid/"); done &
# done
# wait
# fi
......
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