[v4,0/4] softisp tuning script for LSC
mbox series

Message ID 20261202151305.132644-1-mzamazal@redhat.com
Headers show
Series
  • softisp tuning script for LSC
Related show

Message

Milan Zamazal Dec. 2, 2026, 3:13 p.m. UTC
This adds softisp tuning script.  The script is based on rkisp1 tuning
script but there are some differences (a different set of algorithms,
LSC: gr+gb x g-only, output range).  It’s probably not worth to make a
common base class for rkisp1 and softisp; I selected the copy & edit
approach.

Additionally, support for variable, rather than fixed 17x17, LSC table size is added.

Changes in v4:
- Support for variable LSC table size.

Changes in v3:
- Wrong output algorithm order fixed.

Changes in v2:
- Wrong pixel value mapping fixed.
- Data for all the softisp algorithms rather than only LSC, added by Hans.

Milan Zamazal (4):
  utils: tuning: Add softisp script
  libcamera: software_isp: Use specified LSC grid size in debayering
  ipa: softisp: Support any LSC table sizes
  utils: tuning: Support variable softisp LSC size

 .../internal/software_isp/debayer_params.h    |  21 +---
 .../internal/software_isp/software_isp.h      |   2 +-
 include/libcamera/ipa/softisp.mojom           |   3 +-
 src/ipa/softisp/algorithms/lsc.cpp            |  53 +++++++--
 src/ipa/softisp/algorithms/lsc.h              |   6 +-
 src/ipa/softisp/ipa_context.h                 |   1 +
 src/ipa/softisp/softisp.cpp                   |  10 +-
 src/libcamera/software_isp/debayer.cpp        |  16 +--
 src/libcamera/software_isp/debayer.h          |   2 +-
 src/libcamera/software_isp/debayer_cpu.cpp    |   2 +-
 src/libcamera/software_isp/debayer_cpu.h      |   2 +-
 src/libcamera/software_isp/debayer_egl.cpp    |  18 +--
 src/libcamera/software_isp/debayer_egl.h      |   4 +-
 src/libcamera/software_isp/software_isp.cpp   |  12 +-
 utils/tuning/config-example.yaml              |   5 +-
 .../tuning/libtuning/modules/lsc/__init__.py  |   1 +
 utils/tuning/libtuning/modules/lsc/softisp.py | 109 ++++++++++++++++++
 utils/tuning/softisp.py                       |  53 +++++++++
 18 files changed, 255 insertions(+), 65 deletions(-)
 create mode 100644 utils/tuning/libtuning/modules/lsc/softisp.py
 create mode 100755 utils/tuning/softisp.py