Batch runs
Fixes https://github.com/trynthink/scout/issues/367
Enable running multiple ymls with a single script. This PR adds a new package module run_batch.py that accepts a directory of yml configuration files and runs ecm_prep.py and run.py.
To run: python scout/run_batch.py -b <my_yml_dir>
Summary of updates:
- As a performance optimization, run_batch.py groups together ymls with ecm_prep arguments that are equal with the exception of ECM downselect arguments (
ecm_files,ecm_directory, andecm_files_regex), and runs ecm_prep.py just once for each group. - After running ecm_prep for a group, run.py is run for each yml in that group
- New optional
--results_directoryargument for run.py to specify where results & plots are output - Each yml gets its own results directory, if not provided in
--results_directory, it will default to./results/<name_of_yml>/ - Each "yml group" gets a custom directory within
./generatedfor intermediate files
Depending on timing of https://github.com/trynthink/scout/pull/375, it may be good to update fp.LOGS path based on which yml is being run: https://github.com/trynthink/scout/pull/375#discussion_r1543487672
@trynthink do you think its important to be more clear about which files in ./generated belong to which yml/yml group? It is not at all apparent right now, but are those files ever important to users for debugging?
@trynthink do you think its important to be more clear about which files in ./generated belong to which yml/yml group? It is not at all apparent right now, but are those files ever important to users for debugging?
Copy ymls into their ./generated directories and rename directories as "batch_run1", "batch_run2"...?