Skip to content

Commit

Permalink
Merge pull request #31 from tekktrik/dev/fix-pylint-errors
Browse files Browse the repository at this point in the history
Fix pylint errors
  • Loading branch information
evaherrada committed Nov 14, 2022
2 parents b3bd6b9 + 6a88e73 commit bee668f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions examples/mlx90640_camtest.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,13 +85,13 @@ def gaussian(x, a, b, c, d=0):
def gradient(x, width, cmap, spread=1):
width = float(width)
r = sum(
[gaussian(x, p[1][0], p[0] * width, width / (spread * len(cmap))) for p in cmap]
gaussian(x, p[1][0], p[0] * width, width / (spread * len(cmap))) for p in cmap
)
g = sum(
[gaussian(x, p[1][1], p[0] * width, width / (spread * len(cmap))) for p in cmap]
gaussian(x, p[1][1], p[0] * width, width / (spread * len(cmap))) for p in cmap
)
b = sum(
[gaussian(x, p[1][2], p[0] * width, width / (spread * len(cmap))) for p in cmap]
gaussian(x, p[1][2], p[0] * width, width / (spread * len(cmap))) for p in cmap
)
r = int(constrain(r * 255, 0, 255))
g = int(constrain(g * 255, 0, 255))
Expand Down
6 changes: 3 additions & 3 deletions examples/mlx90640_pil.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ def gaussian(x, a, b, c, d=0):
def gradient(x, width, cmap, spread=1):
width = float(width)
r = sum(
[gaussian(x, p[1][0], p[0] * width, width / (spread * len(cmap))) for p in cmap]
gaussian(x, p[1][0], p[0] * width, width / (spread * len(cmap))) for p in cmap
)
g = sum(
[gaussian(x, p[1][1], p[0] * width, width / (spread * len(cmap))) for p in cmap]
gaussian(x, p[1][1], p[0] * width, width / (spread * len(cmap))) for p in cmap
)
b = sum(
[gaussian(x, p[1][2], p[0] * width, width / (spread * len(cmap))) for p in cmap]
gaussian(x, p[1][2], p[0] * width, width / (spread * len(cmap))) for p in cmap
)
r = int(constrain(r * 255, 0, 255))
g = int(constrain(g * 255, 0, 255))
Expand Down

0 comments on commit bee668f

Please sign in to comment.