I train a Neural Network of Regression Problem in Keras. Why the output is only one Dimension, the accuracy in each Epoch always show acc: 0.0000e+00?
Just a quick add-on to the excellent answers already posted.
The following snippet is a custom metric that will display the average percentage difference between you NN's prediction and the actual value.
def percentage_difference(y_true, y_pred):
return K.mean(abs(y_pred/y_true - 1) * 100)
to implement it into your metrics simply add it to the "metrics" option in your model compilation. I.e.
model.compile(loss= 'mean_squared_error',
optimizer='Adam', metrics=['accuracy',percentage_difference])