Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

why the accuracy is very low when i use my own picture #4

Open
xzshen opened this issue Nov 28, 2017 · 1 comment
Open

why the accuracy is very low when i use my own picture #4

xzshen opened this issue Nov 28, 2017 · 1 comment

Comments

@xzshen
Copy link

xzshen commented Nov 28, 2017

I have a question, I use your source code to build a project on vs2013 of my computer, and when I enter a handwritten digital picture into it, the recognized numbers are wrong.
is there any any requirements for image input?
I used this code to replace the original code
READ_MNIST_DATA("F:/FPGA_CNN/minst/test_images/1_00002.jpg", MNIST_IMG, -1.0f, 1.0f, 1);
is there any wrong?

@xzshen xzshen changed the title why the acc why the accuracy is very low when i use my own picture Nov 28, 2017
@changwoolee
Copy link
Owner

changwoolee commented Nov 29, 2017

Hello, xzshen.

As I tested the few different handwritten picture with Windows app, the results were not so accurate although the accuracy from the test with MNIST test data (t10k-images-idx3-ubyte and t10k-labels-idx1-ubyte) was higher than 98%. The program can't catch my handwritten digits accurately so I resized and correct the tone and brightness of the picture on Photoshop. After then, it works not bad.

I think it's because of trained weights. I'll let you know if I fix the bug.

Also, did you add the code for reading the .jpg file in READ_MNIST_DATA()? The original code is for mnist datasets, not .jpg files.
If you did, the problem might be above, and if you didn't insert the code, please try it.

Thanks for your question.
Chang-woo Lee

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants