CADETProcess.optimization.OptimizationResults.plot_pareto#
- OptimizationResults.plot_pareto(show: bool = True, plot_pareto: bool = True, plot_evolution: bool = False, plot_directory: str | Path | None = None) None[source]#
Plot Pareto fronts for each generation in the optimization.
The Pareto front represents the optimal solutions that cannot be improved in one objective without sacrificing another. The method shows a pairwise Pareto plot, where each objective is plotted against every other objective in a scatter plot, allowing for a visualization of the trade-offs between the objectives. To highlight the progress, a colormap is used where later generations are plotted with darker blueish colors.
- Parameters:
- showbool, optional
If True, display the plot. The default is True.
- plot_paretobool, optional
If True, only Pareto front members of each generation are plotted. Else, all evaluated individuals are plotted. The default is True.
- plot_evolutionbool, optional
If True, the Pareto front is plotted for each generation. Else, only final Pareto front is plotted. The default is False.
- plot_directorystr, optional
The directory where the plot should be saved. The default is None.
- Returns:
- tuple
A tuple containing: - plt.Figure: The Matplotlib Figure object. - npt.NDArray[plt.Axes]: An array of Axes objects representing the subplots.