1 个不稳定版本
0.1.1 | 2024年5月18日 |
---|---|
0.1.0 |
|
#541 in 图像
每月21次下载
205KB
250 行
笔画宽度变换
这是对sunsided/stroke-width-transform仓库的Rust重实现。它提供了一个测试实现,该实现实现了在论文Detecting Text in Natural Scenes with Stroke Width Transform(PDF 在此)中描述的笔画宽度变换算法。
我们提出了一种新的图像操作符,旨在寻找每个图像像素的笔画宽度,并在自然图像中的文本检测任务上展示了其用法。所提出的操作符是局部和依赖数据的,这使得它足够快和健壮,足以消除多尺度计算或扫描窗口的需要。广泛的测试表明,所提出的方案优于最新的已发表算法。其简单性允许算法检测许多字体和语言的文本。
示例
要应用 SWT 到示例图像并显示结果,请运行
$ cargo run --release --example swt -- --show images/train-station.jpg
SWT 的直接输出是一个映射,其中每个像素值对应于该像素上的笔画长度。
示例输入 | 示例输出(SWT) |
---|---|
![]() |
![]() |
原始发布
@InProceedings{epshtein2010detecting,
author = {Epshtein, Boris and Ofek, Eyal and Wexler, Yonatan},
title = {Detecting Text in Natural Scenes with Stroke Width Transform},
year = {2010},
month = {June},
abstract = {We present a novel image operator that seeks to find the value of stroke width for each image pixel, and demonstrate its use on the task of text detection in natural images. The suggested operator is local and data dependent, which makes it fast and robust enough to eliminate the need for multi-scale computation or scanning windows. Extensive testing shows that the suggested scheme outperforms the latest published algorithms. Its simplicity allows the algorithm to detect texts in many fonts and languages.},
publisher = {IEEE - Institute of Electrical and Electronics Engineers},
url = {https://www.microsoft.com/en-us/research/publication/detecting-text-in-natural-scenes-with-stroke-width-transform/},
}
许可证
此仓库中的代码可在 MIT 许可证下获得(请参阅 LICENSE.md)。
依赖项
~10MB
~199K SLoC