jaxopt.objective.binary_logreg
- jaxopt.objective.binary_logreg = <jaxopt._src.objective.BinaryLogreg object>
Binary logistic regression.
\[\frac{1}{n} \sum_{i=1}^n \ell(w^\top x_i, y_i)\]where \(\ell\) is
binary_logistic_loss
andX, y = data
.- Parameters
w – a vector of shape
(n_features, )
.data – a tuple
(X, y)
whereX
is a matrix of shape(n_samples, n_features)
andy
is a vector of shape(n_samples,)
, containing0
or1
values.
- Returns
objective value.
Example:
value = binary_logreg(w, (X, y))