我正在使用 Ubuntu 16.04 运行 OpenALPR。我安装了它并从我所在国家的 TTF 字体文件中生成了字体图块,但在使用train.py时遇到了问题。它应该生成[countrycode].traineddata
文件,但是当我从终端窗口执行它时出现以下错误:
Processing: ./ae/input/lae.abudhabi.exp0.box
./ae/input/lae.abudhabi.exp0.tif
Executing: /home/user123/train-ocr/tesseract-ocr/tesseract -l eng ./ae/input/lae.abudhabi.exp0.tif lae.abudhabi.exp0 nobatch box.train.stderr
sh: 1: /home/user123/train-ocr/tesseract-ocr/tesseract: Permission denied
mv: cannot stat './lae.abudhabi.exp0.tr': No such file or directory
mv: cannot stat './lae.abudhabi.exp0.txt': No such file or directory
sh: 1: /home/user123/train-ocr/tesseract-ocr/tesseract/training/unicharset_extractor: not found
Executing: /home/user123/train-ocr/tesseract-ocr/tesseract/training/mftraining -F ./tmp/font_properties -U unicharset -O ./tmp/lae.unicharset ./tmp/*.tr
sh: 1: /home/user123/train-ocr/tesseract-ocr/tesseract/training/mftraining: not found
rm: cannot remove './unicharset': No such file or directory
mv: cannot stat './tmp/lae.unicharset': No such file or directory
cp: cannot stat './ae/input/unicharambigs': No such file or directory
sh: 1: /home/user123/train-ocr/tesseract-ocr/tesseract/training/cntraining: not found
mv: cannot stat './shapetable': No such file or directory
mv: cannot stat './pffmtable': No such file or directory
mv: cannot stat './inttemp': No such file or directory
mv: cannot stat './normproto': No such file or directory
sh: 1: /home/user123/train-ocr/tesseract-ocr/tesseract/training/combine_tessdata: not found
./ae/ae.config
Applying config file: ./ae/ae.config
lae.traineddata
sh: 1: /home/user123/train-ocr/tesseract-ocr/tesseract/training/combine_tessdata: not found
config file: /home/user123/train-ocr/tesseract-ocr/tesseract/training/combine_tessdata -o lae.traineddata ./ae/ae.config
status: 32512
mv: cannot stat './lae.unicharset': No such file or directory
mv: cannot stat './lae.shapetable': No such file or directory
mv: cannot stat './lae.pffmtable': No such file or directory
mv: cannot stat './lae.inttemp': No such file or directory
mv: cannot stat './lae.normproto': No such file or directory
mv: cannot stat './lae.unicharambigs': No such file or directory
我不确定我应该做什么,因为所有文件路径都是正确的。此外,代码要求在这一行中提供一个 .config 文件,但没有指定我应该从哪里获取它。根据此处的说明,我为我的国家/地区的字体创建了一个 .conf 文件,并生成了 .box 和 .tif 文件,但没有提及 .config。
任何帮助将不胜感激!我正在使用默认的 Python 版本 2.7.12。用户主目录中的我的 Tesseract 文件。