Skip to content
Snippets Groups Projects
Commit 91bd0358 authored by Michael Langguth's avatar Michael Langguth
Browse files

Include automatic destination_dir-construction to the generation of the...

Include automatic destination_dir-construction to the generation of the runscript for data extraction.
parent 0f3fb4e3
No related branches found
No related tags found
No related merge requests found
Pipeline #59313 passed
......@@ -35,14 +35,14 @@ if [ -z ${VIRTUAL_ENV} ]; then
fi
fi
# Declare path-variables
# Declare path-variables (dest_dir will be set and configured automatically via generate_runscript.py)
source_dir=/p/fastdata/slmet/slmet111/met_data/ecmwf/era5/nc/
dest_dir=/p/scratch/deepacf/video_prediction_shared_folder/extractedData/
year="2010"
# Run data extraction
srun python ../main_scripts/main_data_extraction.py --source_dir ${source_dir}/${year}/ --destination_dir ${dest_dir}/${year}/
srun python ../main_scripts/main_data_extraction.py --source_dir ${source_dir}/${year}/ --destination_dir ${dest_dir}
......
......@@ -48,6 +48,10 @@ class Config_Extraction(Config_runscript_base):
self.year = Config_Extraction.keyboard_interaction(year_req_str, Config_Extraction.check_year,
year_err, ntries = 2, test_arg="2012")
# set destination directory based on base directory which can be retrieved from the template runscript
base_dir = Config_Extraction.get_var_from_runscript(self.runscript_template, "destination_dir")
self.destination_dir = os.path.join(base_dir, "extracted_data", self.year)
#
# -----------------------------------------------------------------------------------
#
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment