Skip to content

Add ROI anchoring to iterator grid tiling - #293

Closed
Henrik-KM wants to merge 1 commit into
BioVisionCenter:mainfrom
Henrik-KM:feat/roi-anchored-grid
Closed

Henrik-KM wants to merge 1 commit into
BioVisionCenter:mainfrom
Henrik-KM:feat/roi-anchored-grid

Conversation

@Henrik-KM

Copy link
Copy Markdown

Closes #246.

by_grid(anchor="roi") starts a grid at each ROI's pixel origin and applies the tail policy at that ROI's edge. In the issue's four-field mosaic, tail="shift" yields 144 tiles of 100 × 100 pixels. Tiles carry their parent mask labels and get distinct names when ROIs overlap. Chunk and write-unit tiling use the image grid.

The iterator guide shows how to tile a field-of-view table and explains the extra overlap that shifted edge tiles can introduce.

Verification

  • All 355 iterator tests passed, including regressions for tile geometry, mask labels, overlapping ROI names, and storage alignment.
  • Compared the serialized default tiling, block, and storage results against upstream in 14 cases. All matched byte for byte.
  • Changed-file pre-commit hooks and the locked Pixi type check passed.

Checklist before merging

  • I added an appropriate entry to CHANGELOG.md.

OpenAI Codex prepared, implemented, and tested this change.

@lorenzocerrone

Copy link
Copy Markdown
Collaborator

Hi @Henrik-KM, thanks for the interest in ngio.

I'm closing this along with #293–#296, for the same reason: the linked issues don't have an agreed solution yet, and the new-API ones in particular need a design discussion before a PR can be reviewed.

If you'd like to contribute, please propose the approach on the issue first, and open a PR once there's agreement on the direction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

by_grid: add anchor="roi" to tile relative to each ROI instead of the image

2 participants