技能创建器
skill-creator
创建、改进和评估自定义技能,把专业流程转化为可重复使用的 AI 能力。
storage-io【数据与研究】Read, write, choose, inspect, and troubleshoot AnnData H5AD/Zarr storage, backed mode, lazy reads, sparse datasets, element-level I/O, and Zarr v3 options.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Use this sub-skill when a task mentions .h5ad, .zarr, HDF5, Zarr, storage formats, backed mode, lazy reads, read_h5ad, read_zarr, write_h5ad, write_zarr, anndata.io.read_elem, anndata.io.write_elem, anndata.io.sparse_dataset, encoding metadata, sparse on-disk arrays, compression, chunking, Zarr v3, metadata consolidation, or concat_on_disk storage prerequisites.
obs/var semantics, .raw, and in-memory mutation to ../data-model/SKILL.md.../combining-data/SKILL.md; use this sub-skill only to prepare readable input stores and validate writable output stores for concat_on_disk.../accessors-extensions/SKILL.md.references/api-reference.md lists verified public I/O signatures, stable versus experimental APIs, and option notes.references/file-format.md distills the H5AD/Zarr hierarchy, required encoding metadata, and inspection checks.references/io-workflows.md gives decision workflows for H5AD versus Zarr, backed versus lazy access, element I/O, sparse datasets, Zarr v3 metadata, sharding, and compressor choices.references/troubleshooting.md maps storage symptoms to causes and recovery steps.scripts/check_anndata_io_roundtrip.py creates tiny deterministic H5AD and/or Zarr fixtures, reads them back, optionally checks backed/lazy access, and prints pass/fail without network access..h5ad for single-file local exchange and HDF5 backed reads; close backed objects with adata.file.close().read_h5ad/read_zarr for small or final validation reads; use read_h5ad(..., backed="r") for low-memory H5AD inspection; use anndata.experimental.read_lazy for experimental dask/xarray-backed low-memory reads.anndata.experimental.read_lazy, read_dispatched, and write_dispatched as experimental APIs; use stable high-level methods and anndata.io.read_elem/write_elem unless callback-based traversal or lazy materialization is required.python sub-skills/storage-io/scripts/check_anndata_io_roundtrip.py
python sub-skills/storage-io/scripts/check_anndata_io_roundtrip.py --backed-lazy
python sub-skills/storage-io/scripts/check_anndata_io_roundtrip.py --output-dir ./tmp-anndata-io --keep
When running the script from outside the skill directory, use its full path. The script creates only local temporary fixtures unless --output-dir is provided.