jaxopt.projection.projection_affine_set

jaxopt.projection.projection_affine_set(x, hyperparams)[source]

Projection onto an affine set:

\[\underset{y}{\text{argmin}} ~ ||x - y||_2^2 \quad \textrm{subject to} \quad A y = b\]
Parameters
  • x (Array) – array to project.

  • hyperparams (Tuple) – tuple hyperparams = (A, b), where A is a matrix and b is a vector.

Return type

Array

Returns

output array, with the same shape as x.