jaxopt.objective.multiclass_logreg

jaxopt.objective.multiclass_logreg = <jaxopt._src.objective.MulticlassLogreg object>

Multiclass logistic regression.

\[\frac{1}{n} \sum_{i=1}^n \ell(W^\top x_i, y_i)\]

where \(\ell\) is multiclass_logistic_loss and X, y = data.

Parameters
  • W – a matrix of shape (n_features, n_classes).

  • data – a tuple (X, y) where X is a matrix of shape (n_samples, n_features) and y is a vector of shape (n_samples,).

Returns

objective value.

Example:

value = multiclass_logreg(W, (X, y))