Skip to main content

oxicuda_cs/dictionary/
mod.rs

1//! Dictionary learning: K-SVD, MOD, and online dictionary updates.
2
3pub mod coupled_dl;
4pub mod k_svd;
5pub mod mod_dl;
6pub mod online_dl;
7
8pub use coupled_dl::{CoupledDictionary, CoupledDlConfig, couple_code, coupled_dl};
9pub use k_svd::k_svd;
10pub use mod_dl::mod_dl;
11pub use online_dl::online_dl;
12
13/// Dictionary learning result.
14#[derive(Debug, Clone)]
15pub struct DictionaryResult {
16    /// `d × k` dictionary row-major (each column is an atom).
17    pub dict: Vec<f64>,
18    /// `k × n_samples` coefficient matrix row-major.
19    pub codes: Vec<f64>,
20    pub iterations: usize,
21}