Tasks.objective_function_plot module¶
Description¶
This module defines the ParaMol.Tasks.objective_function_plot.ObjectiveFunctionPlot class, which is a ParaMol task that plots the objective function.
-
class
ParaMol.Tasks.objective_function_plot.ObjectiveFunctionPlot¶ Bases:
ParaMol.Tasks.task.TaskParaMol task that plots the objective function.
-
static
_plot(x, y, z=None)¶ Method that plots the objective function.
- Parameters
x (list or np.array) – x points.
y (list or np.array) – y points.
z (list or np.array) – z points.
- Returns
None
-
static
_write_data(data)¶ Method that writes objective function plot data to a file.
- Parameters
data (np.array) –
- Returns
None
-
run_task(settings, systems, grid_1, grid_2=None, parameter_space=None, objective_function=None, interface=None, write_data=False, plot=True)¶ This method can be used to generate plots of the objective function.
- Parameters
settings (dict) – Dictionary containing global ParaMol settings.
systems (list of
ParaMol.System.system.ParaMolSystem) – List containing instances of ParaMol systems.grid_1 (list or np.array) – Array with values of parameter 1.
grid_2 (list or np.array) – Array with values of parameter 2.
parameter_space (
ParaMol.Parameter_space.parameter_space.ParameterSpace) – Instance of parameter space. (default is None).objective_function (
ParaMol.Objective_function.objective_function.ObjectiveFunction) – Instance of ` (default is None).interface (
ParaMol.Utils.interface.ParaMolInterface) – ParaMol system instance.write_data (bool) – Flag that signal whether the data is going to be written to a file.
plot (bool) – Flag that signal wheter to plot the data using matplotlib.
- Returns
data (np.array) – Objective function plot data
-
static