python skimage 连通性区域检测方法

时间:2019-04-20
本文章向大家介绍python skimage 连通性区域检测方法,主要包括python skimage 连通性区域检测方法使用实例、应用技巧、基本知识点总结和需要注意事项,具有一定的参考价值,需要的朋友可以参考一下。

涉及到的函数为

import matplotlib.pyplot as plt
from skimage import measure, color
labels = measure.label(img4[:,:,0], connectivity=2)
dst = color.label2rgb(labels)
plt.imshow(dst)

labels为整个灰度图像的坐标的类别标签,值为[0, max_label], 一个连通区域为一个 lable .

以上这篇python skimage 连通性区域检测方法就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持脚本之家。