pub struct ReadSharedRowsArgs {Show 13 fields
pub data_files: Vec<Box<str>>,
pub batch_files: Option<Vec<Box<str>>>,
pub preload: bool,
pub feature_kind: Option<FeatureNameKind>,
pub row_alignment: RowAlignment,
pub column_alignment: ColumnAlignment,
pub qc: Option<QcConfig>,
pub keep_empty_barcodes: bool,
pub qc_exempt_files: Option<Vec<bool>>,
pub qc_block_size: Option<usize>,
pub qc_report_out: Option<Box<str>>,
pub per_file_feature_suffix: Option<Vec<Box<str>>>,
pub per_file_barcode_suffix: Option<Vec<Option<Box<str>>>>,
}Expand description
Arguments for loading multiple sparse data files with shared row names.
Fields§
§data_files: Vec<Box<str>>§batch_files: Option<Vec<Box<str>>>§preload: bool§feature_kind: Option<FeatureNameKind>Cross-file row-name canonicalization rule. None = auto-detect
via FeatureNameKind::auto_detect once row names are in hand.
Some(kind) skips detection and uses the caller’s choice.
Default = None (auto).
row_alignment: RowAlignmentHow to align row names across input files. Default
RowAlignment::Union keeps every row from any backend — the
strictly more permissive option that reduces to single-modality
semantics when all files share their row set, and supports
multi-modal load (e.g. paired RNA + ATAC) when they don’t.
Switch to RowAlignment::Intersect for strict “common rows
only” behavior.
column_alignment: ColumnAlignmentHow to align column (cell / barcode) names across input files.
Default ColumnAlignment::Disjoint concatenates cells with
@<basename> disambiguation, preserving single-modality
semantics. Switch to ColumnAlignment::Union for patchy
multi-modal (multiome) load: cells are glued by raw barcode
across backends, a cell observed in only one modality
contributes triplets only on that modality’s row block, and no
@<basename> suffix is added.
qc: Option<QcConfig>Optional shared cell QC. When Some, non-near-empty MAD outlier
cells are dropped from the working set (via mask_columns), the
returned batch Vec is filtered in lockstep, junk features are
dropped (when feature_min_cells > 0), and the near-empty
output keep-mask is returned in output_keep_idx. None
(the default) = no QC, i.e. today’s behavior.
keep_empty_barcodes: boolOpt out of the empty-barcode gate. By default each file’s columns
are cell-called on their own nnz distribution
(crate::qc::suggest_nnz_cutoff: the trough between the ambient
and the cell peak) and a column is dropped when it falls below the
cut in every file that observes it — so an unfiltered barcode axis
(e.g. ATAC from a fragments file) loses its empty droplets before any
projection or collapse, while a cell in two modalities survives on
either. A no-op on already-called data (no trough). Set true where
every input column must come back, e.g. query cells at inference.
Files flagged in qc_exempt_files are never gated.
qc_exempt_files: Option<Vec<bool>>Per-data_files entry: true exempts that file’s columns from QC —
out of the band statistics AND out of every verdict (see
qc_from_metrics). For inputs whose columns are not cells (a carried
pb_reference, bulk samples): a pseudobulk standing for hundreds of
cells is a legitimate depth outlier, and letting it into the MAD band
either gets it dropped or — worse, as the mixture grows — recenters
the band and guillotines the real cells. None = no exemption. Must
match data_files length when Some.
qc_block_size: Option<usize>Block size for the QC streaming stat passes (None = default).
qc_report_out: Option<Box<str>>Optional path for a per-cell QC report TSV (None = don’t write).
per_file_feature_suffix: Option<Vec<Box<str>>>Optional per-file feature-name (row) modality suffix, one entry per
data_files entry in order. When Some, backend b’s rows are
renamed {canon(row)}/{suffix[b]} so files sharing raw feature
names (e.g. spliced/unspliced) stay on separate rows, while the same
name + suffix (same modality across samples) still merges. None =
today’s behavior (no suffixing). Must match data_files length.
per_file_barcode_suffix: Option<Vec<Option<Box<str>>>>Optional per-file barcode (column) suffix, one entry per data_files
entry in order. Under ColumnAlignment::Union, backend b’s
barcodes are tagged {barcode}@{suffix[b]} before the canonical merge,
so callers can encode per-cell sample identity: the same barcode in
two files merges into one cell only when both carry the same suffix
(same sample across modalities), while different samples stay distinct.
None (or a per-entry None) = no tag. Must match data_files
length. No effect under Disjoint (which disambiguates via
@<basename>).
Trait Implementations§
Auto Trait Implementations§
Blanket Implementations§
impl<T> Allocation for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.