grassp.io.list_msnset_results

grassp.io.list_msnset_results#

list_msnset_results(path, *, strict_spec=False)[source]#

Inventory a pRoloc artifact without reading it into a session.

Reports what the artifact holds and where each piece belongs, so you can look before you read or merge. strict_spec defaults to False here, since inspecting an artifact you cannot read is exactly when you want a report.

Return type:

dict[str, Any]

Returns:

A dict describing the artifact:

  • source, spec, n_obs, n_vars, obs_names – provenance, shape and a few example IDs.

  • obs / var{column: dtype} for the scalar fData / pData columns.

  • matrices{name: {"shape": [...], "categories": [...]}} for the matrix-valued fData columns, which live in .obsm; var_matrices the same for pData, in .varm.

  • layers – extra assayData element names.

  • notes – advisory warnings about columns pRoloc is known to misname.

  • dropped – slots the writer could not carry, per uns["msnset_dropped"].

Parameters:
path str | Path | AnnData

strict_spec bool

Examples

>>> gr.io.list_msnset_results("results.h5ad")["matrices"]
{'svm.all.scores': {'shape': [2538, 12], 'categories': ['Cytosol', ...]}}