Fix GUI detection colors by rendering the original image - #631
Draft
divyanshAgarwal123 wants to merge 1 commit into
Draft
Fix GUI detection colors by rendering the original image#631divyanshAgarwal123 wants to merge 1 commit into
divyanshAgarwal123 wants to merge 1 commit into
Conversation
Signed-off-by: Divyansh agarwal <85987665+divyanshAgarwal123@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
The image detection tab was converting the model input tensor back to a display image. When normalization is configured, that tensor no longer contains display-ready RGB values.
This change draws the predictions on the original uploaded RGB image instead. The prediction path already maps bounding boxes back to the original image coordinates. A regression test verifies that the original image is passed to the drawing function and that the normalized sample is not requested.
Reproduction
With a small RGB sample, the current conversion changed pixel (128, 64, 32) to (18, 23, 195).
Checks
Fixes #524