import numpy as np
from cv2 import *
# 读取中文路径也不会报错
def myImread(path):
img = imdecode(np.fromfile(path, dtype=np.uint8), -1)
## 经验证,不需要再转bgr,myImread的读图结果已经是和imread一样的
return img
import numpy as np
from cv2 import *
# 读取中文路径也不会报错
def myImread(path):
img = imdecode(np.fromfile(path, dtype=np.uint8), -1)
## 经验证,不需要再转bgr,myImread的读图结果已经是和imread一样的
return img