tesseract 字体训练资料篇

1.制作.box档案文件.

tesseract [lang].[fontname].exp[num].tif [lang].[fontname].exp[num] -l yournewlanguage batch.nochop makebox

2.开始培训

tesseract [lang].[fontname].exp[num].tif [lang].[fontname].exp[num] box.train

tesseract [lang].[fontname].exp[num].tif [lang].[fontname].exp[num] box.train.stderr

set_unicharset_properties

不知道什么来的

training/set_unicharset_properties -U input_unicharset -O output_unicharset --script_dir=training/langdata

font_properties

字体属性文件

<fontname> <italic> <bold> <fixed> <serif> <fraktur>

在<字体>是一个字符串命名的字体 ; <斜体>,<加粗>,<固定>,<衬线>和<哥特体>都是简单的0或1标志指示字体是与否的属性。

Example:

timesitalic     

----在3.03,有一个默认的font_properties文件,涵盖3000字体(不一定准确)培训/langdata / font_properties。

Clustering

shapeclustering 创建主控形状表的聚类形状并将其写入一个文件shapetable。

shapeclustering -F font_properties -U unicharset lang.fontname.exp0.tr lang.fontname.exp1.tr ...

----如果你得到错误信息,像这样的 "index >= 0 && index < size_used_:Error:Assert failed in genericvector.h, line 512" 添加shapetable文件到您的语言数据文件。

mftraining -F font_properties -U unicharset -O lang.unicharset lang.fontname.exp0.tr lang.fontname.exp1.tr ...

你的文件是通过unicharset_extractor以上产生的unicharset,和lang.unicharset是输出unicharset将给予combine_tessdata。mftraining将输出两个数据文件:inttemp(形状的原型)和pffmtable(每个字符的预期功能)。

输出normproto数据文件 

cntraining lang.fontname.exp0.tr lang.fontname.exp1.tr ...

数据字典(可选)

Name Type Description
word-dawg dawg A dawg made from dictionary words from the language.
freq-dawg dawg A dawg made from the most frequent words which would have gone into word-dawg.
punc-dawg dawg A dawg made from punctuation patterns found around words. The "word" part is replaced by a single space.
number-dawg dawg A dawg made from tokens which originally contained digits. Each digit is replaced by a space character.
fixed-length-dawgs dawg Several dawgs of different fixed lengths —— useful for languages like Chinese.
bigram-dawg dawg A dawg of word bigrams where the words are separated by a space and each digit is replaced by a ?.
unambig-dawg dawg TODO: Describe.
user-words text A list of extra words to add to the dictionary. Usually left empty to be added by users if they require it; see tesseract(1).
wordlist2dawg frequent_words_list lang.freq-dawg lang.unicharset
wordlist2dawg words_list lang.word-dawg lang.unicharset

参考资料:

WIKI

https://code.google.com/p/tesseract-ocr/wiki/FAQ

Introduction

https://code.google.com/p/tesseract-ocr/wiki/TrainingTesseract3#font_properties_(new_in_3.01)

WORDLIST2DAWG(1) Manual Page

http://tesseract-ocr.googlecode.com/svn-history/trunk/doc/wordlist2dawg.1.html

COMBINE_TESSDATA(1) Manual Page

http://tesseract-ocr.googlecode.com/svn-history/r800/trunk/doc/combine_tessdata.1.html

