lynx.dataset.XeniumDataset

class lynx.dataset.XeniumDataset(*args, **kwargs)[source]

Bases: Dataset

Load Xenium ST graph w/ auxiliary DESI modality

Parameters:
  • adatas (Union[sc.AnnData, List[sc.AnnData]]) – List of spatial data

  • k (int) – Resolution for k-NN graph

  • n_subgraphs (int) – Number of graph partition batches per data

  • r (float)

  • is_grid (bool)

  • verbose (bool)

__init__(adatas, k=8, r=50, n_subgraphs=8, is_grid=False, verbose=True, **kwargs)[source]
Parameters:

Methods

__init__(adatas[, k, r, n_subgraphs, ...])

construct_graph(neighbor_nodes, distances[, ...])

Compute undirected graph edges & attributes

get(idx)

get_neighbors(ref_coords, query_coords[, ...])

Retrieve k-nearest-neighbor (or radius-bounded neighbors) of query_coords to ref_coords using a KDTree

len()

load_graphs()

construct_graph(neighbor_nodes, distances, cluster_labels=None)[source]

Compute undirected graph edges & attributes

Parameters:
static get_neighbors(ref_coords, query_coords, is_grid=False, k=8, r=50)[source]

Retrieve k-nearest-neighbor (or radius-bounded neighbors) of query_coords to ref_coords using a KDTree

Parameters: