From patchwork Tue May 12 00:03:11 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 3767 Return-Path: Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 7307A60E17 for ; Tue, 12 May 2020 02:03:39 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="BscImK5E"; dkim-atps=neutral Received: from pendragon.bb.dnainternet.fi (81-175-216-236.bb.dnainternet.fi [81.175.216.236]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id AF85411F3; Tue, 12 May 2020 02:03:38 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1589241819; bh=iNMim9myxijZHhPjk+y9eE1edXo8CgJW7XlQwPZjajw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BscImK5EZRhhc4voM5SCwyJ4Pdd/cAUrTIItTu42sMO90BZihhnLH2VMv+G5dhnsm V6+d9gtNlrDAiEaxved30VxOJ/bz1ps9EdCMMRbx2/B8jNFZY7Z7HafMOJaVqf/vSU 60diJ7HIVFx1AoI/CNLXJjJdneszFFmxlnPc+akw= From: Laurent Pinchart To: libcamera-devel@lists.libcamera.org Date: Tue, 12 May 2020 03:03:11 +0300 Message-Id: <20200512000322.11753-14-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 Subject: [libcamera-devel] [PATCH 13/24] utils: raspberrypi: ctt: Fix pycodestyle W605 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 May 2020 00:03:40 -0000 W605 invalid escape sequence '\.' Signed-off-by: Laurent Pinchart --- utils/raspberrypi/ctt/ctt.py | 4 ++-- utils/raspberrypi/ctt/ctt_awb.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/utils/raspberrypi/ctt/ctt.py b/utils/raspberrypi/ctt/ctt.py index ff264176f040..4d8d6addf415 100755 --- a/utils/raspberrypi/ctt/ctt.py +++ b/utils/raspberrypi/ctt/ctt.py @@ -41,8 +41,8 @@ def get_col_lux(string): """ Extract colour and lux values from filename """ - col = re.search('([0-9]+)[kK](\.(jpg|jpeg|brcm|dng)|_.*\.(jpg|jpeg|brcm|dng))$', string) - lux = re.search('([0-9]+)[lL](\.(jpg|jpeg|brcm|dng)|_.*\.(jpg|jpeg|brcm|dng))$', string) + col = re.search('([0-9]+)[kK](\\.(jpg|jpeg|brcm|dng)|_.*\\.(jpg|jpeg|brcm|dng))$', string) + lux = re.search('([0-9]+)[lL](\\.(jpg|jpeg|brcm|dng)|_.*\\.(jpg|jpeg|brcm|dng))$', string) try: col = col.group(1) except AttributeError: diff --git a/utils/raspberrypi/ctt/ctt_awb.py b/utils/raspberrypi/ctt/ctt_awb.py index 58ef8432fb86..e97d833d0e49 100644 --- a/utils/raspberrypi/ctt/ctt_awb.py +++ b/utils/raspberrypi/ctt/ctt_awb.py @@ -256,8 +256,8 @@ def awb(Cam, cal_cr_list, cal_cb_list, plot): plt.scatter(rbs_hat[0], rbs_hat[1], color='red') for i, ct in enumerate(rbs_hat[2]): plt.annotate(str(ct), (rbs_hat[0][i], rbs_hat[1][i])) - plt.xlabel('$\hat{r}$') - plt.ylabel('$\hat{b}$') + plt.xlabel('$\\hat{r}$') + plt.ylabel('$\\hat{b}$') """ optional set axes equal to shortest distance so line really does looks perpendicular and everybody is happy