Skip to main content

Module separation

Module separation 

Source
Expand description

Source separation (classical masking now; learned = NeedsWeights). Re-exports only (AU-GEN).

apply_soft_mask / binary_mask_from_ratio are real classical spectral masking and work now over caller-owned buffers. separate_learned is a fail-closed stub for demucs-class learned separation that always returns crate::types::AudioError::BackendUnavailable — it never fabricates stems.

Re-exports§

pub use learned::separate_learned;
pub use mask::apply_soft_mask;
pub use mask::binary_mask_from_ratio;

Modules§

learned
Learned (demucs / open-unmix / band-split RNN class) source separation — fail-closed stub.
mask
Classical spectral masking for source separation. Given a mixture magnitude spectrum and a per-bin soft mask (each element in [0, 1]), the separated stem magnitude is the element-wise product stem = mixture ⊙ mask. This is the algorithmic core of ideal-ratio / Wiener-style masking; it invents nothing — it only re-weights energy the mixture already contains. Learned mask estimation (a demucs/openunmix network) is a separate, NeedsWeights concern (see learned.rs).