Skip to content
Snippets Groups Projects
Commit d62417b7 authored by Peter Alexander's avatar Peter Alexander
Browse files

Split out scenarios into ensemble directories

parent ab9988c2
No related branches found
No related tags found
No related merge requests found
...@@ -22,9 +22,15 @@ do ...@@ -22,9 +22,15 @@ do
if [ -z "$header" ]; then if [ -z "$header" ]; then
header=( "${array[@]}" ) header=( "${array[@]}" )
else else
scenario="${array[0]}" ensemble="${array[0]}"
scenario_dir=$output_dir/$scenario scenario="${array[1]}"
echo "$scenario in $scenario_dir" scenario_dir=$output_dir/$ensemble/$scenario
echo "$scenario for $ensemble in $scenario_dir"
if [ ! -d "$output_dir/$ensemble" ]; then
mkdir $output_dir/$ensemble
fi
if [ ! -d "$scenario_dir" ]; then if [ ! -d "$scenario_dir" ]; then
mkdir $scenario_dir mkdir $scenario_dir
elif [ $overwrite -ne 1 ]; then elif [ $overwrite -ne 1 ]; then
......
...@@ -17,17 +17,18 @@ do ...@@ -17,17 +17,18 @@ do
if [ -z "$header" ]; then if [ -z "$header" ]; then
header=( "${array[@]}" ) header=( "${array[@]}" )
else else
scenario="${array[0]}" ensemble="${array[0]}"
scenario_dir=$output_dir/$scenario scenario="${array[1]}"
echo $scenario scenario_dir=$output_dir/$ensemble/$scenario
echo $scenario for $ensemble
if [ ! -d "$scenario_dir" ]; then if [ ! -d "$scenario_dir" ]; then
echo "Scenario $scenario dir is missing, so skipping" echo "Scenario $scenario dir is missing, so skipping"
continue; continue;
fi fi
echo "qsub /exports/csce/eddie/geos/groups/LURG/models/PLUM/plumv2/scripts/runPlum.sh $scenario" echo "qsub /exports/csce/eddie/geos/groups/LURG/models/PLUM/plumv2/scripts/runPlum.sh $ensemble/$scenario"
qsub /exports/csce/eddie/geos/groups/LURG/models/PLUM/plumv2/scripts/runPlum.sh $scenario qsub /exports/csce/eddie/geos/groups/LURG/models/PLUM/plumv2/scripts/runPlum.sh $ensemble/$scenario
fi fi
done < $filename done < $filename
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment