мой код:
history=model.fit(X_train, y_train, validation_data=(X_val,y_val),epochs=10, verbose=0,callbacks=[callbacks])
xyz=model.history.history['val_accuracy']
print(xyz)
По моему мнению, значения val_accuracy на выходе из model.fit должны быть такими же, как значения в model.history.history ['val_accuracy']. Где я ошибаюсь?
Вывод:
Model: "sequential"
_________________________________________________________________
Layer (type) Output Shape Param #
=================================================================
dense (Dense) (None, 15) 240
_________________________________________________________________
dense_1 (Dense) (None, 15) 240
_________________________________________________________________
dense_2 (Dense) (None, 1) 16
=================================================================
Total params: 496
Trainable params: 496
Non-trainable params: 0
_________________________________________________________________
validation accuracy : 57.00%
training accuracy : 49.82%
[0.5699999928474426, 0.5899999737739563, 0.550000011920929, 0.550000011920929, 0.5299999713897705, 0.5199999809265137, 0.5199999809265137, 0.5199999809265137, 0.5099999904632568, 0.5]
---------------------------------------------------------------------------