Accuracy reported by caffe and pycaffe are different

人盡茶涼 提交于 2019-11-28 02:19:05

There are differences between your validation step (TEST phase) and the python code you are running:

  1. You are using a different mean file for train and test (!): for phase: TRAIN you are using mean_file: "mean.binaryproto" while for phase: TEST you are using mean_file: "painmean.binaryproto". Your python evaluation code uses the training mean file and not the validation.
    It is not a good practice to have different settings for train/validation.

  2. Your input images have new_height: 256 and copr_size: 224. This settings means caffe reads the image, scales it to 256x256 and then crops the center to size 224x224. Your python code seems to only scale the input to 224x224 without cropping: you feed your net with different inputs.

  3. Please verify that you do not have any other differences between your training prototxt and deploy prototxt.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!