如何使用带有Stitcher类的opencv python从UAV拼接图像 [英] How to stitch images from a UAV using opencv python with Stitcher class

查看:421
本文介绍了如何使用带有Stitcher类的opencv python从UAV拼接图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在OpenCV Python中搜索Stitcher类,这将帮助我缝合从无人机收集的图像.我正在遵循此链接中显示的方法 如何在Python中使用OpenCV Stitcher类? 不幸的是,这在OpenCV 3.1和Python 2.7中引发了一些错误.我没有找到适合此功能的任何Opencv文档.任何人都可以在这方面帮助我. 如果有人能够使用python解释拼接器类,那将是非常感谢. `导入cv2

I was searching for the Stitcher class in OpenCV Python which will help me to stitch the images which I collect from the UAV. I was following the method shown in this link How to use OpenCV Stitcher class with Python? Unfortunately this is throwing some errors in OpenCV 3.1 and Python 2.7. I didn't find any appropriate Opencv docs for this function. Could anyone please help me in this. It would be highly apperciated if someone is able to explain the stitcher class using python. ` import cv2

stitcher = cv2.createStitcher(False)
foo = cv2.imread("Image1")
bar = cv2.imread("Image2")
result = stitcher.stitch((Image1,Image2))

cv2.imshow("stitch_image",result)

推荐答案

基于

Based on this other answer, I believe you need to do the following:

cv2.imshow("stitch_image",result[1])

这篇关于如何使用带有Stitcher类的opencv python从UAV拼接图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