mirror of
https://github.com/wassname/scikit-image.git
synced 2026-09-11 12:43:04 +08:00
put code into functions
This commit is contained in:
@@ -164,8 +164,13 @@ class RAG(nx.Graph):
|
||||
"""
|
||||
return self.max_id + 1
|
||||
|
||||
def _add_node(self, u):
|
||||
super(RAG, self).add_node(u)
|
||||
def _add_node_silent(self, n):
|
||||
"""Add node `n` without updating the maximum node id.
|
||||
|
||||
This is a convenience method used internally.
|
||||
|
||||
.. seealso:: :func:`networkx.Graph.add_node`."""
|
||||
super(RAG, self).add_node(n)
|
||||
|
||||
|
||||
def _add_edge_filter(values, graph):
|
||||
|
||||
Reference in New Issue
Block a user