Accuracy always 1 Caffe Regression

前端 未结 1 735
萌比男神i
萌比男神i 2020-12-22 10:29

My dataset contains 400 images 32x32x3 and the labels contain float number (-1,1). Example:

faceCroppedImages/img1.jpg 0
faceCroppedImages/img2.jpg 0.0128
fa         


        
1条回答
  •  遥遥无期
    2020-12-22 10:42

    No point using "Accuracy" layer for regression task: this layer measures the accuracy of classification output.
    For instance, if you are trying to predict one of L labels, num_output of fc2 layer will be L - that is, predicting a probability per class. Then "Accuracy" layer checks that the probability of the l-th entry, corresponding to the expected output l is maximal.
    How can you compute such accuracy when fc2 output is only 1 dimensional?

    In your case, you can only check the Euclidean loss and see it decreasing for both test and train.

    0 讨论(0)
提交回复
热议问题