AnnData schema registry#
smftools maintains a versioned AnnData schema registry to document the expected
structure of each processing stage (raw, preprocess, spatial, hmm, and future).
The registry captures the intended keys, data types, creators, and notes for
each AnnData slot (obs, var, obsm, varm, layers, obsp, uns).
The runtime pipeline also records a live schema snapshot in
adata.uns["smftools"]["schema"], along with a schema_registry_version field
to link each file to the registry version used for documentation.
Schema registry version: 1
raw#
Stage requires: None
obs#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
None |
None |
Experiment identifier applied to all reads. |
|
|
|
`` |
obs.Experiment_name + obs.Barcode |
None |
Concatenated experiment name and barcode. |
|
|
|
`` |
None |
None |
Barcode assigned during demultiplexing or extraction. |
|
|
|
`` |
None |
None |
Read length in bases. |
|
|
|
`` |
None |
None |
Aligned length in bases. |
|
|
|
`` |
None |
None |
Reference length for alignment target. |
|
|
|
`` |
None |
None |
Per-read quality score. |
|
|
|
`` |
None |
None |
Mapping quality score. |
|
|
|
`` |
None |
None |
0-based reference start position for the alignment. |
|
|
|
`` |
None |
None |
0-based reference end position (exclusive) for the alignment. |
|
|
|
`` |
obs.read_length + obs.reference_length |
None |
Read length divided by reference length. |
|
|
|
`` |
obs.mapped_length + obs.reference_length |
None |
Mapped length divided by reference length. |
|
|
|
`` |
obs.mapped_length + obs.read_length |
None |
Mapped length divided by read length. |
|
|
|
|
X OR layers.raw_mods |
None |
Summed modification signal per read. |
|
|
|
`` |
obs_names |
None |
POD5 filename source for each read. |
|
|
|
`` |
obs_names |
None |
Classification of demultiplexing status. |
|
|
|
`` |
obs.cigar |
None |
Longest internal insertion (bp) from the alignment CIGAR; consumed by preprocess's CIGAR-indel filter. |
|
|
|
`` |
obs.cigar |
None |
Longest internal deletion (bp) from the alignment CIGAR; consumed by preprocess's CIGAR-indel filter. |
|
|
|
`` |
obs.cigar |
None |
Per-read C->T (top-consistent) deamination event count, from the alignment CIGAR. Deaminase modality only. |
|
|
|
`` |
obs.cigar |
None |
Per-read G->A (bottom-consistent) deamination event count, from the alignment CIGAR. Deaminase modality only. |
|
|
|
`` |
obs.ct_event_count + obs.ga_event_count |
None |
Best two-segment purity of the ordered C->T/G->A vote track; ~1.0 for a pure read or a clean PCR chimera, lower for a noisy read. Deaminase modality only. |
|
|
|
`` |
obs.ct_event_count + obs.ga_event_count |
None |
Reference coordinate of the best opposite-majority C->T/G->A split, or -1 if none. Deaminase modality only. |
var#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
None |
None |
Reference coordinate for each column. |
|
|
|
`` |
None |
None |
Reference contig or sequence name. |
obsm#
No entries defined.
varm#
No entries defined.
layers#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
None |
None |
Raw modification scores (modality-dependent). |
obsp#
No entries defined.
uns#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
None |
None |
smftools metadata including history, environment, provenance, schema snapshot. |
preprocess#
Stage requires: raw
obs#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
layers.nan0_0minus1 |
obs.demux_type |
Cluster identifier for duplicate detection. |
|
|
|
`` |
obs.ct_event_count + obs.ga_event_count + obs.strand_segment_purity |
None |
Flags reads whose deamination signature switches from a C->T span to a G->A span partway through the read (PCR chimera evidence). Reads are labeled, not removed. Deaminase modality only. |
var#
No entries defined.
obsm#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
X |
None |
UMAP embedding for preprocessed reads. |
varm#
No entries defined.
layers#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
|
X |
None |
Binarized methylation matrix (nan=0, 0=-1). |
obsp#
No entries defined.
uns#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
obs.sequence__merged_cluster_id |
None |
Duplicate read group metadata. |
spatial#
Stage requires: raw, preprocess
obs#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
obsm.X_umap |
None |
Leiden cluster assignments. |
var#
No entries defined.
obsm#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
X |
None |
UMAP embedding for spatial analyses. |
varm#
No entries defined.
layers#
No entries defined.
obsp#
No entries defined.
uns#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
X |
obs.reference_column |
Positionwise correlation statistics for spatial analyses. |
hmm#
Stage requires: raw, preprocess, spatial
obs#
No entries defined.
var#
No entries defined.
obsm#
No entries defined.
varm#
No entries defined.
layers#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
layers.nan0_0minus1 |
None |
HMM-derived state calls per read/position. |
obsp#
No entries defined.
uns#
Key |
Dtype |
Created by |
Modified by |
Requires |
Optional inputs |
Notes |
|---|---|---|---|---|---|---|
|
|
|
`` |
layers.hmm_state_calls |
None |
Flag indicating HMM annotations are present. |