Open
Conversation
asmorkalov
reviewed
Jul 17, 2025
| generate_dataset(args, synthetic_object) | ||
| if configuration == "generate": | ||
| return | ||
| return |
Contributor
There was a problem hiding this comment.
It changes logic. The original "generate" just saves test images and exit. "generate_run" generates, saves and runs all benchmark steps.
Comment on lines
77
to
83
| def get_coord(num_rows, num_cols, start_x=0, start_y=0): | ||
| i, j = np.ogrid[:num_rows, :num_cols] | ||
| v = np.empty((num_rows, num_cols, 2), dtype=np.float32) | ||
| v[..., 0] = j + start_y | ||
| v[..., 1] = i + start_x | ||
| v[..., 0] = j + start_x | ||
| v[..., 1] = i + start_y | ||
| v.shape = (1, -1, 2) | ||
| return v |
Contributor
There was a problem hiding this comment.
The function is not used in the benchmark at all and may be removed.
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.
Refine benchmark script logic
get_max_errorboolean logic and remove nonexistentl3branchget_coordfunctionTransformObject.nameto empty string to avoid “none” history entries--rel_center_yget_normusingcv.intersectConvexConvexandcv.contourAreacornersinPerspectiveTransformtofloat32before callinggetPerspectiveTransformTests
tests/test_utils.pytests/test_generate_run.pyTo run locally: