用法:
skimage.future.graph.cut_threshold(labels, rag, thresh, in_place=True)
合並按權重小於閾值的區域。
給定圖像的標簽及其 RAG,通過組合節點之間的權重小於給定閾值的區域來輸出新標簽。
- labels:ndarray
標簽數組。
- rag:RAG
區域鄰接圖。
- thresh:浮點數
門檻。由具有較小權重的邊連接的區域被組合起來。
- in_place:bool
如果設置,修改
rag
到位。該函數將刪除權重小於脫粒.如果設置為False該函數複製rag
在繼續之前。
- out:ndarray
新標記的數組。
參數:
返回:
參考:
- 1
Alain Tremeau and Philippe Colantoni “Regions Adjacency Graph Applied To Color Image Segmentation” DOI:10.1109/83.841950
例子:
>>> from skimage import data, segmentation >>> from skimage.future import graph >>> img = data.astronaut() >>> labels = segmentation.slic(img) >>> rag = graph.rag_mean_color(img, labels) >>> new_labels = graph.cut_threshold(labels, rag, 10)
相關用法
- Python skimage.future.graph.cut_normalized用法及代碼示例
- Python skimage.future.graph.RAG.__init__用法及代碼示例
- Python skimage.future.graph.show_rag用法及代碼示例
- Python skimage.future.graph.ncut用法及代碼示例
- Python skimage.future.graph.rag_boundary用法及代碼示例
- Python skimage.future.graph.rag_mean_color用法及代碼示例
- Python skimage.future.manual_polygon_segmentation用法及代碼示例
- Python skimage.future.manual_lasso_segmentation用法及代碼示例
- Python skimage.feature.graycomatrix用法及代碼示例
- Python skimage.feature.blob_doh用法及代碼示例
- Python skimage.feature.blob_dog用法及代碼示例
- Python skimage.filters.unsharp_mask用法及代碼示例
- Python skimage.filters.rank.noise_filter用法及代碼示例
- Python skimage.filters.gaussian用法及代碼示例
- Python skimage.feature.graycoprops用法及代碼示例
- Python skimage.feature.corner_orientations用法及代碼示例
- Python skimage.filters.threshold_otsu用法及代碼示例
- Python skimage.feature.structure_tensor用法及代碼示例
- Python skimage.filters.rank.sum用法及代碼示例
- Python skimage.filters.window用法及代碼示例
注:本文由純淨天空篩選整理自scikit-image.org大神的英文原創作品 skimage.future.graph.cut_threshold。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。