BGR、RBG

OpenCV为BGR

pytorch为RGB

(1)cv2.cvtColor(img, cv2.COLOR_BGR2RGB)

(2)img.transpose(2, 1, 0)

posted @ 2020-08-05 10:03  6+0  阅读(195)  评论(0编辑  收藏  举报