1 img = cv2.imread("4.jpg") #是BGR格式,数据范围在 0~255,通道格式为(H,W,C) 2 height, width, channel = img.shape 3 img = cv2.resize(img,(width, height))