diff --git a/PE_CBL.py b/PE_CBL.py index 7b7ccee66debf5fcbe95e66d6e56aeaca8aba369..0445b0074fc8e968dcbb63ac5794716f112b717a 100644 --- a/PE_CBL.py +++ b/PE_CBL.py @@ -12,7 +12,10 @@ from ENDA import experiment from PE_CBL_models import CBL from PE_CBL_graphics import * -def load_or_run(settings): +def get_experiment(settings_file): + + with open(settings_file, 'r') as fp: + settings = json.load(fp) try: exp = pickle.load(open(settings['path']+'/'+settings['filename'], "rb")) @@ -24,14 +27,6 @@ def load_or_run(settings): return exp -def get_experiment(settings_file): - - with open(settings_file, 'r') as fp: - settings = json.load(fp) - exp = load_or_run(settings) - - return exp - if __name__ == '__main__': workdir = "./runs/seed=181612_enssize=200_EAKF_6hrs/" @@ -41,7 +36,6 @@ if __name__ == '__main__': if not os.path.exists(workdir): os.makedirs(workdir) - ################################################################################## # Check if the necessary config files exist in the working directory. # If not, copy them. # for src in args[:-1]: