{"id":3771,"url":"https://patchwork.libcamera.org/api/1.1/patches/3771/?format=json","web_url":"https://patchwork.libcamera.org/patch/3771/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20200512000322.11753-18-laurent.pinchart@ideasonboard.com>","date":"2020-05-12T00:03:15","name":"[libcamera-devel,17/24] utils: raspberrypi: ctt: Fix pycodestyle E116 and E117","commit_ref":null,"pull_url":null,"state":"accepted","archived":false,"hash":"e1d793007d013e133fb92d6ea9eda6ee861b4430","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/1.1/people/2/?format=json","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/3771/mbox/","series":[{"id":897,"url":"https://patchwork.libcamera.org/api/1.1/series/897/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=897","date":"2020-05-12T00:02:58","name":"utils: raspberrypi: ctt: Comply with pycodestyle","version":1,"mbox":"https://patchwork.libcamera.org/series/897/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/3771/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/3771/checks/","tags":{},"headers":{"Return-Path":"<laurent.pinchart@ideasonboard.com>","Received":["from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 8DDC160E0D\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 12 May 2020 02:03:44 +0200 (CEST)","from pendragon.bb.dnainternet.fi (81-175-216-236.bb.dnainternet.fi\n\t[81.175.216.236])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 4AFAF11F3;\n\tTue, 12 May 2020 02:03:43 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"j216xfzm\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1589241824;\n\tbh=9b1kxGqyxYCby1+ouLFTZ+KDUTJkCzHi1pQKQamBn10=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=j216xfzmcSYbha11ayvyajvLjM8GAuwn5uA3etE9QKjL/4UVUrS6QhHAxOnxsgJOE\n\teaqibOQa6q8dzBaYs55KiWeKAb8Ae1RkeHUeRaLq8uirFDvYABH+x/h93mdwfjH5KH\n\tebvLHK7HHS5S/zODJCQM4bFG9JQ7nbe+AOxefiS0=","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Tue, 12 May 2020 03:03:15 +0300","Message-Id":"<20200512000322.11753-18-laurent.pinchart@ideasonboard.com>","X-Mailer":"git-send-email 2.26.2","In-Reply-To":"<20200512000322.11753-1-laurent.pinchart@ideasonboard.com>","References":"<20200512000322.11753-1-laurent.pinchart@ideasonboard.com>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH 17/24] utils: raspberrypi: ctt: Fix\n\tpycodestyle E116 and E117","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>","X-List-Received-Date":"Tue, 12 May 2020 00:03:45 -0000"},"content":"E116 unexpected indentation (comment)\nE117 over-indented (comment)\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n utils/raspberrypi/ctt/ctt_macbeth_locator.py | 26 ++++++++++----------\n utils/raspberrypi/ctt/ctt_tools.py           |  8 +++---\n 2 files changed, 17 insertions(+), 17 deletions(-)","diff":"diff --git a/utils/raspberrypi/ctt/ctt_macbeth_locator.py b/utils/raspberrypi/ctt/ctt_macbeth_locator.py\nindex 05d1bd437001..4e666b0f1089 100644\n--- a/utils/raspberrypi/ctt/ctt_macbeth_locator.py\n+++ b/utils/raspberrypi/ctt/ctt_macbeth_locator.py\n@@ -450,14 +450,14 @@ def get_macbeth_chart(img, ref_data):\n                 \"\"\"\n                 in_border = True\n                 # for p in mac_guess[0]:\n-                    # pptest = cv2.pointPolygonTest(\n-                        # img_con,\n-                        # tuple(p),\n-                        # False\n-                    # )\n-                    # if pptest == -1:\n-                        # in_border = False\n-                        # break\n+                #     pptest = cv2.pointPolygonTest(\n+                #         img_con,\n+                #         tuple(p),\n+                #         False\n+                #     )\n+                #     if pptest == -1:\n+                #         in_border = False\n+                #         break\n \n                 if in_border:\n                     mac_mid = np.mean(mac_guess,\n@@ -499,9 +499,9 @@ def get_macbeth_chart(img, ref_data):\n         else:\n             clustering.fit(mac_mids_list)\n             # try:\n-                # clustering.fit(mac_mids_list)\n+            #     clustering.fit(mac_mids_list)\n             # except RuntimeWarning as error:\n-                # return(0, None, None, error)\n+            #     return(0, None, None, error)\n \n             \"\"\"\n             create list of all clusters\n@@ -549,9 +549,9 @@ def get_macbeth_chart(img, ref_data):\n         # copy = cv2.cvtColor(copy, cv2.COLOR_GRAY2RGB)\n         # copy = cv2.resize(copy, None, fx=2, fy=2)\n         # for clus in clus_list:\n-            # centroid = tuple(2*np.round(clus[2]).astype(np.int32))\n-            # cv2.circle(copy, centroid, 7, (255, 0, 0), -1)\n-            # cv2.circle(copy, centroid, 2, (0, 0, 255), -1)\n+        #     centroid = tuple(2*np.round(clus[2]).astype(np.int32))\n+        #     cv2.circle(copy, centroid, 7, (255, 0, 0), -1)\n+        #     cv2.circle(copy, centroid, 2, (0, 0, 255), -1)\n         # represent(copy)\n \n         \"\"\"\ndiff --git a/utils/raspberrypi/ctt/ctt_tools.py b/utils/raspberrypi/ctt/ctt_tools.py\nindex 27080de08cec..f4b9baac5521 100644\n--- a/utils/raspberrypi/ctt/ctt_tools.py\n+++ b/utils/raspberrypi/ctt/ctt_tools.py\n@@ -99,11 +99,11 @@ display image for debugging... read at your own risk...\n \"\"\"\n def represent(img, name='image'):\n     # if type(img) == tuple or type(img) == list:\n-        # for i in range(len(img)):\n-            # name = 'image {}'.format(i)\n-            # cv2.imshow(name, img[i])\n+    #     for i in range(len(img)):\n+    #         name = 'image {}'.format(i)\n+    #         cv2.imshow(name, img[i])\n     # else:\n-        # cv2.imshow(name, img)\n+    #     cv2.imshow(name, img)\n     # cv2.waitKey(0)\n     # cv2.destroyAllWindows()\n     # return 0\n","prefixes":["libcamera-devel","17/24"]}