adata slots for table and point spec in ngff
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 171
- Forks
- 75
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 20
Description
related to #64 and https://github.com/kevinyamauchi/ome-ngff-tables-prototype , as discussed this morning with @kevinyamauchi this is a description of adata slots and how they are used in https://github.com/theislab/squidpy and other spatial analysis tools of the https://github.com/theislab/scanpy ecosystem.
adata.Xandadata.layers["layer"]store molecular info (gene/protein expression etc.).adata.obsmstores various "latent" representations of obs (e.g. PCA/UMAP coordinates) but also:adata.obsm["spatial"]stores obs coordinates in space, with shape(N,2)or(N,3).adata.obsm["molecule_spatial"]will store molecule location in FISH-based data (with awkward arrays).
adata.varmno real use in spatial data afaikadata.obspstores adjacency matrices of e.g. graphs in spatial coordinates, knn graphs in latent spaces etc.adata.varpno real use in spatial data afaikadata.unsstores a bunch of image-related data. It is structured as follow:adata.uns["spatial"]containslibrary_idkeys that correspond to unique identifiers of images (e.g. tissue slides). These values are also stored inadata.obs["library_ids"]which can be used to subset anndata based on the tissue slide of interest. Furthermore, insideadata.uns["spatial"][<library_id>]there are 2 more dictionaries:imagesfor small-size tissue images (order of Mbs)scalefactorsmetadata related to scaling original coordinates inadata.obs["spatial"]as well as other infos
adata.uns also stores intermediate analysis results by several analysis tools in the ecosystem. e.g. trajectory analysis, velocity, various plotting params etc. I would therefore consider to support it for a better integration in the ecosystem.
It would also be ok to store the same type of info in metadata in ngff, and then handle this on the API side (it'd be fine for us at Squidpy, not so sure for others).
@kevinyamauchi next week I'll try out https://github.com/kevinyamauchi/ome-ngff-tables-prototype and report back, thanks again for sharing.
Just want to mention one more time that this is super exciting and am really looking forward to see how it develops!
pinging various people @ivirshup @michalk8 @hspitzer @AnnaChristina @LucaMarconato
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing related issue #64 and the ome-ngff-tables-prototype, then compare the listed AnnData slots with the NGFF metadata options. Done means reaching and documenting a decided representation for spatial, molecular, graph, image, and intermediate analysis data, including whether it belongs in metadata or dedicated NGFF slots.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data, documentation
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100