Erro ao tentar passar a onfig_tesseract:
TesseractError: (1, 'Error opening data file tessdata/por.traineddata Please make sure the TESSDATA_PREFIX environment variable is set to your "tessdata" directory. Failed loading language 'por' Tesseract couldn't load any languages! Could not initialize tesseract.')
meu código:
img_livro = cv2.imread("/content/text-recognize/Imagens/Aula2-trecho-livro.png")
rgb = cv2.cvtColor(img_livro, cv2.COLOR_BGR2RGB)
cv2_imshow(img_livro)
config_tesseract = '--tessdata-dir tessdata'
texto3 = pytesseract.image_to_string(rgb, lang='por', config=config_tesseract)
print(texto3)