这是一个示例航空图像:
![一些未冻结的湖泊的鸟瞰图] [1]

如何自动从图像中检测并提取黑色未冻结湖的参数?我主要使用Python。

编辑:请参阅下面我的回答;我想我已经找到了解决方案。

最佳答案

这是在SimpleCV中执行此操作的快速方法:

from SimpleCV import *

lakeimg = Image('http://i.stack.imgur.com/ku8F8.jpg') #load this image from web, or could be locally if you wanted.
invimg = lakeimg.invert() #we invert because blobs looks for white blobs, not black
lakes = invimg.findBlobs() # you can always change parameters to find different sized blobs
if lakes: lakes.draw() #if it finds blobs then draw around them
invimg.show() #display the image

如果您希望始终可以使用参数,那么如果您希望它相当健壮,通常我们会使用图像大小的比率。 Features类中还有很多选项,可以在一些斑点上绘制边界框,等等。

关于python - 如何在航空影像中的白色雪域背景上检测出一个黑湖?,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/11768763/

10-12 22:22