-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adata slots for table and point spec in ngff #99
Comments
Thanks, @giovp ! This is very helpful. In principle, it seems like all of these attributes could be included in the table spec. I don't think they add any additional data types (potentially with the exception of awkward arrays), so I don't think it adds much extra work for the non-python implementations. A couple of follow-up questions:
|
There hasn't been a zarr proposal yet. Interestingly, @eriknw joined the zarr call last night and I mentioned to him that @ivirshup might be getting in touch. I know @martindurant is interested as well. @MSanKeys963 and I can spend some time getting the existing issues cleaned up. |
thanks @kevinyamauchi for prompt reply!
exactly, I think there could pandas dataframes and there is interest for tuples and named tuples afaik but I think what you listed should be enough, maybe @ivirshup can comment more on this?
yes exactly, this is something that would be very useful and we'd be happy to change the current API in squidpy to accomodate that eventually. Current solution is not sustainable and doesn't really scale.
I'm working on adding awkward array support in both
I completely forgot about |
Values in
|
👍 Work here will likely start to ramp up soon (perhaps along with the soon to be listed https://github.com/zarr-developers/gsoc/tree/main/2022). Seems like it's a good time to get all of us working in the same direction. |
Is there a good place to discuss the awkward array proposal? I'm wondering whether the goal here is more like |
@kevinyamauchi, one more point I forgot to add about potential future changes in One place this might play into the design on OME is for point data, if
|
@joshmoore an update regarding reading/writing awkward arrays in zarr, we ended up doing it with This is the relevant code from scverse/anndata#647
where:
|
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.X
andadata.layers["layer"]
store molecular info (gene/protein expression etc.).adata.obsm
stores 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.varm
no real use in spatial data afaikadata.obsp
stores adjacency matrices of e.g. graphs in spatial coordinates, knn graphs in latent spaces etc.adata.varp
no real use in spatial data afaikadata.uns
stores a bunch of image-related data. It is structured as follow:adata.uns["spatial"]
containslibrary_id
keys 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:images
for small-size tissue images (order of Mbs)scalefactors
metadata related to scaling original coordinates inadata.obs["spatial"]
as well as other infosadata.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
The text was updated successfully, but these errors were encountered: