什么是 font_properties 为 Tesseract OCR 制作训练数据?
What is font_properties in making traineddata for Tesseract OCR?
我正在尝试创建一个训练有素的数据文件来训练 tesseract 如何读取我将提供给它的图像,但我不明白 font_properties 步骤中要包含什么。
我正在关注 this example and the answer to post。这两个示例仅将 0 和 1 作为 font_properties 的值,而我的训练数据文件用于特定的字母数字值。在我发给你的第二个 link 中,你能告诉我更多关于步骤 3 中要包含的内容吗?它可以是任何东西吗,它就像是对字体的简单描述,还是它实际上很重要并且需要准确。
哦,我明白了。 1 表示是,0 表示否。我在考虑不同的事情。我现在明白了,例如,如果我的字体是粗体,我会给粗体值 1。
Each line of the font_properties file is formatted as follows:
fontname italic bold fixed serif fraktur where fontname is a string
naming the font (no spaces allowed!), and italic, bold, fixed, serif
and fraktur are all simple 0 or 1 flags indicating whether the font
has the named property.
Example:
timesitalic 1 0 0 1 0
我正在尝试创建一个训练有素的数据文件来训练 tesseract 如何读取我将提供给它的图像,但我不明白 font_properties 步骤中要包含什么。
我正在关注 this example and the answer to
哦,我明白了。 1 表示是,0 表示否。我在考虑不同的事情。我现在明白了,例如,如果我的字体是粗体,我会给粗体值 1。
Each line of the font_properties file is formatted as follows: fontname italic bold fixed serif fraktur where fontname is a string naming the font (no spaces allowed!), and italic, bold, fixed, serif and fraktur are all simple 0 or 1 flags indicating whether the font has the named property.
Example:
timesitalic 1 0 0 1 0