[v4,00/23] Add ccm calibration to libtuning
mbox series

Message ID 20240705144209.418906-1-stefan.klug@ideasonboard.com
Headers show
Series
  • Add ccm calibration to libtuning
Related show

Message

Stefan Klug July 5, 2024, 2:41 p.m. UTC
Hi all,

this patch series improves the rkisp1 tuning tool support. With that
code, it is possible to create a nice looking image on the imx8mp. It
incorporates some logic from the raspberrypi tuning tools. This was used
to get to a working state in a timely manner. After that further
refactoring and algorithm development can take place.

Feature wise it contains:
- Added ccm calibration for the rkisp1
- Add static support for awb, filter, gamma and cproc
- Fixed lsc correction tables
- Some general fixes to make all that work

Best regards,
Stefan

Changes in v3:
- Replaced BLC module by a simple static module as the black level is now 
  provided by the camera sensor helpers (seperate series).
- Dropped P23 ([PATCH v2 23/25] libtuning: Make blacklevel optional).
- Collected tags.
- Fixed typos and comments from first review.
- P12 is now split in two.

Changes in v4:
- Fixed error handling when ccm could not be calibrated (P16)
- Collected tags
- Improved commit messages (especially in 
  [PATCH v4 20/23] tuning: rkisp1: Add some static modules)
- Fixed a few typos


Paul Elder (1):
  libtuning: modules: Add initial CCM module

Stefan Klug (22):
  libtuning: Backport improvements in MacBeth search reliability
  libtuning: Fix reference image
  libtuning: Copy files from raspberrypi
  libtuning: Copy visualize_macbeth_chart from raspberry pi
  utils: tuning: Add requirements file and update readme
  libtuning: Fix imports
  libtuning: Migrate prints to python logging framework
  libtuning: Fix visualize_macbeth_chart()
  libtuning: Improve filename parsing
  libtuning: Implement a minimal yaml parser
  libtuning: Reactivate macbeth locator
  libtuning: Be a bit more verbose
  libtuning: lsc: rkisp1: Clip lsc values to valid range
  libtuning: Use the color member of the Image class
  libtuning: Remove need for Cam object from ccm
  libtuning: Handle cases, where no lsc tuning images are present
  libtuning: Only warn if processing returns None
  libtuning: Add static module
  tuning: rkisp1: Add some static modules
  libtuning: lsc: rkisp1: Do not calculate ratios to green
  libtuning: lsc: Prevent negative values
  libtuning: agc: rkisp1: Increase y-target

 utils/tuning/README.rst                       |  23 +-
 utils/tuning/config-example.yaml              |  12 +
 utils/tuning/libtuning/ctt_awb.py             | 378 ++++++++++++++++
 utils/tuning/libtuning/ctt_ccm.py             | 408 ++++++++++++++++++
 utils/tuning/libtuning/ctt_colors.py          |  30 ++
 utils/tuning/libtuning/ctt_ransac.py          |  71 +++
 .../libtuning/generators/yaml_output.py       |   8 +-
 utils/tuning/libtuning/image.py               |   8 +-
 utils/tuning/libtuning/libtuning.py           |  23 +-
 utils/tuning/libtuning/macbeth.py             |  65 ++-
 utils/tuning/libtuning/macbeth_ref.pgm        |   2 +-
 utils/tuning/libtuning/modules/agc/rkisp1.py  |   2 +-
 .../tuning/libtuning/modules/ccm/__init__.py  |   6 +
 utils/tuning/libtuning/modules/ccm/ccm.py     |  41 ++
 utils/tuning/libtuning/modules/ccm/rkisp1.py  |  28 ++
 utils/tuning/libtuning/modules/lsc/lsc.py     |   5 +-
 .../libtuning/modules/lsc/raspberrypi.py      |  12 +-
 utils/tuning/libtuning/modules/lsc/rkisp1.py  |  20 +-
 utils/tuning/libtuning/modules/static.py      |  24 ++
 utils/tuning/libtuning/parsers/yaml_parser.py |   9 +-
 utils/tuning/libtuning/utils.py               |  95 +++-
 utils/tuning/requirements.txt                 |   6 +
 utils/tuning/rkisp1.py                        |  24 +-
 23 files changed, 1217 insertions(+), 83 deletions(-)
 create mode 100644 utils/tuning/config-example.yaml
 create mode 100644 utils/tuning/libtuning/ctt_awb.py
 create mode 100644 utils/tuning/libtuning/ctt_ccm.py
 create mode 100644 utils/tuning/libtuning/ctt_colors.py
 create mode 100644 utils/tuning/libtuning/ctt_ransac.py
 create mode 100644 utils/tuning/libtuning/modules/ccm/__init__.py
 create mode 100644 utils/tuning/libtuning/modules/ccm/ccm.py
 create mode 100644 utils/tuning/libtuning/modules/ccm/rkisp1.py
 create mode 100644 utils/tuning/libtuning/modules/static.py
 create mode 100644 utils/tuning/requirements.txt