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

Inconsistent results in model classification #20

Open
arc144 opened this issue Jan 22, 2020 · 0 comments
Open

Inconsistent results in model classification #20

arc144 opened this issue Jan 22, 2020 · 0 comments

Comments

@arc144
Copy link

arc144 commented Jan 22, 2020

First of all thank you for your code!

I've converted a classification model to tflite and I'm trying to run it using your lib but the results do not match. I've already verified the conversion (running the .tflite in Python) and it's ok. Thus I believe it could be a pre-processing fault.

I don't know much about Java but from what I've understood from your code it does the following:

  1. Loads the image given a path (in RGB)
  2. Resizes it to the model's input size (implicit determined from the .tflite)
  3. Subtracts the specified mean and divides by the std
  4. Runs the .tflite on the image
  5. Gets the TopK results and filters by the given threshold

Is my assessment correct? The TopK is applied on the raw logits or softmaxed?

My model only needs a RGB 299x299x3 image, where mean and std are 127.5 but even so I cannot reproduce the results.

Thank you for your time

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

1 participant