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

Post processing of image classification model #2640

Open
raushani2v opened this issue Nov 15, 2023 · 2 comments
Open

Post processing of image classification model #2640

raushani2v opened this issue Nov 15, 2023 · 2 comments
Assignees

Comments

@raushani2v
Copy link

raushani2v commented Nov 15, 2023

Hi,

I have trained MobileNet-V3-large-1x classifier for 2 classes using openvino training extensions. While inferring the trained onnx model, I get the result as something similar to this vector [[-1.5802931e-10 1.1259661e-10]].

Can you please tell me what these 2 values represent?

How to post-process these values to get meaningful information i.e, class label and confidence score?

@goodsong81
Copy link
Contributor

The values might be the logits for each class, which could be transformed to class probability via softmax operation. Currently, direct inference of ONNX format is not supported on OTX.
You can try to parse label_schema.json along with the ONNX file to map output index to the label name.
@sovrasov Could you help?

@sovrasov
Copy link
Contributor

Hi! Indeed, OTX generates models that produce logits. I recommend ModelAPI as a default tool for inference: https://pypi.org/project/openvino-model-api/
It supports inference of ONNX models via OpenVINO or ONNXRuntime

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

3 participants