bundles / scipy 1.17.1 / scipy / _lib / _disjoint_set / DisjointSet / subset_size
function
scipy._lib._disjoint_set:DisjointSet.subset_size
Signature
def subset_size ( self , x ) Summary
Get the size of the subset containing x.
Extended Summary
Note that this method is faster than len(self.subset(x)) because the size is directly read off an internal field, without the need to instantiate the full subset.
Parameters
x: hashable objectInput element.
Returns
result: intSize of the subset containing
x.
Aliases
-
scipy.cluster.hierarchy.DisjointSet.subset_size