Skip to content

streaming: variants-output surface (variants/variant-windows, min_af/max_af, var_fields) — Wave B of #277 #304

Description

@d-laub

Part of the write-free StreamingDataset effort — see docs/roadmaps/streaming-dataset.md (Plan 5). Split out of #277.

#277 (output-mode breadth) splits along a hard technical seam into two waves:

Scope (Wave B)

Bring StreamingDataset up to the written Dataset's variant-level output surface:

  • with_seqs("variants") (RaggedVariants) and with_seqs("variant-windows") (_FlatVariantWindows).
  • min_af / max_af filtering. Note: on the written path this is implemented only for variants output (get_variants_flat, _flat_variants.py); haplotype/annotated output raises NotImplementedError (_haps.py:707). Streaming matches that — hence AF lives in Wave B, not A.
  • var_fields (custom per-call FORMAT / INFO columns; default ["alt","ilen","start"]).

Why this is the expensive half

The written variants path (get_variants_flat) does not use a reconstruct kernel — it uses assemble_variant_buffers_u8/i32 + gather/compact helpers, consuming per-variant data the current streaming buffer (src/record_stream/transpose.rs::DecodedWindow) does not carry:

fill_decoded_window throws all of this away today; Wave B must extract it per backend (VCF/PGEN INFO/REF decode via genoray DenseChunk; SVAR1/SVAR2 read it from their stores).

Also in scope

Parity oracle

Byte-identical vs gvl.write() + Dataset[r, s] under the matching with_seqs(...) / min_af / max_af / var_fields config.

Backends

SVAR1 + VCF + PGEN (the backends merged into streaming). SVAR2 (#298) picks up the same generic code when it merges.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions