scvelo.tl.VELOVI.setup_anndata

classmethod VELOVI.setup_anndata(adata, spliced_layer, unspliced_layer, **kwargs)

Sets up the AnnData object for this model.

A mapping will be created between data fields used by this model to their respective locations in adata. None of the data in adata are modified. Only adds fields to adata.

Parameters
adata : AnnData

AnnData object. Rows represent cells, columns represent features.

spliced_layer : str

Layer in adata with spliced normalized expression

unspliced_layer : str

Layer in adata with unspliced normalized expression.

Return type

AnnData, None

Returns

  • None. Adds the following fields

  • .uns[‘_scvi’]scvi setup dictionary

  • .obs[‘_scvi_labels’] – labels encoded as integers

  • .obs[‘_scvi_batch’] – batch encoded as integers