tesseract 字体训练资料篇的更多相关文章

  1. 【Tesseract】Tesseract 的训练流程

    在泰迪杯A题中,我刚刚接触了Tesseact,其中训练字库中遇到了较多的问题.所以在此记录一下,也当做一个笔记,省得以后忘记. 为了方便 ,将tif命名格式设为[lang].[fontname].ex ...

  2. Windows下Tesseract4.0识别与中文手写字体训练

    一 . tesseract 4.0 安装及使用 1. tesseract 4.0 安装 安装包下载地址: http://digi.bib.uni-mannheim.de/tesseract/tesse ...

  3. OCR2:tesseract字库训练

    由于tesseract的中文语言包“chi_sim”对中文字体或者环境比较复杂的图片,识别正确率不高,因此需要针对特定情况用自己的样本进行训练,提高识别率,通过训练,也可以形成自己的语言库. 工具: ...

  4. tesseract ocr训练 pt验证码

    识别率有问题A大概率识别为n,因此需要训练,这里讲一下 如何训练 参考 java代码里边直接使用tess4j,是对tesseract的封装,但是如果要训练,还是需要在进行安装tesseract-ocr ...

  5. Tesseract训练中文字体识别

    注:目前仅说明windows下的情况 前言 网上已经有大量的tesseract的识别教程,但是主要有两个缺点: 大多数比较老,有部分内容已经不适用. 大部分只是就英文的训练进行探索,很少针对中文的训练 ...

  6. tesseract-ocr如何训练Tesseract 4.0

    引自:https://blog.csdn.net/huobanjishijian/article/details/76212214 原文:https://github.com/tesseract-oc ...

  7. Tesseract训练

    最近在用Tesseract做一个图片识别的小应用,目标图像只有数字和英文字母,在实际使用过程中发现个别数识别错误,因此不得不研究学习Tesseract的训练. http://www.cnblogs.c ...

  8. 使用jTessBoxEditorFX训练Tesseract-OCR教程

    使用jTessBoxEditorFX训练Tesseract-OCR教程 注:1,工具是JAVA编写的,所以在使用工具之间,需要安装JAVA环境. 2,安装Tesseract-OCR应用程序,并将目录添 ...

  9. jTessBoxEditor工具进行Tesseract3.02.02样本训练

    1.背景 前文已经简要介绍tesseract ocr引擎的安装及基本使用,其中提到使用-l eng参数来限定语言库,可以提高识别准确率及识别效率. 本文将针对某个网站的验证码进行样本训练,形成自己的语 ...

随机推荐

  1. find——文件查找命令 linux一些常用命令

    find 命令eg: 一般文件查找方法: 1.  find /home -name file  ,  在/home目录下查找文件名为file的文件2.  find /home -name '*file ...

  2. 【Unicode】字符编码表信息

    UTF-8有点类似于Haffman编码,它将Unicode编码为:0x00-0x7F的字符,用单个字节来表示:0x80-0x7FF的字符用两个字节表示:0x800-0xFFFF的字符用3字节表示:   ...

  3. easy_painting

    最近感觉结构,比例抓的容易多了.

  4. java not enough memory error.

    After Update from jre-7_21 to jre-7_45: Java HotSpot(TM) 64-Bit Server VM warning: INFO: os::commit_ ...

  5. 在HTML中怎么去掉a标签(超链接)的下划线?

    <style type="text/css">a:link,a:visited{ text-decoration:none; /*超链接无下划线*/}a:hover{ ...

  6. 使用XMl序列化器生成xml文件

    生成XML文件 创建几个虚拟的短信对象,存在list中 备份数据通常都是备份至sd卡 使用StringBuffer拼接字符串 把整个xml文件所有节点append到sb对象里 sb.append(&q ...

  7. android studio环境搭建-笔记1

    自己干了几年测试(功能性的),最近比较闲,就自己学习下android(以前也有所接触,但那是几年前的一点皮毛,都忘记了). 先搭建谷歌推出的android studio(以前用eclipse搭建总觉得 ...

  8. 第二篇:gradle脚本运行环境分析(gradle的语义模型)

    引言:通过上一篇的论述,我们知道gradle脚本是如假包换的groovy代码,但是这个groovy代码是运行在他的上下文环境里面的,学名叫语义模型.这一篇我们就来看看他的语义模型到底是什么,如何使用. ...

  9. WildFly 9.0.2 + SQLServer + BIRT + JNDI 处理BIRT报表发布时数据源的修改

    一.前提需求说明: 最近在做项目的时候使用jboss WildFly发布BIRT报表,在报表中我是直接添加的JDBC数据源,通过Database URL .用户名和密码连接数据库.后来在部署到正式和测 ...

  10. 小技巧之指定refer

    在当前页面A的控制台输入window.location.href='要跳去的页面B',B页面的refer即为A页面.