watch_progress#

nextnano_optimizers.plotting.watch_progress(json_path, interval=1.0, **plotter_kwargs)#

Open a live-updating progress window for an optimization JSON log.

Blocks until the window is closed. This is what Evolution.run(live_progress=True) and BayesianOptimization.run(live_progress=True) spawn in a separate process, and what python -m nextnano_optimizers.plotting <log> --watch calls.

Parameters:
json_pathstr

Path to the optimization JSON log to watch. It need not exist yet: the window waits for it to appear and for the first results to be logged.

intervalfloat, default=1.0

Polling interval in seconds.

**plotter_kwargs

Forwarded to OptimizationPlotter.

param_nameslist of str, optional

Axis labels for the input variables.

fitness_nameslist of str, optional

Axis labels for the objectives.

exclude_failedbool, optional

Drop the evaluations that scored the run’s non_execution_penalty before plotting.

fitness_limitslist or dict, optional

Per-objective (min, max) bounds, one entry per objective or a sparse dict keyed by objective name or index.

progress_seriessequence of str or str, optional

Which per-panel curves the progress figure draws; "all" selects every curve.

series_labelsdict, optional

Legend text per curve, keyed by curve name.

series_specsdict, optional

Per-curve drawing overrides, keyed by curve name, each holding kind and/or style.

iteration_labelstr, optional

What one optimization step is called in the figures. Also names the “waiting” placeholder shown before the first results land.

progress_titlestr, optional

Suptitle of the progress figure.

population_labelstr, optional

What the points of the final iteration are called.

Notes

The optimizers open this window for you when run(live_progress=True) is used, so calling it directly is for runs that are not in your own process – one started from another terminal, or one on a cluster node writing its log to a shared filesystem. Point this at that log and the figure updates on your machine while the run goes on elsewhere.

The log is only read, never written, so opening the window, closing it, or starting it long after the run has finished leaves the run untouched.