plot_best_state

Contents

plot_best_state#

class pinnx.utils.plot_best_state(train_state)[source]#

Plot the best result of the smallest training loss.

This function only works for 1D and 2D problems. For other problems and to better customize the figure, use save_best_state().

Note

You need to call plt.show() to show the figure.

Parameters:

train_stateTrainState instance. The second variable returned from Trainer.train().