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

Support for the positive scale in xee added. #154

Merged
merged 18 commits into from
Apr 2, 2024
Merged

Conversation

dabhicusp
Copy link
Collaborator

As indicated in the title, Xee does not work properly when the positive scale is passed. To address this, I have included a logic that can also operate on the positive scale.

The reference notebook, which includes all possible test cases, can be found here Reference notebook

xee/ext.py Outdated Show resolved Hide resolved
xee/ext.py Outdated Show resolved Hide resolved
xee/ext.py Show resolved Hide resolved
@mahrsee1997 mahrsee1997 requested a review from naschmitz March 29, 2024 17:55
xee/ext.py Outdated Show resolved Hide resolved
xee/ext.py Outdated
x_start, y_start, x_end, y_end = bbox
width = x_end - x_start
height = y_end - y_start

# Found the actual coordinates of the first or last point of the bbox based on the pos & neg scale in the actual image.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This comment needs some line-rewrapping. Consider re-writing to capture the weirdness of EE bounding boxes:

Origin (transform translation) cannot be found by simply identifying the min and max extents of the EE bounding box. The bounding boxes can be flipped (negative scale).

xee/ext.py Outdated Show resolved Hide resolved
@dabhicusp dabhicusp requested a review from naschmitz April 2, 2024 17:12
@copybara-service copybara-service bot merged commit 7fe930c into main Apr 2, 2024
11 checks passed
@dabhicusp dabhicusp deleted the translate_origin branch April 2, 2024 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants