python读取rgb图片
PIL
from PIL import Image
img= Image.open(img_path).convert('RGB')
opencv
import cv2
# Load the image as a numpy array
img = cv2.imread("<PATH_TO_YOUR_IMAGE>")
# Convert OpenCV bgr to rgb
img = cv2.cvtColor(img, cv2.COLOR_BGR2RGB)
# Convert OpenCV bgr to hsv
image_hsv = cv2.cvtColor(img, cv2.COLOR_BGR2HSV)