Conversation
There was a problem hiding this comment.
Pull request overview
This PR extends the Rust Qube functionality with dimension-removal utilities and exposes additional APIs in the Python bindings, including selection and introspection helpers.
Changes:
- Added
Qube::drop()(dimension splicing/removal) andQube::squeeze()(drop dimensions with only one coordinate), plus Rust unit tests. - Added
PyQube.select(),PyQube.all_unique_dim_coords(), andPyQube.compress()to the Python bindings. - Added Python tests for
select,all_unique_dim_coords, andcompress, and updated the arena JSON roundtrip test to match the current JSON envelope shape.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
qubed/src/qube.rs |
Adds dimension dropping/splicing (drop, squeeze) and associated Rust tests. |
py_qubed/src/lib.rs |
Exposes new Python APIs (select, all_unique_dim_coords, compress) over the Rust core. |
py_qubed/tests/test_select_api.py |
Adds pytest coverage for Python select and related APIs. |
py_qubed/tests/test_qubed_api.py |
Updates JSON parsing expectations for to_arena_json() output shape. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR extends the core qubed functionality with dimension-removal utilities (drop/squeeze) and exposes the existing Rust select API to Python, aligning Python tests and coordinate parsing behavior with the ASCII “/-separated” coordinate format used across the codebase.
Changes:
- Added
Qube::drop()(dimension splicing) andQube::squeeze()(drop dimensions with only one unique coordinate) plus Rust unit tests. - Fixed
Coordinates::from_string()to split on/(matchingto_string()and ASCII conventions). - Added Python bindings and tests for
select,all_unique_dim_coords,compress,drop, andsqueeze; updated arena JSON test expectations.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
qubed/src/qube.rs |
Implements drop/squeeze via subtree splicing + compression; adds unit tests. |
qubed/src/coordinates/mod.rs |
Makes from_string parse /-separated coordinates to match serialization/ASCII. |
py_qubed/src/lib.rs |
Adds Python-facing select, all_unique_dim_coords, compress, drop, squeeze bindings. |
py_qubed/tests/test_select_api.py |
New pytest coverage for Python select/drop/squeeze/etc APIs. |
py_qubed/tests/test_qubed_api.py |
Updates arena JSON test to expect {version, qube} object shape. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Description
Contributor Declaration
By opening this pull request, I affirm the following: