Repository navigation
Fix Affine matrix multiplication warnings #939
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
Closed
Closed
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
6ff71dc
Fix Affine matrix multiplication warnings
be-student 0764a5a
TST: allow affine warnings to remain visible
be-student 345b55b
FIX: preserve affine array transforms
be-student 5440b2d
DEP: require compatible rasterio and affine versions
be-student b3a5b5d
TST: compare affine transform coefficients explicitly
be-student 7e50acc
BUG: close rasterio managers before interpreter shutdown
be-student 7ef1aee
BUG: register restored rasterio managers for shutdown
be-student cd0776b
BUG: close stranded rasterio cache handles at shutdown
be-student 3d00f63
BUG: close shared xarray cache before interpreter teardown
be-student b0e252d
CI: verify tests before tolerating Windows teardown crash
be-student 127d5af
MAINT: keep PR focused on affine multiplication
be-student 1f895d0
fix: keep affine coordinate conversion scoped to matmul
codex cd7a8e4
fix: preserve affine numpy typing
be-student File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| import numpy | ||
| from affine import Affine | ||
|
|
||
| from rioxarray._spatial_utils import affine_to_coords | ||
|
|
||
|
|
||
| def test_affine_to_coords_avoids_deprecated_matrix_multiplication() -> None: | ||
| transform = Affine(1, 0, 0, 0, -1, 4) | ||
| coords = affine_to_coords(transform, width=4, height=4) | ||
|
|
||
| numpy.testing.assert_array_equal(coords["x"], [0.5, 1.5, 2.5, 3.5]) | ||
| numpy.testing.assert_array_equal(coords["y"], [3.5, 2.5, 1.5, 0.5]) |
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.