Skip to content

Refactor pyraview MEX and implement readFile functions#16

Merged
stevevanhooser merged 2 commits intomainfrom
add-readfile-functions-13897329639786336155
Feb 25, 2026
Merged

Refactor pyraview MEX and implement readFile functions#16
stevevanhooser merged 2 commits intomainfrom
add-readfile-functions-13897329639786336155

Conversation

@google-labs-jules
Copy link
Copy Markdown
Contributor

This submission refactors the MATLAB MEX implementation to expose the main processing function as pyraview.pyraview and the header reader as pyraview.get_header, hiding the "mex" suffix implementation details. It also adds robust file reading functions (readFile/read_file) for both MATLAB and Python that handle the specific Pyraview binary format (planar layout, min/max pairs). Documentation and tests have been updated and expanded to professional standards.


PR created automatically by Jules for task 13897329639786336155 started by @stevevanhooser

…mplement readFile functions

- Renamed `src/matlab/+pyraview/pyraview.c` to `src/matlab/+pyraview/pyraview_mex.c` and updated `src/matlab/build_pyraview.m` to compile it to `pyraview.mex*`. This avoids object file collisions with the C++ engine while allowing the user-facing function to be `pyraview.pyraview`.
- Updated `src/matlab/build_pyraview.m` to compile `pyraview_get_header_mex.c` to `get_header.mex*`, exposing it as `pyraview.get_header`.
- Added detailed `.m` help files for `pyraview.pyraview` and `pyraview.get_header`.
- Implemented `pyraview.readFile` (MATLAB) and `pyraview.read_file` (Python) to read level files with specific start/stop indices and planar layout support.
- Updated internal usages in `Dataset.m` and `readFile.m` to use `pyraview.get_header`.
- Updated `docs/API.md` to reflect the new API structure, including the `get_header` function and the consolidated MATLAB/Python sections.
- Refactored MATLAB tests to use class-based unit tests in `src/matlab/tests/+pyraview/+unittest/`.
- Enhanced Python tests with more comprehensive coverage and mocking.
@google-labs-jules
Copy link
Copy Markdown
Contributor Author

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@stevevanhooser stevevanhooser merged commit 5cf69f0 into main Feb 25, 2026
6 checks passed
@stevevanhooser stevevanhooser deleted the add-readfile-functions-13897329639786336155 branch February 25, 2026 00:42
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.

1 participant