检测照片方向的算法

发布于 2024-07-27 17:18:16 字数 648 浏览 4 评论 0原文

我想自动旋转照片,即使有关图像方向的 EXIF 元数据不可用。

有没有好的算法来检测照片的方向? 这些图像是数码相机拍摄的照片。 该算法不必完美运行,但适当旋转照片所需的人机交互量的减少将是有益的。

我找到了关于该主题的这两篇论文:

对其他研究尤其是实现的指针表示赞赏。

I would like to rotate photos automatically, even when EXIF metadata about the image orientation is not available.

Are there any good algorithms for detecting the orientation of a photo? The images are photographs from a digital camera. The algorithm doesn't have to work perfectly, but any reduction in the amount of human interaction required to properly rotate photos would be a benefit.

I have found these two papers on the topic:

Pointers to other research and especially implementations are appreciated.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

微凉徒眸意 2024-08-03 17:18:16

消费者数码相机拍摄的许多照片都是人物照片,可用于定位。 人脸检测是一个经过充分研究的研究领域。 基本的面部检测会给你一个矩形,其长边应该是垂直尺寸。 此外,如果您可以检测到眼睛/嘴巴,您应该能够选择矩形的正确方向。

许多其他照片都是旅游照片,其中天空是向上的,蓝色的,地面是向下的,绿色的。

Many photographs from consumer digital cameras are of people, which could be used for orientation. Face detection is a well-studied research area. Basic face detection would give you a rectangle whose longer side should be the vertical dimension. Further, if you can detect the eyes/mouth, you should be able to pick the correct orientation of the rectangle.

Many other photographs are tourist snaps, where the sky is up and blue, and the ground is down and green.

习ぎ惯性依靠 2024-08-03 17:18:16

我只能找到 http://sourceforge.net/projects/rotator/

我使用了一组假日照片测试,其中包含 70 张照片,其中大约 18 张需要旋转。

使用默认设置处理后,有 20 个错误旋转或未旋转。

结果不太好。

I could only find http://sourceforge.net/projects/rotator/.

I used a test set of holiday photos comprising 70 pictures with about 18 requiring rotation.

After processing with the default settings, there were 20 that were either rotated or not rotated in error.

Not so great a result.

风追烟花雨 2024-08-03 17:18:16

如果图像不是正方形,您可以假设默认图像的宽度大于高度。
如果是这种情况,确定是否需要旋转只需比较纵横比并旋转以重新定向到默认值即可。 尽管您最终可能会得到颠倒的图像。

If the images are not square, you may be able to make the assumption that the default images are wider than they are tall.
If that's the case determaning whether you need to rotate is just a matter of comparing the aspect ratio and rotating to reorient to default. Though you may end up with upside down images.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文