The toolbox is organized around two class hierarchies: the functions and the
solvers. Instantiated functions represent convex functions to optimize.
Instantiated solvers represent solving algorithms. The
pyunlocbox.solvers.solve() solving function takes as parameters a solver
object and some function objects to actually solve the optimization problem.
See this function’s documentation for a typical usage example.
pyunlocbox package is divided into the following modules:
pyunlocbox.solvers: problem solvers, implement the solvers class hierarchy and the solving function
pyunlocbox.functions: functions to be passed to the solvers, implement the functions class hierarchy
pyunlocbox.operators: useful operators to be passed to the functions
pyunlocbox.acceleration: acceleration schemes to be passed to the solvers, implement the acceleration class hierarchy
This module implements function objects which are then passed to solvers. The
func base class defines the interface whereas specialised classes who
inherit from it implement the methods. These classes include :
dummy: A dummy function object which returns 0 for the
norm: Norm operators base class.
norm_l1: L1-norm who implements the
norm_l2: L2-norm who implements the
norm_nuclear: nuclear-norm who implements the
norm_tv: TV-norm who implements the
proj: Projection operators base class.
proj_b2: Projection on the L2-ball who implements the
This module implements solver objects who minimize an objective function. Call
solve() to solve your convex optimization problem using your instantiated
solver and functions objects. The
solver base class defines the
interface of all solver objects. The specialized solver objects inherit from
it and implement the class methods. The following solvers are included :
gradient_descent: Gradient descent algorithm.
forward_backward: Forward-backward proximal splitting algorithm.
douglas_rachford: Douglas-Rachford proximal splitting algorithm.
generalized_forward_backward: Generalized Forward-Backward.
primal_dual: Primal-dual algorithms.
mlfbf: Monotone+Lipschitz Forward-Backward-Forward primal-dual algorithm.
projection_based: Projection-based primal-dual algorithm.
This module implements acceleration schemes for use with the
pyunlocbox.solvers. Pass a given acceleration object as an argument to
your chosen solver during its initialization so that the solver can use it. The
accel defines the interface of all acceleration objects.
The specialized acceleration objects inherit from it and implement the class
methods. The following acceleration schemes are included:
dummy: Dummy acceleration scheme. It does nothing.
backtracking: Backtracking line search.
fista: FISTA acceleration scheme.
fista_backtracking: FISTA with backtracking.
regularized_nonlinear: Regularized nonlinear acceleration.