-
Notifications
You must be signed in to change notification settings - Fork 34
Add random tiled raster test data #300
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds functionality to generate tiled random raster test data with nodata values at the corners. The implementation uses fastrand instead of rand for better performance in benchmarking scenarios.
- Adds
generate_tiled_rastersfunction to create a grid of raster tiles with random pixel values - Implements helper functions for corner position detection and random band data generation
- Adds utility functions
raster_arrays_equalandraster_equalfor comparing raster data structures
Reviewed Changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated 6 comments.
| File | Description |
|---|---|
| rust/sedona-testing/src/rasters.rs | Adds new functions for generating tiled rasters with random data, helper functions for nodata value placement, and raster comparison utilities |
| rust/sedona-testing/Cargo.toml | Adds fastrand dependency to the testing package |
| Cargo.toml | Adds fastrand workspace dependency at version 2.0 |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
paleolimbot
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few things to consider now or later! Thank you!
Separated out the PR for generating tiled random rasters because it was overlapping in multiple tasks (cropping, reading/writing, benchmarking).
Screenshot of the result made by writing the three bands as UInt8 with geotiff and opening with Preview. Note the no-data values in the 4 corners, which will be important for testing.
