feat: add sparse GTiff fixtures - #70
Open
ljstrnadiii wants to merge 1 commit into
Open
ljstrnadiii wants to merge 1 commit into
ljstrnadiii wants to merge 1 commit into
Conversation
GDAL/rasterio support "sparse" tiled TIFFs (SPARSE_OK=YES): a tile the encoder never wrote has TileOffsets == TileByteCounts == 0. uint8_1band_sparse_nodata.tif has nodata=7 and only tile (0, 0) written; uint8_1band_sparse_no_nodata.tif is the same with no GDAL_NODATA tag. Written directly with the plain GTiff driver rather than write_utils.write_cog, since that helper's COG-driver copy step may not preserve sparseness.
This was referenced Sep 11, 2026
ljstrnadiii
marked this pull request as ready for review
September 11, 2026 20:11
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.
Summary
Adds two fixtures for sparse-tile support: a tile GDAL never writes has
TileOffsets == TileByteCounts == 0(TIFF6/COG sparse convention).rasterio_generated/fixtures/uint8_1band_sparse_nodata.tif— 512x512, single band, 2x2 tiles,GDAL_NODATA=7, only tile (0, 0) written.rasterio_generated/fixtures/uint8_1band_sparse_no_nodata.tif— same, noGDAL_NODATAtag, exercises the zero-fill default.Generated with plain
rasterio.open(driver="GTiff", sparse_ok=True, ...), notwrite_utils.write_cog— that helper's COG-driver copy may not preserve sparseness.pixi run generate+pixi run infoproduce no diff to any other fixture.Status
Ready for review. Blocks developmentseed/async-tiff#340 and developmentseed/async-geotiff#175 — merge in that order. CI is pending manual workflow approval (
action_required), not failing.Pre-merge checklist
🤖 Generated with Claude Code