콘텐츠로 이동
Search

OpenCV:UMat

GPU 가속

Example

import cv2

img = cv2.UMat(cv2.imread("image.jpg", cv2.IMREAD_COLOR))
imgUMat = cv2.UMat(img)
gray = cv2.cvtColor(imgUMat, cv2.COLOR_BGR2GRAY)
gray = cv2.GaussianBlur(gray, (7, 7), 1.5)
gray = cv2.Canny(gray, 0, 50)

cv2.imshow("edges", gray)
cv2.waitKey();

See also

Favorite site

lastmod 2023-10-20created 2023-10-20author Zer0 sitemap