Show a patch.

GET /api/1.1/patches/17877/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 17877,
    "url": "https://patchwork.libcamera.org/api/1.1/patches/17877/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/17877/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/1.1/projects/1/?format=api",
        "name": "libcamera",
        "link_name": "libcamera",
        "list_id": "libcamera_core",
        "list_email": "libcamera-devel@lists.libcamera.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": ""
    },
    "msgid": "<20221124113550.2182342-12-paul.elder@ideasonboard.com>",
    "date": "2022-11-24T11:35:49",
    "name": "[libcamera-devel,v4,11/12] utils: tuning: Add alsc-only libtuning raspberrypi tuning script",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "8b1d7b2e18e5167ade463f213aa67b51dda7e254",
    "submitter": {
        "id": 17,
        "url": "https://patchwork.libcamera.org/api/1.1/people/17/?format=api",
        "name": "Paul Elder",
        "email": "paul.elder@ideasonboard.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/17877/mbox/",
    "series": [
        {
            "id": 3636,
            "url": "https://patchwork.libcamera.org/api/1.1/series/3636/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=3636",
            "date": "2022-11-24T11:35:38",
            "name": "utils: tuning: Add a new tuning infrastructure",
            "version": 4,
            "mbox": "https://patchwork.libcamera.org/series/3636/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/17877/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/17877/checks/",
    "tags": {},
    "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 554F6BDE6B\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 24 Nov 2022 11:36:24 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 21C2F63322;\n\tThu, 24 Nov 2022 12:36:24 +0100 (CET)",
            "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 595886331A\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 24 Nov 2022 12:36:22 +0100 (CET)",
            "from pyrite.tail37cf.ts.net (h175-177-042-159.catv02.itscom.jp\n\t[175.177.42.159])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id D2B0D7FA;\n\tThu, 24 Nov 2022 12:36:20 +0100 (CET)"
        ],
        "DKIM-Signature": [
            "v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1669289784;\n\tbh=Fgf46HEmOv2at5EcVS9YyASZedI8PKg6nfBtederpYg=;\n\th=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=oPCmKmcPtwXGAg035VokkKruTzfvtpzRErRNsQ7w6uwTxoRyYj+EyfKXQpOYLEQRW\n\tMMLgOGBEhiDyT29RfkqFnMULSYmiggSPDgYvkA6Ve4mE4gQ4B6D3j/NsXnV1qlQ8Bu\n\tfiGU1lD3jBAGTiqTX7EzTbw7r6zFUwgJhPswMjzR/EBCz5bVHuOKLvYD012LM3yhfC\n\tU2ufYjB50ruNlv/Fx46Kv2qocP06179lEHBXedDTrr/VO3g20JSRHQgyJmFNQN3tax\n\t9sU5JIO3xbWoDEVR32hKGpX1L48DWbghCGkzZLBnPclv0UhJfTvhZN7udvOXwBfTdT\n\tUDudkkO6lv54Q==",
            "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1669289782;\n\tbh=Fgf46HEmOv2at5EcVS9YyASZedI8PKg6nfBtederpYg=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=VnF5HJQ1WnfPL3aTT08hOQAHBsTV32H7mAJtwmOe+oCLJtW9yKCUX+vBboV8On3ks\n\t4KHYPK4BycRBc0lkcvSQaL0xW4becrcSPhOexZsIPe12nPzm78b4TPTvOOyEwRPgHt\n\te2ekuC7/vh3bppzlXeSF+LACgU0rmn9zyr7pcFGc="
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"VnF5HJQ1\"; dkim-atps=neutral",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Thu, 24 Nov 2022 20:35:49 +0900",
        "Message-Id": "<20221124113550.2182342-12-paul.elder@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.35.1",
        "In-Reply-To": "<20221124113550.2182342-1-paul.elder@ideasonboard.com>",
        "References": "<20221124113550.2182342-1-paul.elder@ideasonboard.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [PATCH v4 11/12] utils: tuning: Add alsc-only\n\tlibtuning raspberrypi tuning script",
        "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": "Paul Elder via libcamera-devel <libcamera-devel@lists.libcamera.org>",
        "Reply-To": "Paul Elder <paul.elder@ideasonboard.com>",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "Add a tuning script for raspberrypi for alsc only, that uses libtuning.\nSince there will also be a tuning script for raspberrypi that has more\nmodules, put the libtuning alsc module definition in a separate file so\nthat it can be reused later.\n\nSigned-off-by: Paul Elder <paul.elder@ideasonboard.com>\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\n---\nChanges in v3:\n- add __main__ guard\n- add file description\n- fix style\n\nChanges in v2:\n- fix python errors\n- fix style\n- add SPDX and copyright\n- s/average_functions/average/\n- update script to work with new raspberrypi alsc module\n---\n utils/tuning/raspberrypi/__init__.py  |  0\n utils/tuning/raspberrypi/alsc.py      | 19 +++++++++++++++++++\n utils/tuning/raspberrypi_alsc_only.py | 23 +++++++++++++++++++++++\n 3 files changed, 42 insertions(+)\n create mode 100644 utils/tuning/raspberrypi/__init__.py\n create mode 100644 utils/tuning/raspberrypi/alsc.py\n create mode 100755 utils/tuning/raspberrypi_alsc_only.py",
    "diff": "diff --git a/utils/tuning/raspberrypi/__init__.py b/utils/tuning/raspberrypi/__init__.py\nnew file mode 100644\nindex 00000000..e69de29b\ndiff --git a/utils/tuning/raspberrypi/alsc.py b/utils/tuning/raspberrypi/alsc.py\nnew file mode 100644\nindex 00000000..024eb5a3\n--- /dev/null\n+++ b/utils/tuning/raspberrypi/alsc.py\n@@ -0,0 +1,19 @@\n+# SPDX-License-Identifier: GPL-2.0-or-later\n+#\n+# Copyright (C) 2022, Paul Elder <paul.elder@ideasonboard.com>\n+#\n+# alsc.py - ALSC module instance for Raspberry Pi tuning scripts\n+\n+import libtuning as lt\n+from libtuning.modules.lsc import ALSCRaspberryPi\n+\n+ALSC = \\\n+    ALSCRaspberryPi(do_color=lt.Param('do_alsc_colour', lt.Param.Mode.Optional, True),\n+                    luminance_strength=lt.Param('luminance_strength', lt.Param.Mode.Optional, 0.5),\n+                    debug=[lt.Debug.Plot],\n+                    sector_shape=(16, 12),\n+                    sector_x_gradient=lt.gradient.Linear(lt.Remainder.DistributeFront),\n+                    sector_y_gradient=lt.gradient.Linear(lt.Remainder.DistributeFront),\n+                    sector_average_function=lt.average.Mean(),\n+                    smoothing_function=lt.smoothing.MedianBlur(3),\n+                    )\ndiff --git a/utils/tuning/raspberrypi_alsc_only.py b/utils/tuning/raspberrypi_alsc_only.py\nnew file mode 100755\nindex 00000000..af04e6a8\n--- /dev/null\n+++ b/utils/tuning/raspberrypi_alsc_only.py\n@@ -0,0 +1,23 @@\n+#!/usr/bin/env python3\n+# SPDX-License-Identifier: GPL-2.0-or-later\n+#\n+# Copyright (C) 2022, Paul Elder <paul.elder@ideasonboard.com>\n+#\n+# raspberrypi_alsc_only.py - Tuning script for raspberrypi, ALSC only\n+\n+import sys\n+\n+import libtuning as lt\n+from libtuning.parsers import RaspberryPiParser\n+from libtuning.generators import RaspberryPiOutput\n+\n+from raspberrypi.alsc import ALSC\n+\n+tuner = lt.Tuner('Raspberry Pi (ALSC only)')\n+tuner.add(ALSC)\n+tuner.set_input_parser(RaspberryPiParser())\n+tuner.set_output_formatter(RaspberryPiOutput())\n+tuner.set_output_order([ALSC])\n+\n+if __name__ == '__main__':\n+    sys.exit(tuner.run(sys.argv))\n",
    "prefixes": [
        "libcamera-devel",
        "v4",
        "11/12"
    ]
}