From 60d60c13672b81f2a57894467a569c6ba98ae895 Mon Sep 17 00:00:00 2001 From: Stefan Klug Date: Thu, 23 Jan 2025 12:40:58 +0100 Subject: libtuning: module: awb: Add bayes AWB support To support the bayesian AWB algorithm in libtuning, the necessary data needs to be collected and written to the tuning file. Extend libtuning to calculate and output that additional data. Prior probabilities and AwbModes are manually specified and not calculated in the tuning process. Add sample values from the RaspberryPi tuning files to the example config file. Signed-off-by: Stefan Klug Reviewed-by: Paul Elder Reviewed-by: Kieran Bingham --- utils/tuning/config-example.yaml | 44 +++++++++++++++++++++++++++++++++++++++- 1 file changed, 43 insertions(+), 1 deletion(-) (limited to 'utils/tuning/config-example.yaml') diff --git a/utils/tuning/config-example.yaml b/utils/tuning/config-example.yaml index 1b7f52cd..1bbb2757 100644 --- a/utils/tuning/config-example.yaml +++ b/utils/tuning/config-example.yaml @@ -5,7 +5,49 @@ general: do_alsc_colour: 1 luminance_strength: 0.5 awb: - greyworld: 0 + # Algorithm can either be 'grey' or 'bayes' + algorithm: bayes + # Priors is only used for the bayes algorithm. They are defined in + # logarithmic space. A good staring point is: + # - lux: 0 + # ct: [ 2000, 3000, 13000 ] + # probability: [ 1.0, 0.0, 0.0 ] + # - lux: 800 + # ct: [ 2000, 6000, 13000 ] + # probability: [ 0.0, 2.0, 2.0 ] + # - lux: 1500 + # ct: [ 2000, 4000, 6000, 6500, 7000, 13000 ] + # probability: [ 0.0, 1.0, 6.0, 7.0, 1.0, 1.0 ] + priors: + - lux: 0 + ct: [ 2000, 13000 ] + probability: [ 0.0, 0.0 ] + AwbMode: + AwbAuto: + lo: 2500 + hi: 8000 + AwbIncandescent: + lo: 2500 + hi: 3000 + AwbTungsten: + lo: 3000 + hi: 3500 + AwbFluorescent: + lo: 4000 + hi: 4700 + AwbIndoor: + lo: 3000 + hi: 5000 + AwbDaylight: + lo: 5500 + hi: 6500 + AwbCloudy: + lo: 6500 + hi: 8000 + # One custom mode can be defined if needed + #AwbCustom: + # lo: 2000 + # hi: 1300 macbeth: small: 1 show: 0 -- cgit v1.2.1