A GPU-accelerated re-implementation of fast-openISP,
aiming to push an image signal processing pipeline onto the GPU for real-time throughput.
Report bug
·
Request feature
openISP is a Python reference implementation of a classic image signal processing pipeline. fast-openISP is its successor: a drop-in, NumPy-vectorized rewrite that gets the same pipeline running over 300x faster on the CPU.
HyperISP picks up where fast-openISP leaves off. The pipeline stages are inherently data-parallel. Each one maps a function over every pixel of a frame, which makes them a natural fit for the GPU. By re-implementing the pipeline in C++/CUDA, HyperISP aims to take the same algorithms several steps further: from "fast enough to batch-process on a CPU" to "fast enough for real-time, frame-by-frame processing".
HyperISP is written in modern C++/CUDA. Each pipeline stage is an independent IspBlock that
operates on shared PipelineData (Bayer, demosaiced RGB, and YCbCr frame buffers), launched on a
CUDA stream. Per-camera tuning is read from a TOML config file (see configs/), which
also controls which blocks are enabled.
Mirroring the fast-openISP pipeline, the following stages are planned:
- DPC — Dead Pixel Correction
- BLC — Black Level Compensation
- AAF — Anti-aliasing Filter
- AWB — Auto White Balance
- CFA — Color Filter Array Demosaicing
- CNF — Chroma Noise Filtering
- CCM — Color Correction Matrix
- GAC — Gamma Correction
- CSC — Color Space Conversion
- NLM — Non-Local Means Denoising
- BNF — Bilateral Noise Filtering
- CEH — Contrast Enhancement
- EEH — Edge Enhancement
- FCS — False Color Suppression
- HSC — Hue & Saturation Control
- BCC — Brightness & Contrast Control
- SCL — Scaling
Running times for each stage on a 1920x1080, 12-bit RGGB frame, compared against fast-openISP:
| Block | fast-openISP | HyperISP | Speedup |
|---|---|---|---|
| DPC | 0.29 s | 1.9 ms | 152.6x |
| BLC | 0.02 s | 0.02 ms | 1000x |
| AAF | 0.08 s | 0.9 ms | 88.8x |
| AWB | 0.02 s | 0.03 ms | 666.7x |
| CFA | 0.20 s | 0.94 ms | 212.7x |
| CNF | 0.25 s | 0.7 ms | 357.1x |
| CCM | 0.06 s | 0.7 ms | 85.7x |
| GAC | 0.07 s | 0.4 ms | 175x |
| CSC | 0.06 s | 0.8 ms | 75x |
| NLM | 5.37 s | 24.8 ms | 216.5x |
| BNF | 0.75 s | 1.6 ms | 469x |
| CEH | 0.14 s | [x] | |
| EEH | 0.24 s | [x] | |
| FCS | 0.08 s | [x] | |
| HSC | 0.07 s | [x] | |
| BCC | 0.03 s | [x] | |
| End-to-end | 7.82 s | [x] |
Requirements:
- CMake 3.20 or higher
- CUDA Toolkit (nvcc 13.3 is preferable) with a C++23-capable host compiler
- Git (for fetching the
tomlplusplusdependency)
# Clone the repository
git clone https://github.com/moesay/hyperISP.git
cd hyperISP
# Configure and build
cmake -S . -B build
# If CMake have some problems with C++23, manually pass the standard flags
cmake -S . -B build -DCMAKE_CUDA_COMPILER=<cuda_path>/cuda-13.3/bin/nvcc -DCMAKE_CXX_STANDARD=23
cmake --build buildAfter building libhyperisp.a, you can build the example
# Configure and build the example/s
cmake -S examples/ -B examples/build -DCMAKE_CUDA_COMPILER=<cuda_path>/cuda-13.3/bin/nvcc -DCMAKE_CXX_STANDARD=23
cmake --build examples/build/
./examples/build/hyperisp_example -c configs/nikon_d3200.toml -r test_raws/test.rawEach camera/sensor has its own TOML config under configs/, describing the sensor
layout (resolution, bit depth, Bayer pattern) and the tunable parameters for every pipeline stage,
plus a per-block enable/disable switch.
Contributions are welcome — feel free to fork the repo, open issues, and submit pull requests for new pipeline blocks, optimizations, or fixes.
Before opening a PR, please format any C++/CUDA changes with the .clang-format config provided
at the project root (4-space indentation, no tabs):
clang-format -i <changed files>and make sure the project still builds with cmake --build build.
HyperISP is licensed under the GNU General Public License v3.0 (GPL-3.0).
For the complete license text, see the LICENSE file in the repository.