I have exported my trained tflite model. But I noticed the order of the labels in the txt file matters. I'm using image classification models. The ones with only two labels, it's an easy fix. I just switch the two. But when I have more than two labels, I notice the predictions are way off. Does it say in Vertex AI or is there a general rule to what label should go first, second, third..etc in the txt file that we create on our own?
Solved! Go to Solution.
After reviewing more about Export AutoML Edge models, you can see the following TensorFlow documentation to learn more about extracting this information.
The documentation that might help more for your question is the last one “Adding metadata to TensorFlow Lite Models”.
But what I can suggest to you is to send an email to tensorflow-enterprise-support@google.com with your question, and hopefully they can give you a direct solution to your concerns.
Additionally, I found this Stack Overflow question to create labels.txt manually.
I am still reviewing documentation to determine if there is one way to create a rule.
As soon as I collect more information about your main concern, I will share it with you as soon as possible.
After reviewing more about Export AutoML Edge models, you can see the following TensorFlow documentation to learn more about extracting this information.
The documentation that might help more for your question is the last one “Adding metadata to TensorFlow Lite Models”.
But what I can suggest to you is to send an email to tensorflow-enterprise-support@google.com with your question, and hopefully they can give you a direct solution to your concerns.
Additionally, I found this Stack Overflow question to create labels.txt manually.
Thanks! I was able to use unzip command in my terminal and extract the label file.
User | Count |
---|---|
2 | |
2 | |
1 | |
1 | |
1 |