Functions

The pyunlocbox.functions module implements an interface for solvers to access the functions to be optimized as well as common objective functions.

Interface

The func base class defines a common interface to all functions:

func.cap(self, x)

Test the capabilities of the function object.

func.eval(self, x)

Function evaluation.

func.prox(self, x, T)

Function proximal operator.

func.grad(self, x)

Function gradient.

Functions

Then, derived classes implement various common objective functions.

Norm operators (based on norm)

norm_l1(**kwargs)

L1-norm (eval, prox).

norm_l2(**kwargs)

L2-norm (eval, prox, grad).

norm_nuclear(**kwargs)

Nuclear-norm (eval, prox).

norm_tv([dim, verbosity])

TV-norm (eval, prox).

Projection operators (based on proj)

proj_b2(**kwargs)

Projection on the L2-ball (eval, prox).

Miscellaneous

dummy(**kwargs)

Dummy function which returns 0 (eval, prox, grad).

Inheritance diagram of pyunlocbox.functions