summaryrefslogtreecommitdiff
path: root/include/linux/v4l2-mediabus.h
diff options
context:
space:
mode:
authorKieran Bingham <kieran.bingham@ideasonboard.com>2020-01-07 15:18:23 +0000
committerKieran Bingham <kieran.bingham@ideasonboard.com>2020-01-07 16:05:27 +0000
commit32dd1a3b2f813fa39121d3c9781379d1d3208611 (patch)
tree47cb4651a90b7ad95bb309bcd9c8a5620a9e8b50 /include/linux/v4l2-mediabus.h
parent618b5512a8113bcc785ff57afaf7c77e6c489f3b (diff)
utils: checkstyle.py: Fix regex string literal
The checkstyle.py patch has a fault which it identified in itself when updating the regex string. --- utils/checkstyle.py +++ utils/checkstyle.py #105: : W605 invalid escape sequence '\+' + diff_header_regex = re.compile('@@ -([0-9]+)(,[0-9]+)? \+([0-9]+)(,?[0-9]+)? @@') --- 1 potential style issue detected, please review This is documented further at: https://www.flake8rules.com/rules/W605.html Update the string literal prefix to declare a raw byte string for the regex parser. Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'include/linux/v4l2-mediabus.h')
0 files changed, 0 insertions, 0 deletions
side*6 + 5*s_bord + 2*b_bord_x y_max = side*4 + 3*s_bord + 2*b_bord_y c1 = (0, 0) c2 = (0, y_max) c3 = (x_max, y_max) c4 = (x_max, 0) mac_norm = np.array((c1, c2, c3, c4), np.float32) mac_norm = np.array([mac_norm]) square_verts = [] square_0 = np.array(((0, 0), (0, side), (side, side), (side, 0)), np.float32) offset_0 = np.array((b_bord_x, b_bord_y), np.float32) c_off = side * c_err offset_cont = np.array(((c_off, c_off), (c_off, -c_off), (-c_off, -c_off), (-c_off, c_off)), np.float32) square_0 += offset_0 square_0 += offset_cont """ define macbeth square corners """ for i in range(6): shift_i = np.array(((i*side, 0), (i*side, 0), (i*side, 0), (i*side, 0)), np.float32) shift_bord = np.array(((i*s_bord, 0), (i*s_bord, 0), (i*s_bord, 0), (i*s_bord, 0)), np.float32) square_i = square_0 + shift_i + shift_bord for j in range(4): shift_j = np.array(((0, j*side), (0, j*side), (0, j*side), (0, j*side)), np.float32) shift_bord = np.array(((0, j*s_bord), (0, j*s_bord), (0, j*s_bord), (0, j*s_bord)), np.float32) square_j = square_i + shift_j + shift_bord square_verts.append(square_j) # print('square_verts') # print(square_verts) return np.array(square_verts, np.float32), mac_norm def get_square_centres(c_err=0.05, scale=scale): """ define macbeth square centres """ verts, mac_norm = get_square_verts(c_err, scale=scale) centres = np.mean(verts, axis=1) # print('centres') # print(centres) return np.array(centres, np.float32)