def enhance(img): kernel = np.array([[-1,0,1],[-2,0,2],[1,0,1]]) return cv2.filter2D(img, -1, kernel)