- class neuroglancer.EquivalenceMap
Union-find data structure.
Public members¶
-
EquivalenceMap(existing=
None
, _readonly=False
) Create a new empty union-find structure.
- __getitem__(obj: int) -> int
Returns the minimum element in the set containing the specified element.
- clear()
- union(*elements: int) -> int | None
Unions the equivalence classes containing the specified elements.
- members(element: int) -> Iterator[int]
Yields the members of the equivalence class containing the specified element.
- __copy__() -> EquivalenceMap
Does not preserve _readonly attribute.
- __deepcopy__(memo) -> EquivalenceMap
Does not preserve _readonly attribute.
- copy() -> EquivalenceMap
Returns a copy of the equivalence map.
- delete_set(element: int)
Removes the equivalence class containing the specified element.
- isolate_element(element: int)
Isolates the specified element from its equivalence class.
-
EquivalenceMap(existing=