Skip to content

Support (N, M, L) per-dimension zones in octree containers#5391

Open
cphyc wants to merge 2 commits intoyt-project:mainfrom
cphyc:feature/support-non-cubic-zones
Open

Support (N, M, L) per-dimension zones in octree containers#5391
cphyc wants to merge 2 commits intoyt-project:mainfrom
cphyc:feature/support-non-cubic-zones

Conversation

@cphyc
Copy link
Member

@cphyc cphyc commented Feb 26, 2026

PR Summary

Currently, yt only supports cubic "zones" for octrees: this means that octree datasets can only contain (N, N, N) cells in each leaf oct, where N is controlled with the dataset parameter num_zones.

This PR allows passing a tuple of values of num_zones, increasing flexibility in support of #5390. In practice, this allows having an octree of blocks, where each block contains (N, M, L) cells.

This PR should leave the RAMSES, Art and Stream frontends behaviour unchanged.

PR Checklist

  • New features are documented, with docstrings and narrative docs
  • Adds a test for any bugs fixed. Adds tests for new features.

@cphyc cphyc added this to the 4.5.0 milestone Feb 26, 2026
@cphyc cphyc added new feature Something fun and new! index: octree labels Feb 26, 2026
@cphyc cphyc mentioned this pull request Feb 26, 2026
@cphyc cphyc force-pushed the feature/support-non-cubic-zones branch from cf2d51e to d126ef5 Compare February 26, 2026 15:13
@cphyc cphyc marked this pull request as ready for review February 27, 2026 08:40
Blocks may contain more than 256 cells - prevent overflow of the uint8
@chrishavlin chrishavlin self-assigned this Mar 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

index: octree new feature Something fun and new!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants