Advertisement
Guest User

fastNlMeansDenoising

a guest
Nov 24th, 2014
393
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.36 KB | None | 0 0
  1. import numpy as np
  2. import cv2
  3.  
  4.  
  5. windowname = 'img'
  6. cv2.namedWindow(windowname)
  7.  
  8. windowname2 = 'denoised'
  9. cv2.namedWindow(windowname2)
  10.  
  11.  
  12. img = cv2.imread('original.jpg')
  13.  
  14. dst = cv2.fastNlMeansDenoising(img,None,3,7,21)
  15.  
  16. while(1):
  17.     key = cv2.waitKey(5)
  18.     if key == 27:
  19.         break
  20.     cv2.imshow(windowname,img)
  21.     cv2.imshow(windowname2,dst)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement