Python3 加载图片并保存图片
import cv2
img = cv2.imread('1.png')
# img为数组格式,若存在其他格式,可以考虑使用.numpy()将其转化为数组
cv2.imwrite('test.jpg',img)
Python3 加载图片并保存图片
import cv2
img = cv2.imread('1.png')
# img为数组格式,若存在其他格式,可以考虑使用.numpy()将其转化为数组
cv2.imwrite('test.jpg',img)