jaxopt.loss.binary_perceptron_loss

jaxopt.loss.binary_perceptron_loss(label, score)[source]

Binary perceptron loss.

Parameters
  • label (int) – ground-truth integer label (0 or 1).

  • score (float) – score produced by the model (float).

Return type

float

Returns

loss value.

References

https://en.wikipedia.org/wiki/Perceptron