Пишу на Windows 7
Вот код:
from PIL import Image
from pytesseract import image_to_string
def tel_recon( ):
img = Image.open('D:\\PROJECT\\pars_2\\tel.png')
tel = image_to_string(img)
print(tel)
tel_recon( )
Ошибка:
Traceback (most recent call last):
File "D:/PROJECT/pars_2/1.py", line 50, in <module>
main()
File "D:/PROJECT/pars_2/1.py", line 46, in main
navigate()
File "D:/PROJECT/pars_2/1.py", line 43, in navigate
crop(location,size)
File "D:/PROJECT/pars_2/1.py", line 29, in crop
tel_recon()
File "D:/PROJECT/pars_2/1.py", line 17, in tel_recon
tel = image_to_string(img)
File "C:\Python361-32\lib\site-packages\pytesseract\pytesseract.py", line 124, in image_to_string
errors = get_errors(error_string)
File "C:\Python361-32\lib\site-packages\pytesseract\pytesseract.py", line 67, in get_errors
error_string = error_string.decode('utf-8')
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xad in position 12: invalid start byte