Implement Pyraview C Engine with Python/Matlab Wrappers#1
Implement Pyraview C Engine with Python/Matlab Wrappers#1stevevanhooser merged 18 commits intomainfrom
Conversation
Implements high-performance C-based decimation engine using OpenMP. Includes Python wrapper (ctypes) and Matlab MEX gateway. Safety features: Header validation, mismatch prevention, resource cleanup. Documentation: BINARY_FORMAT.md and API.md.
|
👋 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 New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
…, double. Updated C core, Python wrapper, and Matlab MEX. Updated documentation (BINARY_FORMAT.md, API.md). Added tests for all data types. Cleaned up build artifacts.
Added .github/workflows/build_and_release.yml. Updated pyraview_header.h for alignment macros. Updated pyraview.c for large file support (_fseeki64/fseeko). Added root CMakeLists.txt and C tests.
Replaced the deprecated jwlawrence/cmake-action with lukka/get-cmake@latest.
Added comprehensive test coverage for all 10 data types, different channel counts (1, 10), and memory layouts (SxC, CxS). - C tests: `src/c/tests/test_main.c` iterates all permutations. - Python tests: `src/python/tests/test_comprehensive.py` iterates all permutations. - Matlab tests: `src/matlab/test_pyraview.m` iterates all permutations.
- Moved `int64_t ch` declaration outside OpenMP `for` loop to satisfy MSVC C3015. - Updated `src/c/CMakeLists.txt` to output binaries to a common `bin` directory on Windows and use `$<TARGET_FILE:run_tests>` for CTest to correctly locate the executable in multi-config builds.
- Added `build-matlab` job to GitHub Actions workflow. - Fixed `m.lib` linking error on Windows in CMake. - Suppressed `fopen` warnings on Windows with `_CRT_SECURE_NO_WARNINGS`.
- Updated `.github/workflows/build_and_release.yml` to collect MEX artifacts from all platforms. - Added `package-matlab` job to create a `.mltbx` file. - Added `toolboxPackaging.prj` to configure the Matlab toolbox.
- Removed manual `CMAKE_RUNTIME_OUTPUT_DIRECTORY` overrides on Windows in `src/c/CMakeLists.txt` to let CMake handle paths naturally. - Added explicit `run_tests` build step in GitHub Actions to ensure the test executable is built before running CTest.
- Added `ctest -C Release` to GitHub Actions workflow to select the correct configuration on Windows. - Set global `CMAKE_RUNTIME_OUTPUT_DIRECTORY` to `build/bin` so that `pyraview.dll` and `run_tests.exe` end up in the same directory, resolving runtime linking issues on Windows.
- Updated root `CMakeLists.txt` to enforce `CMAKE_RUNTIME_OUTPUT_DIRECTORY` (and all config variants) to `${CMAKE_BINARY_DIR}/bin`. This ensures all executables and DLLs land in the same folder on Windows, preventing path issues.
- Updated GitHub Actions workflow to run `cmake --build ... --parallel` (building "all" targets including tests) and execute tests via bash shell for consistency.
- Updated `src/c/CMakeLists.txt` to strictly enforce `CMAKE_RUNTIME_OUTPUT_DIRECTORY` to `build/bin` for all configurations. - Updated `.github/workflows/build_and_release.yml` to package binaries from `build/bin` instead of default CMake locations. - Ensured `enable_testing()` is called correctly and `add_test` uses `$<TARGET_FILE:run_tests>`.
- Updated `src/c/CMakeLists.txt` to use `add_executable(run_tests ALL ...)` and set `EXCLUDE_FROM_ALL` to `FALSE`. - Updated `.github/workflows/build_and_release.yml` to target `ALL_BUILD` explicitly during the build step.
- Reverted `add_executable(run_tests ALL ...)` to standard `add_executable(run_tests ...)` in `src/c/CMakeLists.txt` to fix potential build issues on Linux. - Removed explicit `--target ALL_BUILD` from GitHub Actions workflow to rely on default target behavior.
- Updated GitHub Actions workflow to use `egor-tensin/setup-mingw` and configure CMake with `-G "MinGW Makefiles"` on Windows. - Simplified `src/c/CMakeLists.txt` to remove MSVC multi-config path logic, using flat output directories (`build/bin`). - Removed `--config Release` and `-C Release` from build/test commands as MinGW is single-configuration.
Relies on the pre-installed MinGW environment on GitHub Actions Windows runners while keeping the `-G "MinGW Makefiles"` generator setting.
- Replaced `macos-13` with `macos-latest` in the `build-matlab` job matrix to resolve "configuration not supported" errors.
- Converted `src/matlab/test_pyraview.m` to a function-based test suite using `matlab.unittest`. - Added dynamic MEX path resolution to ensure the test can find the compiled binary regardless of working directory. - This provides better failure diagnostics in CI/CD (GitHub Actions) compared to script-based execution.
Implements high-performance C-based decimation engine using OpenMP.
Includes Python wrapper (ctypes) and Matlab MEX gateway.
Safety features: Header validation, mismatch prevention, resource cleanup.
Documentation: BINARY_FORMAT.md and API.md.
PR created automatically by Jules for task 1067385455341884938 started by @stevevanhooser