stoclust

Logo

Clustering algorithms using stochastic analysis and ensemble techniques.

utils

  ↳ stoclust

Contains miscellaneous useful functions.

Functions

  • block_sum

    block_sum(a, blocks, axis=0)
    Given an array and a list of index blocks along a given axis, delivers a new array whose indices correspond to blocks and whose entries are sums over the old values.
  • sinkhorn_knopp

    sinkhorn_knopp(mat, num_iter=100, rescalings=False)
    Given a matrix of weights, generates a bistochastic matrix using the Sinkhorn-Knopp algorithm.
  • stoch

    stoch(weights, axis=-1)
    Reweights each row along a given axis such that sums along that axis are one.