poli.core.util.objective_management.make_run_script.make_observer_script

poli.core.util.objective_management.make_run_script.make_observer_script#

poli.core.util.objective_management.make_run_script.make_observer_script(observer: Type[AbstractObserver], conda_environment: Optional[Union[str, Path]] = None, python_paths: Optional[List[str]] = None, cwd=None)#

Create a script to run the given observer.

Parameters
  • observer (AbstractObserver) – The observer object to be executed.

  • conda_environment (str or Path, optional) – The conda environment to activate before running the observer.

  • python_paths (List[str], optional) – Additional Python paths to be added before running the observer.

  • cwd (str or Path, optional) – The current working directory for the script execution.

Returns

run_script – The path to the generated script.

Return type

str