Loss and regularization functions

These are some convenience functions that implement wior convenience, the following are already defined and ready to use.

Smooth loss functions:

copt.utils.LogLoss(A, b[, alpha])

Logistic loss function.

copt.utils.SquareLoss(A, b[, alpha])

Squared loss.

copt.utils.HuberLoss(A, b[, alpha, delta])

Huber loss

Non-smooth terms accessed through their proximal operator

copt.utils.L1Norm(alpha)

L1 norm, that is, the sum of absolute values:

copt.utils.L1Ball(alpha)

Indicator function over the L1 ball

copt.utils.GroupL1(alpha, groups)

Group Lasso penalty

copt.utils.TraceNorm(alpha, shape)

Trace (aka nuclear) norm, sum of singular values

copt.utils.TraceBall(alpha, shape)

Projection onto the trace (aka nuclear) norm, sum of singular values

copt.utils.TotalVariation2D(alpha, shape[, …])

2-dimensional Total Variation pseudo-norm