How does Keras rate accuracy?

If there is a binary classification problem, and if the label is 0 and 1, I know that prediction is a floating point number, because p is the possibility of belonging to this class.
enter image description here

But the labels are 0 1.
All of them do not match our forecasts. How can cerams evaluate accuracy?
Will keras automatically round our prediction to 0 or 1?

eq: for example, this is the accuracy of data testing
but all the predictions are floating point, so keras around the forecast to 0 1
and calculate the accuracy of 0.749?

>>> scores = model.evaluate(x=test_Features, 
                    y=test_Label)
>>> scores[1]
0.74909090952439739
+2
source share
1 answer

; , ...

- ( ).

y[i] - , 0, 1.

p[i] - , , [0,1] ( ).

i - , y[i] = 0, , y[i] = 1.

:

, y[0] = 1, p[0] = 0.99 ( ). ( 1 - y[0] = 0), log(0.99) = -0.01; , (i=0) 0,01 (- - ).

, 1, y[1] = 1, p[1] = 0.1; , , -log(0.1) = 2.3, , , .

, , y[2] = 0, p[2] = 0; , ,

(1 - y[2]) * log(1 - p[2]) = 1 * log(1) = log(1) = 0

.. , , , i=2.

, n.

, (.. scores[0] ), .

- ; , - , , - , () . , "" - () , , ( , , - , , , , RMSE)...

keras 0 1?

: ( 0,5 , ); , model.evaluate Keras 1, p[i] > 0.5, 0 . , y_true==y_pred ( ) , [0,1].

, :

, ...

+14

All Articles