Cannot load image on Windows machine if there are non-ASCII characters in file path
Opened this issue · 0 comments
JeffreyScheck commented
If there is a non-ASCII character in the file path then the library has issues loading images from file properly.
Potential fix is to change line 766 in machinevisiontoolbox/base/imageio.py from
image = cv.imread(path.as_posix(), -1)
to
image = cv.imdecode(np.fromfile(path.as_posix(), dtype=np.uint8),cv.IMREAD_UNCHANGED)
I don't know if this causes other issues, but it did resolve the primary problem on a Windows machine.