callback

Callback objects for per-iterate actions in iterative methods.

Classes

Callback()

Abstract base class for handling iterates of solvers.

CallbackApply(function[, step])

Callback for applying a custom function to iterates.

CallbackPrint([func, fmt, step])

Callback for printing the current value.

CallbackPrintHardwareUsage([step, fmt_cpu, …])

Callback for printing memory and CPU usage.

CallbackPrintIteration([fmt, step])

Callback for printing the iteration count.

CallbackPrintNorm()

Callback for printing the current norm.

CallbackPrintTiming([fmt, step, cumulative])

Callback for printing the time elapsed since the previous iteration.

CallbackProgressBar(niter[, step])

Callback for displaying a progress bar.

CallbackSaveToDisk(saveto[, step, impl])

Callback for saving iterates to disk.

CallbackShow([title, step, saveto])

Callback for showing iterates.

CallbackShowConvergence(functional[, title, …])

Displays a convergence plot.

CallbackSleep([seconds])

Callback for sleeping for a specific time span.

CallbackStore([results, function, step])

Callback for storing all iterates of a solver.

Functions

save_animation(filename[, writer, …])

Context manager for creating animations from a series of plots.