def bilateralFilter(srcpath, dstpath):
img = cv2.imread(srcpath, 0)
# 9---??????
# ??????????????????????????
blur = cv2.bilateralFilter(img,9,75,75)
# cv2.imwrite(dstpath, blur)
plt.subplot(1,2,1),plt.imshow(img,'gray')
plt.subplot(1,2,2),plt.imshow(blur,'gray')
plt.show()
评论列表
文章目录