past.Utils.Ripplewalk_prediction

past.Utils.Ripplewalk_prediction(graph, r=0.5, batchsize=6400)

Prediction stategy of subgraph segmentation based on random walk, enabling mini-batch prediction on large datasets

Parameters:
  • graph – graph indicating connectivity between spots, usually K-NN graph constructed from spatial coordinates

  • r – expansion ratio for sampling subgraph

  • batchsize – number of samples for a mini-batch

Returns:

a list containing index of sampled sub-graphs

Return type:

list