[{"id":26370,"web_url":"https://patchwork.libcamera.org/comment/26370/","msgid":"<167508490706.42371.14534704715229173750@Monstersaurus>","date":"2023-01-30T13:21:47","subject":"Re: [libcamera-devel] [PATCH v3 3/5] ipa: raspberrypi: awb: Delay\n\trelease of the statistics buffer","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Quoting Naushir Patuck via libcamera-devel (2022-12-13 11:48:34)\n> Release the statistics buffer after running the through the AWB calculations.\n> Only the \"counted\" statistics are copied out to a local structure, so keeping\n> the statistics buffer allows the algorithm to see the \"uncounted\" statistics as\n> well.\n> \n> This is currently handled by hard-coding the total number of statistics regions\n> regions based on the structure definition in the bcm2835_isp_stats structure.\n> \n> Signed-off-by: Naushir Patuck <naush@raspberrypi.com>\n> Reviewed-by: David Plowman <david.plowman@raspberrypi.com>\n\nReviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n\n> ---\n>  src/ipa/raspberrypi/controller/rpi/awb.cpp | 10 +++++-----\n>  1 file changed, 5 insertions(+), 5 deletions(-)\n> \n> diff --git a/src/ipa/raspberrypi/controller/rpi/awb.cpp b/src/ipa/raspberrypi/controller/rpi/awb.cpp\n> index 4f6af4ba98dc..04d1c8783654 100644\n> --- a/src/ipa/raspberrypi/controller/rpi/awb.cpp\n> +++ b/src/ipa/raspberrypi/controller/rpi/awb.cpp\n> @@ -427,11 +427,6 @@ void Awb::prepareStats()\n>          */\n>         generateStats(zones_, statistics_->awb_stats, config_.minPixels,\n>                       config_.minG);\n> -       /*\n> -        * we're done with these; we may as well relinquish our hold on the\n> -        * pointer.\n> -        */\n> -       statistics_.reset();\n>         /*\n>          * apply sensitivities, so values appear to come from our \"canonical\"\n>          * sensor.\n> @@ -728,6 +723,11 @@ void Awb::doAwb()\n>                         << \" with gains r \" << asyncResults_.gainR\n>                         << \" and b \" << asyncResults_.gainB;\n>         }\n> +       /*\n> +        * we're done with these; we may as well relinquish our hold on the\n> +        * pointer.\n> +        */\n> +       statistics_.reset();\n>  }\n>  \n>  /* Register algorithm with the system. */\n> -- \n> 2.25.1\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id A9EC6BDC71\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 30 Jan 2023 13:21:51 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 45077625E4;\n\tMon, 30 Jan 2023 14:21:51 +0100 (CET)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 3E6BD60482\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 30 Jan 2023 14:21:50 +0100 (CET)","from pendragon.ideasonboard.com\n\t(cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id D89878B8;\n\tMon, 30 Jan 2023 14:21:49 +0100 (CET)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1675084911;\n\tbh=bcrin4MQL/q/f35smU1nN2eZ6csosFjcNszQ+eec+eM=;\n\th=In-Reply-To:References:To:Date:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=VS6R+LoHP0r5rv79Y+DC6MNlQl40Hj6GGGPl1wfhgA33K+/zkZdojmVSbvBcX6BSi\n\tjtRmdKR2Fs1jFLapezK/ql/U2ha+WOaAZBo4Q3aR5jZVt+jMHz0Qr7PuGIQmLdSA5K\n\tnl8dWeSHsp5hy3GQOkExXPrAGWBgxjrka02+wJx73PJmFXuS1n2BhPahtQdAp6rhQj\n\t1fHbz3eqQ2REcVKrFkR2EWSiQ2f42cbcImhSV3FySm5/8TDhxScmWt8eqEgfyMQrDQ\n\tj3fsyN5gXDVDpzjeVQX3pSdTekTTCpe4AzOWpcxQO5u0rK3exI6BW2wT3fnWAxfSKd\n\t6bjNVbJntOdog==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1675084910;\n\tbh=bcrin4MQL/q/f35smU1nN2eZ6csosFjcNszQ+eec+eM=;\n\th=In-Reply-To:References:Subject:From:To:Date:From;\n\tb=D+tkzuklt8yVp8Ly0DD3jPyF7zd6jJs+JLY6c5LmxGHVoornb294f3XgZlaH6S4Dj\n\tD1FnEJbwiSia36bYzKV7n2dBYWAZZuGNnvkDfjOpaQ49AxC0+1HUlGe7LtaMED+NDk\n\t01qZvPTYaNTOwq+FQIGxMqQocKIB/pVWBfjgBD20="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"D+tkzukl\"; dkim-atps=neutral","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20221213114836.15473-4-naush@raspberrypi.com>","References":"<20221213114836.15473-1-naush@raspberrypi.com>\n\t<20221213114836.15473-4-naush@raspberrypi.com>","To":"Naushir Patuck <naush@raspberrypi.com>,\n\tlibcamera-devel@lists.libcamera.org","Date":"Mon, 30 Jan 2023 13:21:47 +0000","Message-ID":"<167508490706.42371.14534704715229173750@Monstersaurus>","User-Agent":"alot/0.10","Subject":"Re: [libcamera-devel] [PATCH v3 3/5] ipa: raspberrypi: awb: Delay\n\trelease of the statistics buffer","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","From":"Kieran Bingham via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]