Tesseract OCR 执行哪些预处理操作?

编程入门 行业动态 更新时间:2024-10-28 12:18:47
本文介绍了Tesseract OCR 执行哪些预处理操作?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时送ChatGPT账号..

我找不到详细的文档,也没有浏览源代码的感觉.例如,如果 Tesseract 引擎已经完成了精明的边缘检测,我不想重做.

I couldn't find a detailed documentation and I don't feel browsing the source code. I want not to redo canny edge detection for example if it is already done by Tesseract engine.

推荐答案

本文档提供了引擎的概述:https://github/tesseract-ocr/docs/blob/master/tesseracticdar2007.pdf

This document provides an overview of the engine: https://github/tesseract-ocr/docs/blob/master/tesseracticdar2007.pdf

所以看起来你不需要实现canny边缘检测.

So it looks like you don't need to implement canny edge detection.

Tesseract 在处理之前使用 Otsu 阈值对图像进行二值化 https://github/tesseract-ocr/tesseract/blob/master/ccstruct/otsuthr.h

Tesseract uses Otsu thresholding to binarize the image before processing it https://github/tesseract-ocr/tesseract/blob/master/ccstruct/otsuthr.h

如果您想查看二值化图像,只需在\tessdata\configs\"中创建一个新的配置文件,添加以下行:tessedit_write_images True 并处理您的图像:tesseractyour_image out your_config_file.Tesseract 将二值化图像保存为 tessinput.tif.

If you want to see the binarized image just create a new config file in "\tessdata\configs\", add this line: tessedit_write_images True and process your image: tesseract your_image out your_config_file. Tesseract saves the binarized image as tessinput.tif.

这篇关于Tesseract OCR 执行哪些预处理操作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

更多推荐

[db:关键词]

本文发布于:2023-04-30 23:12:28,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1401085.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:操作   Tesseract   OCR

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!