cleanups
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 7.7 KiB |
BIN
examples/_DSC1022 (1)-edge-detection.png
Normal file
BIN
examples/_DSC1022 (1)-edge-detection.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 9.7 MiB |
@@ -3,7 +3,13 @@
|
||||
import cv2 as cv
|
||||
import numpy as np
|
||||
|
||||
file = '01-0001-cropped.png'
|
||||
# edge-detection kernel amplification
|
||||
AMPLIFIER=9
|
||||
|
||||
MIN_INTENSITY=100
|
||||
|
||||
# file = '01-0001-cropped.png'
|
||||
file = 'streaktest.png'
|
||||
file_name = file.split(".")[0]
|
||||
file_ext = file.split(".")[1]
|
||||
|
||||
@@ -13,7 +19,7 @@ img = cv.cvtColor(img, cv.COLOR_BGR2GRAY)
|
||||
|
||||
kernel = np.array([
|
||||
[-1, -1, -1],
|
||||
[-1, 8, -1],
|
||||
[-1, AMPLIFIER, -1],
|
||||
[-1, -1, -1],
|
||||
])
|
||||
img = cv.filter2D(src=img, ddepth=-1, kernel=kernel)
|
||||
|
||||
BIN
examples/streaktest-edge-detection.png
Normal file
BIN
examples/streaktest-edge-detection.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 31 KiB |
Reference in New Issue
Block a user