フィルターのクリア

How to use the .traineddata file with the ocr function after training?

13 ビュー (過去 30 日間)
Artyom Archiyan
Artyom Archiyan 2017 年 11 月 10 日
コメント済み: H LIU 2020 年 12 月 8 日
I trained the our function using a data set, but I don't know how to actually load in the data for use.

採用された回答

Nick Choi
Nick Choi 2017 年 11 月 13 日
You can use the path to the trained data file as part of the 'Language' name-value pair. One thing to note is that the trained data file must be located in a folder named 'tessdata'. An example function call would look like this:
txt = ocr(img,'Language','path/to/tessdata/eng.traineddata');
The following documentation link provides some additional information on how to use .traineddata files with the 'ocr' function: https://www.mathworks.com/help/vision/ref/ocr.html#input_argument_namevalue_d119e140075
  2 件のコメント
MUHAMMED IRFAN
MUHAMMED IRFAN 2017 年 12 月 11 日
Hello, I used this simple code.I have trained data for malayalam language in the mentioned location.But the matlab crashes as shown in the figure. What's wrong with my code?
Card = imread('sam.png');
txt = ocr(Card,'Lang','E:\irfan\OCR\tessdata\mal.traineddata');
H LIU
H LIU 2020 年 12 月 8 日
txt = ocr(Card,'Language',{'E:\irfan\OCR\tessdata\mal.traineddata'});
have a try !

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeCharacters and Strings についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by