From 6a750fbfb803252e4804637f405e30ab60e3a3b3 Mon Sep 17 00:00:00 2001 From: Cmurilochem Date: Fri, 22 Mar 2024 16:58:15 +0100 Subject: [PATCH] Include runcard name to mongo workers log filenames --- n3fit/src/n3fit/hyper_optimization/mongofiletrials.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/n3fit/src/n3fit/hyper_optimization/mongofiletrials.py b/n3fit/src/n3fit/hyper_optimization/mongofiletrials.py index ecf874f3c9..a0beb0c21f 100644 --- a/n3fit/src/n3fit/hyper_optimization/mongofiletrials.py +++ b/n3fit/src/n3fit/hyper_optimization/mongofiletrials.py @@ -155,6 +155,7 @@ def __init__( ) self.workers = [] self.log_files = [] + self.output_path = replica_path.parts[-3] self._store_trial = False self._json_file = replica_path / "tries.json" @@ -266,7 +267,7 @@ def start_mongo_workers( # my_env["TF_GPU_ALLOCATOR"] = "cuda_malloc_async" # create log files to redirect the mongo-workers output - mongo_workers_logfile = f"mongo-worker_{i+1}.log" + mongo_workers_logfile = f"mongo-worker_{i+1}_{self.output_path}.log" log_file = open(mongo_workers_logfile, 'w') self.log_files.append(log_file) # run mongo workers