sfaira.data.DatasetGroupDirectoryOriented.write_backed¶
- DatasetGroupDirectoryOriented.write_backed(adata_backed: anndata._core.anndata.AnnData, genome: str, idx: List[numpy.ndarray], annotated_only: bool = False, load_raw: bool = False, allow_caching: bool = True)¶
Loads data set group into slice of backed anndata object.
Subsets self.datasets to the data sets that were found. Note that feature space is automatically formatted as this is necessary for concatenation.
- Parameters
adata_backed – Anndata instance to load into.
genome – Genome container target genomes loaded.
idx – Indices in adata_backed to write observations to. This can be used to immediately create a shuffled object. This has to be a list of the length of self.data, one index array for each dataset.
annotated_only –
load_raw – See .load().
allow_caching – See .load().
- Returns
New row index for next element to be written into backed anndata.