笔画宽度变换 (SWT) 实现 (Python)

Stroke Width Transform (SWT) implementation (Python)(笔画宽度变换 (SWT) 实现 (Python))
本文介绍了笔画宽度变换 (SWT) 实现 (Python)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

问题描述

谁能描述我如何在 python 中使用 opencv 或 simplecv 实现 SWT?

Can anyone describe how can i implement SWT in python using opencv or simplecv ?

推荐答案

好的,就这样吧:

底部有代码下载链接的实现细节链接:SWT

The link that has details on the implementation with the code download link at the bottom: SWT

为了完整起见,还提到 SWT 或 Stroke Width Transform 是 Epshtein 和其他人在 2010 年设计的,并且已证明是迄今为止最成功的文本检测方法之一.它不使用机器学习或复杂的测试.基本上在对输入图像进行 Canny 边缘检测之后,它会计算构成图像中对象的每个笔划的粗细.由于文本的笔画粗细一致,这可能是一种强大的识别功能.

For the sake of completeness, also mentioning that SWT or Stroke Width Transform was devised by Epshtein and others in 2010 and has turned out to be one of the most successful text detection methods til date. It does not use machine learning or elaborate tests. Basically after Canny edge detection on the input image, it calculates the thickness of each stroke that makes up objects in the image. As text has uniformly thick strokes, this can be a robust identifying feature.

链接中给出的实现是使用 C++、OpenCV 和 Boost 库,它们用于连接图遍历等.计算 SWT 步骤.我个人已经在 Ubuntu 上对其进行了测试,它工作得很好(而且效率很高),尽管准确度并不准确.

The implementation given in the link is using C++, OpenCV and the Boost library they use for the connected graph traversals etc. after the SWT step is computed. Personally I've tested it on Ubuntu and it works quite well (and efficiently), though the accuracy is not exact.

这篇关于笔画宽度变换 (SWT) 实现 (Python)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

相关文档推荐

groupby multiple coords along a single dimension in xarray(在xarray中按单个维度的多个坐标分组)
Group by and Sum in Pandas without losing columns(Pandas中的GROUP BY AND SUM不丢失列)
Group by + New Column + Grab value former row based on conditionals(GROUP BY+新列+基于条件的前一行抓取值)
Groupby and interpolate in Pandas(PANDA中的Groupby算法和插值算法)
Pandas - Group Rows based on a column and replace NaN with non-null values(PANAS-基于列对行进行分组,并将NaN替换为非空值)
Grouping pandas DataFrame by 10 minute intervals(按10分钟间隔对 pandas 数据帧进行分组)