Traceback (most recent call last):
File "train_liveness.py", line 114, in <module>
plt.plot(np.arange(0, EPOCHS), H.history["acc"], label="train_acc")
KeyError: 'acc'
Convolutional Neural Net-Keras-val_acc Keyerror ‘acc’
SOLUTION
from keras source :
warnings.warn('The “show_accuracy” argument is deprecated, ’
'instead you should pass the “accuracy” metric to ’
‘the model at compile time:\n’
‘model.compile(optimizer, loss, ' 'metrics=["accuracy"])
’)
The right way to get the accuracy is indeed to compile your model like this:
model.compile(loss=‘categorical_crossentropy’, optimizer=‘adadelta’, metrics=[“accuracy”])
Tensorflow 2.1.0 not working
TensorFlow 2.1: ImportError: DLL load failed: The specified module could not be found. #35749
File "C:\Development\Python\Python37\lib\imp.py", line 242, in load_module
return load_dynamic(name, filename, file)
File "C:\Development\Python\Python37\lib\imp.py", line 342, in load_dynamic
return _load(spec)
ImportError: DLL load failed: The specified module could not be found.
SOLUTION
pip install tensorflow==2.0