Created
February 24, 2017 15:39
-
-
Save rfmerrill/f4aa204f7ad1e6f5099d7a1910e2c5c9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import numpy as np | |
import os | |
import cv2 | |
kernel = np.ones((6,6), np.float32)/36.0 | |
while True: | |
#img = noisy(sys.argv[1], seed) | |
img = np.random.normal(192, 5, (400,400,1)) | |
cv2.imshow("Noise", np.uint8(img)) | |
img_filtered = cv2.filter2D(img, -1, kernel) | |
cv2.imshow("Filtered noise", np.uint8(img_filtered)) | |
cv2.waitKey(1) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment