diff --git a/micro_manager/adaptivity/adaptivity.py b/micro_manager/adaptivity/adaptivity.py index b61e008..bcf156e 100644 --- a/micro_manager/adaptivity/adaptivity.py +++ b/micro_manager/adaptivity/adaptivity.py @@ -5,6 +5,7 @@ from math import exp from typing import Callable from warnings import warn +import subprocess from micro_manager.tools.logging_wrapper import Logger import numpy as np @@ -40,8 +41,9 @@ def __init__(self, configurator, rank) -> None: output_dir = configurator.get_output_dir() if output_dir is not None: + subprocess.run(["mkdir", "-p", output_dir]) # Create output directory self._metrics_logger = Logger( - __name__, output_dir + "adaptivity-metrics.csv", rank, csv_logger=True + __name__, output_dir + "/adaptivity-metrics.csv", rank, csv_logger=True ) else: self._metrics_logger = Logger( diff --git a/micro_manager/config.py b/micro_manager/config.py index deb0729..1b31bdc 100644 --- a/micro_manager/config.py +++ b/micro_manager/config.py @@ -650,7 +650,7 @@ def create_single_sim_object(self): """ return self._initialize_once - def get_output_dir_name(self): + def get_output_dir(self): """ Get the name of the output directory.