We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 05a7cc9 commit 464747cCopy full SHA for 464747c
src/PIL/ImageOps.py
@@ -675,7 +675,7 @@ def sobel(image: Image.Image) -> Image.Image:
675
for dy in (-1, 0, 1):
676
for dx in (-1, 0, 1):
677
v = image.getpixel((x + dx, y + dy))
678
- assert isinstance(v, float)
+ assert isinstance(v, (int, float))
679
680
gx += v * Kx[dy + 1][dx + 1]
681
gy += v * Ky[dy + 1][dx + 1]
0 commit comments