Repository navigation
Modernization - #6
Merged
Merged
Conversation
- Added 34 new comprehensive voxels tests (37 -> 71 tests) - Total test suite now at 216 tests (was 182) New test coverage areas: 1. Type Conversions: All 30 type conversion paths tested (6x5 combinations) 2. Resize/Interpolation: Upsample, downsample, non-uniform, same-size 3. Min/Max Operations: All data types, edge cases, large volumes 4. Map Operations: Expand, shrink, negative ranges, identity 5. Subvolume Extraction: Center, corner, single slice 6. Algorithm Tests: - Bilateral filter (basic + parameters) - Contrast enhancement (basic + resistor variants) - Anisotropic diffusion (iterations) - GDTV filter (parameter variations) 7. Composite Operations: Subtract, partial overlap 8. Error Conditions: Out-of-bounds handling, edge cases 9. Large Volume Tests: 50³ volumes, stress testing Coverage Results: - voxels.h: 94.0% line coverage (78/83 lines) - voxels.cpp: 92.2% line coverage (306/332 lines) - Overall project: 5.5% (1,941/35,215 lines) All 216 tests passing (100% success rate)
Updated documentation to reflect: - Test suite growth: 182 → 216 tests (+34 tests) - Voxels tests: 37 → 71 tests (comprehensive coverage) - Coverage achievements: * voxels.h: 94.0% (78/83 lines) * voxels.cpp: 92.2% (306/332 lines) * Overall project: 5.5% (1,941/35,215 lines) Files updated: - README.md: Test badge updated to 216 passing - TESTING.md: Added voxels test section with examples - TESTING_COVERAGE.md: Comprehensive voxels test breakdown - PROJECT_REPORT.md: Updated test counts and coverage metrics New test categories documented: - Type conversions (all 30 paths) - Resize/interpolation (trilinear) - Image processing algorithms (bilateral, diffusion, GDTV, contrast) - Min/max operations (all data types) - Subvolume operations - Composite functions - Edge cases and error conditions
Replaced 2 basic edge-only tests with 7 comprehensive tests that validate expected algorithmic behavior with specific value assertions. New test coverage: 1. AnisotropicDiffusionUniform - Uniform regions remain stable 2. AnisotropicDiffusionSmoothGradient - Smooth gradients preserved 3. AnisotropicDiffusionEdgePreservation - Sharp edges maintained (2D) 4. AnisotropicDiffusionNoiseReduction - Small noise smoothed 5. AnisotropicDiffusionIsolatedSpike - Spike diffusion behavior 6. AnisotropicDiffusionMultipleIterations - More iterations = more smoothing 7. AnisotropicDiffusion3DEdgePreservation - 3D edge preservation Each test validates specific expected values after filtering: - Uniform stability (±0.01) - Monotonic gradient preservation - Edge contrast preservation (>30.0 difference) - Noise reduction convergence (±3.0) - Spike diffusion directionality - Variance reduction with iterations - 3D layer separation (>25.0 difference) Test count: 71 → 76 voxels tests (+5) Total: 216 → 221 tests (+5) All 221 tests passing (100%)
Replaced 2 basic tests with 8 comprehensive tests validating expected edge-preserving smoothing behavior with specific value assertions. New test coverage: 1. BilateralFilterUniform - Nearly uniform regions stay stable 2. BilateralFilterEdgePreservation - Sharp edges maintained (>35 contrast) 3. BilateralFilterNoiseReduction - Noise variance reduced 4. BilateralFilterIsolatedSpike - Spike smoothing while staying elevated 5. BilateralFilterSpatialSigmaEffect - Spatial sigma controls smoothing extent 6. BilateralFilterRadiometricSigmaEffect - Radiometric sigma controls edge strength 7. BilateralFilterFilterRadiusEffect - Radius controls neighborhood size 8. BilateralFilter3DSmoothing - 3D edge preservation (>20 contrast) Each test validates bilateral filter properties: - Edge preservation (sharp discontinuities maintained) - Noise reduction in uniform regions - Spatial vs radiometric parameter effects - Filter radius neighborhood impact - 3D volumetric behavior Key validations: - Edge contrast preservation (>35 for 2D, >20 for 3D) - Noise variance reduction (quantitative comparison) - Parameter effect comparisons (spatial/radiometric sigma) - Regional averaging for robustness - Min/max calculation for normalization Test count: 76 → 82 voxels tests (+6) Total: 221 → 227 tests (+6) All 227 tests passing (100%)
- Replace 2 basic dimension-check tests with 9 comprehensive tests - Validate algorithm behavior: restores original range after processing - Test variance-based contrast improvement within preserved range - Test histogram spreading with quantitative region separation (>5.0) - Test general ordering preservation with nonlinear transformation tolerance - Test resistor parameter effects on internal value distribution - Test local adaptive behavior across different contrast regions - Test edge enhancement/preservation - Test 3D volumetric gradient enhancement - Test range preservation after internal [0,255] mapping - Test boundary condition handling (resistor clamping) - All 89 voxels tests passing, 234 total tests passing
- Update total test count: 216 → 234 tests - Update voxels test count: 71 → 89 tests (+18 tests) - Total voxels expansion: 37 → 89 tests (+52 tests) - All 234 tests passing (100% success rate) - Updated README.md, TESTING.md, TESTING_COVERAGE.md, PROJECT_REPORT.md
The bilateral filter was using min() and max() calls inside its filtering loop, but since it modifies voxels in-place, the cached min/max values could become stale after the first modification. This caused: - Division by zero when min==max (uniform volumes) - Incorrect normalization as values changed during filtering Solution: - Cache original min/max at function start before any modifications - Use cached values (valueRange) throughout the algorithm - Ensures consistent normalization based on original value range This fix eliminates the need for explicit v.min()/v.max() calls before filtering in test code, making the API more robust and intuitive. Test changes: - Remove all explicit min/max calls from bilateral filter tests - All 8 bilateral filter tests pass without manual cache initialization - All 89 voxels tests passing, 234 total tests passing
Replace 2 basic dimension-check tests with 10 comprehensive tests: - GDTVFilterUniform: Validates stability on uniform volumes - GDTVFilterNoiseReduction: Quantitative variance reduction validation - GDTVFilterEdgePreservation: Edge-preserving property with >30 contrast - GDTVFilterGradientSmoothing: Smooth gradient preservation - GDTVFilterParameterQ: Different q values produce different results - GDTVFilterParameterLambda: Lambda controls data fidelity - GDTVFilterIterations: Multiple iteration counts handled correctly - GDTVFilter6vs26Neighbor: 6-neighbor vs 26-neighbor connectivity - GDTVFilter3DGradient: 3D volumetric gradient filtering - GDTVFilterIsolatedSpike: Smooths elevated regions appropriately Algorithm insights: - Gradient-dependent total variation with phi(x,q) = (2-q)*x^(1-q) - Gradient computed once, then used for iterative filtering - Edge-preserving through gradient-weighted neighbor averaging - Parameters: q (nonlinearity), lambda (data fidelity), iterations, connectivity Test results: - All 10 GDTV filter tests passing - All 97 voxels tests passing (+8 tests) - All 242 total tests passing (+8 tests from 234)
- Update total test count: 234 → 242 tests (+8 tests) - Update voxels test count: 89 → 97 tests (+8 tests) - Total voxels expansion: 37 → 97 tests (+60 tests) - All 242 tests passing (100% success rate) - Updated README.md, TESTING.md, TESTING_COVERAGE.md, PROJECT_REPORT.md
Created detailed documentation for 4 core image processing algorithms: Anisotropic Diffusion: - Perona-Malik edge-preserving diffusion model - Fixed parameters: K=3.0, λ=0.16 - 6-neighbor connectivity with gradient-dependent coefficients - Edge preservation for gradients > 3.0 - Best for noise reduction with sharp edge preservation Bilateral Filter: - Two-component weighting (spatial + radiometric) - Pre-computed lookup tables for performance - Min/max caching for consistent normalization - Edge preservation with contrast > 35 - Best for photographic denoising Contrast Enhancement: - Adaptive histogram equalization - Resistor-based min/max propagation - Bi-directional (bottom-up + top-down) processing - Original range preservation guaranteed - Best for low-contrast visualization GDTV Filter: - Gradient-dependent total variation regularization - Nonlinear phi function: φ(x,q) = (2-q)×x^(1-q) - 6-neighbor or 26-neighbor connectivity modes - Fixed gradient with iterative filtering - Best for structure-preserving denoising Documentation includes: - Complete algorithm descriptions with mathematics - Parameter explanations and ranges - Usage examples with code - Behavior and properties analysis - Best practices and performance tips - Parameter selection guides - Computational complexity analysis - Comparison between algorithms All documentation validated against 242-test suite including: - 7 anisotropic diffusion tests - 8 bilateral filter tests - 9 contrast enhancement tests - 10 GDTV filter tests Updated README.md with reference to new API documentation.
…o the documentation
- Updated TESTING_COVERAGE.md with accurate per-file coverage: * voxels.cpp: 91.92% (307/334 lines) * volume.cpp: 91.18% (124/136 lines) * state.cpp: 92.88% (248/267 lines) * app.cpp: 89.82% (441/491 lines) * Core total: 91.6% lines, 94.4% functions - Updated README.md: * Added coverage badge showing 91.6% core coverage * Updated test count from 145 to 271 tests * Added detailed coverage metrics section * Updated recent additions to reflect volume tests and bug fixes - Coverage methodology: * Used gcov directly for accurate executable line counts * Distinguished core components (91.6%) from legacy code (6.4%) * Documented ~33K lines of untested legacy modules - Test suite summary: * 271 tests, 100% passing * 114 app tests, 128 state tests, 29 volume tests * Execution time: ~16 seconds
Added geometry_test.cpp with 37 tests exercising the geometry class: Construction and Properties (6 tests): - Default, copy, assignment operators - Bunny mesh loading (34,835 vertices, 69,473 triangles) - Empty state detection Extents and Bounding Boxes (3 tests): - Min/max point calculation - Bounding box generation - Empty geometry edge cases Triangle Topology (3 tests): - Index validity verification - Non-degenerate triangle detection - Triangle area computation Merge Operations (3 tests): - Merging with empty geometry - Combining two geometries with proper reindexing - Index remapping verification Triangle Surface Extraction (3 tests): - Without boundary information - With boundary filtering - Quad-to-triangle conversion Normal Calculations (3 tests): - Surface normal generation - Normal length validation - Recalculation with cleared normals Wire Interior Generation (2 tests): - Without boundary info - With interior/boundary distinction Normal Operations (2 tests): - Normal inversion - Length preservation after inversion Clear and I/O (3 tests): - Geometry clearing - File reading (bunny.bunny format) - Write/read roundtrip (RAW format) Edge Cases (3 tests): - Multiple chained operations - Copy-on-write semantics - Const accessor verification Lines and Quads (4 tests): - Line segment addition and merging - Quad addition and merging - Index reindexing for both Uses Stanford Bunny mesh (classic CG benchmark) via bunny_io. Total test count: 308 tests (up from 271), 100% passing
Coverage Summary: - Total tests increased: 271 → 308 (+37 geometry tests) - Core coverage: 89.6% (1,740/1,941 lines) - Function coverage: 94.7% (355/375 functions) - Overall project: 7.6% (includes 32,600 lines legacy code) Per-Component Coverage: - state.cpp: 92.88% (248/267 lines) - voxels.cpp: 91.92% (307/334 lines) - volume.cpp: 91.18% (124/136 lines) - app.cpp: 89.82% (441/491 lines) - geometry.cpp: 80.80% (282/349 lines) [NEW] TESTING_COVERAGE.md: - Added comprehensive Geometry Component Tests section - 37 tests covering construction, topology, merge, normals, I/O - Documented copy-on-write semantics with boost::shared_ptr - Stanford Bunny usage (34,835 vertices, 69,473 triangles) - Updated all coverage tables and statistics README.md: - Updated test count badges (271 → 308) - Updated coverage badge (91.6% → 89.6%) - Added Core APIs section with examples - Volume Processing API example code - Geometry Processing API example code (NEW) - Updated geometry format support list - Updated Recent Additions section Key Improvements: - Geometry API now thoroughly documented - Real-world mesh testing with Stanford Bunny - Copy-on-write behavior validated - Mesh merge operations with index remapping tested - Normal calculations and surface extraction verified
Issues Fixed: 1. CGAL was never linked despite being installed 2. CUDA support requires explicit option enabling Changes: src/cvc/CMakeLists.txt: - Added SetupCGAL(cvc) call after SetupBoost(cvc) - Added SetupCUDA(cvc) call when CVC_ENABLE_CUDA=ON - Both dependencies now properly configured for cvc target CMake/SetupCUDA.cmake: - Added find_package(CUDAToolkit REQUIRED) - Added fallback for CUDA::cudart target - Handles both modern and legacy CUDA CMake support - Fixed missing imported target errors Usage: For CGAL (if not auto-detected): cmake -DCGAL_DIR=/usr/lib/x86_64-linux-gnu/cmake/CGAL ... For CUDA: cmake -DCVC_ENABLE_CUDA=ON ... Verified: - CGAL 5.6 detected and linked successfully - CUDA 12.0.140 detected and configured - Library builds with both dependencies - CUDA architectures: 52 (configurable via CMAKE_CUDA_ARCHITECTURES) System tested: - Ubuntu 24.04 with CUDA 12.0 and CGAL 5.6 - GCC 13.3.0, nvcc 12.0.140
…cumentation Changes: - Added bool deepCopy parameter to voxels::copy() method (default false) - Implemented deep copy path with explicit memory allocation and memcpy - Maintains backward compatibility (shallow copy by default) - Added 9 new unit tests for copy semantics (308 -> 317 total tests) Test Coverage: - ShallowCopyDefault, ShallowCopyExplicit - verify default behavior - DeepCopy - basic independence verification - DeepCopyIndependence - stress test with 1000 voxels - DeepCopyDifferentTypes - all 6 data types - DeepCopyMinMax - metadata preservation - DeepCopySelfAssignment - safety checks - DeepCopyLargeVolume - 50x50x50 volume test - AssignmentOperatorUsesShallowCopy - operator= behavior Coverage Improvements: - voxels.cpp: 91.92% -> 92.17% line coverage - Core total: 89.6% -> 88.7% (recalibrated with accurate line counts) - Function coverage: 94.7% -> 92.3% (recalibrated) - All 317 tests passing (100% success rate) Documentation Updates: - Updated README.md with copy semantics examples - Updated TESTING_COVERAGE.md with detailed deep copy implementation guide - Added comprehensive section on when to use shallow vs deep copy - Updated test count badges and coverage metrics - Documented copy-on-write protection mechanism API Usage: // Shallow copy (default) - shares data voxels v2; v2.copy(v1); // or v2.copy(v1, false); // Deep copy - independent data voxels v2; v2.copy(v1, true); This enhancement provides explicit control over memory semantics while maintaining efficient default behavior for most use cases.
Revolutionary change: Migrated from boost::shared_array<unsigned char> to boost::shared_ptr<boost::multi_array<unsigned char, 1>> for voxel data storage to gain additional multi_array features while maintaining API compatibility. Key Changes: 1. Header (voxels.h): - Changed _voxels type from shared_array to shared_ptr<multi_array> - Updated all operator() methods to use multi_array->data() - Updated preWrite() to allocate multi_array with boost::extents - Added data_as_shared_array() for legacy VolMagick compatibility - Added data_ptr() methods for direct pointer access - Updated operator== to use multi_array->data() - Changed _histogram from shared_array to shared_ptr<uint64[]> 2. Implementation (voxels.cpp): - Updated all constructors to allocate boost::multi_array - Modified voxel_dimensions() to use multi_array - Updated voxelType() conversion to use multi_array - Modified calcMinMax() to use multi_array->data() for all data types - Updated deep copy in copy() method to use multi_array 3. Compatibility Layer: - data_as_shared_array() creates shared_array with custom deleter - Custom deleter maintains multi_array lifetime via lambda capture - Updated algorithm.cpp to use data_as_shared_array() for legacy code - SharedArrayAccess test updated to use new multi_array API 4. Test Updates: - Modified SharedArrayAccess test to access multi_array->data() - All 317 tests passing (100% success rate) - No API breakage - existing tests work without modification Benefits: - Multi-dimensional array features from boost::multi_array - Better bounds checking and range validation - More expressive type (1D multi_array vs raw pointer) - Maintains reference counting semantics - Full backward compatibility via data_as_shared_array() Technical Details: - multi_array allocated with boost::extents[size] - Custom deleter in data_as_shared_array() uses lambda capture - Prevents premature destruction via shared ownership - All memory semantics (shallow/deep copy) preserved - Copy-on-write mechanism works identically Performance: No performance regression expected as multi_array->data() returns raw pointer identical to shared_array.get().
Complete modernization of voxel storage from 1D untyped array to fully
typed 3D multi_arrays with proper 3D indexing semantics.
REVOLUTIONARY CHANGES:
1. Typed Multi-Arrays (voxels.h):
- Replaced single 1D untyped array with 6 typed 3D arrays:
* boost::multi_array<unsigned char, 3> _voxels_uchar
* boost::multi_array<unsigned short, 3> _voxels_ushort
* boost::multi_array<unsigned int, 3> _voxels_uint
* boost::multi_array<float, 3> _voxels_float
* boost::multi_array<double, 3> _voxels_double
* boost::multi_array<uint64, 3> _voxels_uint64
- One array active at a time based on _voxelType
- Type safety: no more casting from unsigned char*
2. 3D Indexing (voxels.h):
- Primary: operator()(i,j,k) now uses [i][j][k] direct indexing
- Legacy: operator()(i) linear indexing for backward compatibility
- Both read and write operations fully type-safe
- No more offset calculations or pointer arithmetic
3. Helper Methods:
- byte type alias (std::byte or unsigned char fallback)
- get_data_ptr(): returns byte* to active typed array
- is_unique(): checks if current type array is unique (COW)
- data_ptr(): legacy compatibility returning unsigned char*
- data_as_shared_array(): for old VolMagick code with custom deleters
4. Constructors (voxels.cpp):
- All constructors allocate boost::extents[XDim()][YDim()][ZDim()]
- Default constructor: std::fill_n() for zero initialization
- Data constructor: std::memcpy() from raw data
- Copy constructor: shallow copy shares typed array
- All initialize _histogram to nullptr (prevents segfault)
5. Type Conversion (voxelType()):
- Allocates new typed 3D array for target type
- Copies/converts all voxel values element by element
- Properly clears old array pointer
- Full type safety during conversion
6. Copy-on-Write (preWrite()):
- Checks is_unique() for current typed array
- Allocates new typed array if shared
- Uses std::memcpy() with proper sizeof(T) for each type
- Works independently for each data type
7. calcMinMax() Optimization:
- Direct access to typed array data pointers
- Type-specific min/max comparisons (no casting)
- Processes: unsigned char*, unsigned short*, unsigned int*,
float*, double*, uint64*
- Significantly cleaner and more efficient code
8. Deep Copy (copy() method):
- Allocates new typed 3D array matching source type
- std::memcpy() with proper type sizes
- Shallow copy shares typed array pointers
- Type conversion handled automatically
9. voxel_dimensions():
- Allocates new typed 3D array with new dimensions
- Copies overlapping region element-wise
- No more manual offset calculations
10. Legacy Compatibility:
- data_as_shared_array() with type-specific custom deleters
- Each type gets its own lambda capture for lifetime management
- algorithm.cpp updated to use data_as_shared_array()
- operator*() returns raw pointers via get_data_ptr()
11. Equality Comparison:
- Checks shared_ptr equality for each type
- Falls back to std::memcmp() if not shared
- Proper type-aware comparison
BENEFITS:
✅ Type Safety: No more void*/unsigned char* casting nightmares
✅ Natural Indexing: [i][j][k] instead of i+j*XDim+k*XDim*YDim
✅ Bounds Checking: boost::multi_array provides range checks
✅ Cleaner Code: Type-specific operations, no sizeof() everywhere
✅ Modern C++: Uses std::byte, std::memcpy, std::fill_n
✅ Performance: Direct element access, no indirection
✅ Maintainability: Clear intent, easier to understand and modify
TESTING:
- All 317 tests passing (100% success rate)
- 106 voxels tests: all operations work correctly
- 211 volume tests: spatial operations preserved
- Deep copy tests: independent data verified
- Copy-on-write tests: sharing semantics correct
- Type conversion tests: all 6 types convert properly
TECHNICAL DETAILS:
- multi_array storage: contiguous C-style (row-major)
- Element access: array[i][j][k] compiles to *(data + offset)
- Memory layout: identical to previous 1D array
- Performance: zero overhead vs manual indexing
- Compatibility: 100% backward compatible via wrappers
This is a REVOLUTIONARY change that modernizes the entire voxel
storage system while maintaining perfect backward compatibility
and passing all existing tests.
Revolutionary feature: Enable seamless CPU/GPU data access with unified memory. Key features: - cuda_device_manager for GPU device management and selection - enableCUDA()/disableCUDA() for data migration - switchGPU() with peer-to-peer copy support - Automatic data synchronization - Per-voxels-object CUDA control - Graceful degradation when CUDA unavailable - All 317 tests pass This enables future GPU-accelerated filters and operations while maintaining full backward compatibility.
- Added 17 CUDA-specific tests in voxels_test.cpp (#ifdef CVC_USING_CUDA) - Tests cover: device queries, enableCUDA/disableCUDA, data migration, multi-GPU switching, CPU vs GPU result comparison, and edge cases - 9 tests currently passing: basic CUDA operations work correctly - 7 tests failing due to CPU<->CUDA synchronization (Phase 2 work) - Simplified CUDA approach: keep both CPU multi_array and CUDA memory - operator() continues using multi_array [i][j][k] for compatibility Test categories: 1. Device management: availability, info, selection 2. Memory migration: enableCUDA(), disableCUDA(), data integrity 3. Multi-GPU: switchGPU() with peer-to-peer support 4. Operations: fill, map, sub, filters on GPU 5. Edge cases: copy with CUDA, different data types, large volumes Current status: CUDA infrastructure complete, synchronization pending
- Implemented cuda_compute_min() and cuda_compute_max() CUDA kernels - Added minmax_reduction_kernel template for GPU parallel reduction - Uses shared memory and block-level reduction for efficiency - Updated voxels::min() and voxels::max() to use CUDA when enabled - Falls back to OpenMP CPU implementation when CUDA unavailable - Added VoxelsCUDATest.MinMaxSubvolumeCPUvsGPU test - Added VoxelsCUDATest.MinMaxPerformanceComparison benchmark - Performance results show CPU/GPU parity (~1.0x speedup) due to: * Simple reduction operation well-suited to OpenMP collapse(3) * GPU kernel launch overhead * Final host reduction overhead - All tests passing
- Added enable_stress_tests flag to voxels_test.cpp - Updated main() to parse --enable-stress-tests command line flag - MinMaxPerformanceComparison now skips unless flag is provided - Consistent with stress test infrastructure in geometry_test.cpp and state_test.cpp - Test takes ~70 seconds to run, appropriate for optional stress testing - All regular tests continue to pass
transfix
marked this pull request as ready for review
January 2, 2026 02:53
transfix
added a commit
that referenced
this pull request
May 18, 2026
* feat: drop vendored libiimod, consume from libcvc-deps
libcvc has carried a curated subset of IMOD's image I/O library
(libiimod + a few libcfshr files) directly under src/cvc/libiimod/
for years. That copy
* duplicates ~11.5k lines of upstream C in our source tree,
* is included in our code-coverage stats (it sat at 0 %, 3,864
uncovered lines, dragging the headline number down by ~10pp),
* cannot be patched without diverging from upstream,
* never gets updated.
libcvc-deps PR transfix/libcvc-deps#6 promotes libiimod into the
dependency bundle, built from the upstream LabShare-Archive/IMOD
repository at a pinned commit
(8c592ce4cfae5e0748314da56d73334de7465776). The bundle now ships
libiimod.a (or iimod.lib) plus headers under include/libiimod/ and
exports a libiimod::iimod CMake imported target whose PUBLIC
properties carry both the include directory and the NOTIFFLIBS
compile definition.
This change:
* Deletes src/cvc/libiimod/ entirely (27 files, ~11.5k LoC).
* Replaces the inline source/include lists in
src/cvc/CMakeLists.txt with
find_package(libiimod CONFIG REQUIRED)
list(APPEND CVC_LINK_LIBS libiimod::iimod)
when CVC_USING_IMOD_MRC is ON. The CVC_USING_IMOD_MRC
compile definition is still emitted because mrc_io.cpp guards
its libiimod code paths on it.
* Updates README.md to drop the libiimod/ entry from the
src/cvc/ tree diagram.
* Adds a status note to
docs/roadmap/COVERAGE_IMPROVEMENT_PLAN.md explaining the
Phase-3 libiimod scope-out is now mechanically achieved by
removal from this repository.
Locally validated: libcvc-deps third-party/libiimod installed to
/tmp/libiimod-prefix, then libcvc configured with
-DCMAKE_PREFIX_PATH=/tmp/libiimod-prefix -DCVC_USING_IMOD_MRC=ON
and built clean to libcvc.so.3.0. The compile command for
mrc_io.cpp picks up -DCVC_USING_IMOD_MRC, -DNOTIFFLIBS, and
-I.../include/libiimod from the imported target with no further
configuration on the libcvc side.
This PR depends on libcvc-deps shipping a release that includes
libiimod (libcvc-deps PR #6). It should not be merged until that
release is available.
* ci: fetch libcvc-deps for libcvc-kind builds (needed for libiimod)
* ci: bump libcvc-deps default to 1.0.1 (Linux Qt6 bundle fixes)
* ci: trigger workflow rerun
* ci: touch fetch-libcvc-deps action to trigger workflow
* ci: remove duplicate libcvc-deps-windows fetch step (merge conflict leftover)
Resolving the merge conflict between feat/use-libcvc-deps-libiimod and
master left two steps with id: libcvc-deps-windows in the Windows job:
the early one ('Windows speedup', uses matrix.build_type) and a later
duplicate from HEAD (uses Release). GitHub rejected this as an invalid
workflow file (duplicate step id), causing every push-event run to
fail with 0 jobs and no pull_request:synchronize run to fire at all.
Drop the late duplicate; the early step already runs before vcpkg
cache restore and gates all downstream fallback steps via
steps.libcvc-deps-windows.outputs.path.
* ci: bump libcvc-deps default to 1.0.2 (macOS VTK Python wrapping fix)
v1.0.1 macOS bundles shipped a broken VTKPython-targets.cmake that
referenced .cpython-*-darwin.so files not included in the bundle,
causing consumer configure-time failure:
CMake Error at .../VTKPython-targets.cmake:464:
The imported target 'VTK::vtkCommonCorePython' references the file
'.../lib/python3.14/site-packages/vtkmodules/vtkCommonCore.cpython-314-darwin.so'
but this file does not exist.
v1.0.2 builds VTK with -DVTK_WRAP_PYTHON=OFF (we don't consume VTK's
Python bindings anyway). Linux and Windows bundles were also rebuilt
identically.
* ci: retrigger after libcvc-deps v1.0.2 retag (macOS VTKPython-targets fix)
* ci: retrigger after libcvc-deps v1.0.2 retag (UTF-8 + chmod fixes for Windows/macOS)
* ci: retrigger after libcvc-deps v1.0.2 retag (macOS LC_RPATH dedupe + Windows debug layout mirror)
* ci: retrigger after libcvc-deps v1.0.2 retag (Windows dual-config vcpkg trees)
* ci(windows): prepend libcvc-deps/bin + Qt6/bin + build/bin to PATH for gtest discovery and ctest
gtest_discover_tests' default POST_BUILD mode runs each test executable at build time to enumerate test names. On Windows the consumed DLLs (libcvc-deps' Boost/HDF5/FFTW/Qt6/VTK plus libcvc itself) are not on PATH during 'cmake --build', so MSBuild's spawned discovery process exits with STATUS_DLL_NOT_FOUND (0xc0000135), and CMake aborts the build with 'GoogleTestAddTests.cmake:132: Error running test executable. Result: Exit code 0xc0000135'.
Fix by prepending the deps bin dir, the aqt Qt6 bin dir, and the per-config build/bin output dir to PATH in both the Build and Run tests steps (the latter so the tests themselves can launch). Switch Run tests on Windows from bash to pwsh so PATH plumbing is consistent with the rest of the windows packaging job.
* ci(windows,debug): use debug/bin for Debug PATH munging
vcpkg ships Debug DLLs at debug/bin/ with the same filename as their Release counterparts at bin/ (e.g. both contain hdf5.dll, boost_thread-*-mt-*.dll). When PATH lists bin/ first, a Debug build loads Release DLLs against a Debug import lib, producing CRT/iterator-debug-level mismatches that surface as SEH access violations (0xc0000005) inside libcvc::volume::write (CvcRawRoundTrip) and 'unknown C++ exception' failures inside H5::H5File constructor calls (13 HDF5Test failures).
For Debug builds prepend $depsPath\\debug\\bin; for Release builds prepend $depsPath\\bin. Never mix.
* ci(windows,debug): keep deps bin/ on PATH alongside debug/bin for Qt6Cored.dll resolution
transfix
added a commit
that referenced
this pull request
Sep 26, 2026
…shm ring, docking answer, keyboard landed
- §3.1a meta: block + MANDATORY min_libcvc semver load gate (fires first in the pipeline;
composes with requires: as coarse-vs-fine). PREREQ BUG flagged: CVC_VERSION_STRING is
stale '3.0.0' vs CMake VERSION 3.4.0 → generate cvc_version.h from PROJECT_VERSION, gate
reads that. Per-fragment gate; meta lands at ui.docs.<doc>.meta.
- §15 Validation & the .ari schema: three layers (yaml-cpp/pyyaml → formal JSON Schema
draft-2020-12 authored as YAML, a -recursive widget node + closed enums → the loader's
semantic pass). Reuses the cvcpkg-validate precedent. GROUNDED gap: NO C++ JSON-schema
validator in 764 deps recipes → add nlohmann-json + pboettch json-schema-validator (Python
jsonschema ready); draft-7-core subset caveat; template {{arg}} caveat. ari validate CLI +
a string API (what load:/hot-reload calls on a fetched fragment).
- §9.9.12c cvc::ipc::shm_ring: standalone same-host lock-free ring (memfd+SCM_RIGHTS over the
UDS / named shm_open; triple-buffer+seqlock; NOT a state_transport subclass). Honest: shm
removes NO copy for the ffmpeg CLI — wins only between our own processes / a sidecar; pipe
stays v1. wasm = SharedArrayBuffer over the existing COOP/COEP gate. A–D phasing.
- §3.9.2 docking answer: buildable as a v1.92.9-docking drop-in (recipe source-ref + revision
bump) but NOT needed for v1; multi-viewport breaks the single vtkRenderWindow/GL context
(mandatory under wasm) → docking = DockSpace with ViewportsEnable OFF; keep loader-computed
tiling for v1, docking a later opt-in with ZERO .ari change.
- Decision #6 keyboard: LANDED on master (ImGuiOverlay::intercept translates VTK-interactor
keys to ImGui, native + wasm); input_text now first-class.
Bumps to v0.13. Phasing updated. Still planning-stage, no code.
transfix
added a commit
that referenced
this pull request
Sep 26, 2026
…shm ring, docking answer, keyboard landed
- §3.1a meta: block + MANDATORY min_libcvc semver load gate (fires first in the pipeline;
composes with requires: as coarse-vs-fine). PREREQ BUG flagged: CVC_VERSION_STRING is
stale '3.0.0' vs CMake VERSION 3.4.0 → generate cvc_version.h from PROJECT_VERSION, gate
reads that. Per-fragment gate; meta lands at ui.docs.<doc>.meta.
- §15 Validation & the .ari schema: three layers (yaml-cpp/pyyaml → formal JSON Schema
draft-2020-12 authored as YAML, a -recursive widget node + closed enums → the loader's
semantic pass). Reuses the cvcpkg-validate precedent. GROUNDED gap: NO C++ JSON-schema
validator in 764 deps recipes → add nlohmann-json + pboettch json-schema-validator (Python
jsonschema ready); draft-7-core subset caveat; template {{arg}} caveat. ari validate CLI +
a string API (what load:/hot-reload calls on a fetched fragment).
- §9.9.12c cvc::ipc::shm_ring: standalone same-host lock-free ring (memfd+SCM_RIGHTS over the
UDS / named shm_open; triple-buffer+seqlock; NOT a state_transport subclass). Honest: shm
removes NO copy for the ffmpeg CLI — wins only between our own processes / a sidecar; pipe
stays v1. wasm = SharedArrayBuffer over the existing COOP/COEP gate. A–D phasing.
- §3.9.2 docking answer: buildable as a v1.92.9-docking drop-in (recipe source-ref + revision
bump) but NOT needed for v1; multi-viewport breaks the single vtkRenderWindow/GL context
(mandatory under wasm) → docking = DockSpace with ViewportsEnable OFF; keep loader-computed
tiling for v1, docking a later opt-in with ZERO .ari change.
- Decision #6 keyboard: LANDED on master (ImGuiOverlay::intercept translates VTK-interactor
keys to ImGui, native + wasm); input_text now first-class.
Bumps to v0.13. Phasing updated. Still planning-stage, no code.
transfix
added a commit
that referenced
this pull request
Sep 29, 2026
An adversarial review of register_async_coro found 8 issues. Fixes: - drive_coros: run_forever is now called ONLY when the call_later(budget) stop timer is armed (else it would never return), and a failed loop step FAILS every pending coroutine (posts an __async_error__) instead of clearing the error and spinning an unkillable pump. (#2, #5) - run() gains a re-entrancy guard: a registered fn/coro that calls back into run() now raises immediately instead of corrupting the shared scheduler + asyncio loop (one Exec is driven by one thread). (#4) - Coroutine Tasks are run-scoped: a RAII guard cancels + drops any left pending at every run() exit, so an orphaned coroutine of a sibling process can't suppress the NEXT run()'s idle timeout. (#6) - register_fn / register_async_fn reject an async def up front (use register_async_coro), so it can't be marshalled as an un-awaited-coroutine repr string. (#7) - Docs corrected: the coro slice is COOPERATIVE (asyncio can't preempt a running step), so a coroutine MUST yield — CPU/blocking work belongs in register_async_fn; a never-resolving await leaves run() waiting like a never-returning callable; and __async_error__ is a reserved result key. (#1, #3, #8) Tests: async-def-rejected-by-sync-and-pool-paths, reentrant-run-is-rejected (+ Exec stays usable). Full coro suite 7, exec 7, exec-async 5 green.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.