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

Add Classification And Detection Scene #259

Merged

Conversation

ashwinvaidya17
Copy link
Collaborator

@ashwinvaidya17 ashwinvaidya17 commented Jan 22, 2025

What does this PR do?

image = Image.open("./data/coco128/images/train2017/000000000074.jpg")
image_array = cv2.cvtColor(np.array(image), cv2.COLOR_RGB2BGR)
cls_model = ClassificationModel.create_model(
    "./data/otx_models/mlc_mobilenetv3_large_voc.xml"
)
predictions = cls_model(image_array)
visualizer = Visualizer()
visualizer.save(image, predictions, "visualizer_output.jpg")
image
image = Image.open("./data/coco128/images/train2017/000000000257.jpg")
image_array = cv2.cvtColor(np.array(image), cv2.COLOR_RGB2BGR)

det_model = DetectionModel.create_model(
    "./data/otx_models/detection_model_with_xai_head.xml"
)
predictions = det_model(image_array)
visualizer = Visualizer()
visualizer.save(image, predictions, "images/visualizer_output.jpg")
image

Fixes # (issue)

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you make sure to update the documentation with your changes?
  • Did you write any new necessary tests?

@github-actions github-actions bot added the tests Related to tests label Jan 22, 2025
@ashwinvaidya17 ashwinvaidya17 changed the title Add Classification Scene Add Classification And Detection Scene Jan 22, 2025
Signed-off-by: Ashwin Vaidya <ashwinnitinvaidya@gmail.com>
Signed-off-by: Ashwin Vaidya <ashwinnitinvaidya@gmail.com>
Signed-off-by: Ashwin Vaidya <ashwinnitinvaidya@gmail.com>
Signed-off-by: Ashwin Vaidya <ashwinnitinvaidya@gmail.com>
Signed-off-by: Ashwin Vaidya <ashwinnitinvaidya@gmail.com>
@ashwinvaidya17 ashwinvaidya17 force-pushed the ashwin/visualization_scene_2 branch from 5f330ba to 36a6c56 Compare January 23, 2025 08:20
@ashwinvaidya17 ashwinvaidya17 marked this pull request as ready for review January 23, 2025 08:21
Signed-off-by: Ashwin Vaidya <ashwinnitinvaidya@gmail.com>
@sovrasov sovrasov added this pull request to the merge queue Jan 23, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 23, 2025
@sovrasov sovrasov added this pull request to the merge queue Jan 23, 2025
Merged via the queue into openvinotoolkit:master with commit 63056fc Jan 23, 2025
16 checks passed
@sovrasov sovrasov added this to the 0.2.6 milestone Jan 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tests Related to tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants