tensorlogic_infer/low_rank/
error.rs1#[derive(Debug, thiserror::Error)]
5pub enum LowRankError {
6 #[error("SVD failed after {iterations} iterations: {reason}")]
7 SvdFailed { iterations: usize, reason: String },
8
9 #[error("Rank {rank} exceeds min(rows={rows}, cols={cols})")]
10 RankExceedsDimensions {
11 rank: usize,
12 rows: usize,
13 cols: usize,
14 },
15
16 #[error("Approximation error {actual:.6} exceeds threshold {threshold:.6}")]
17 ErrorExceedsThreshold { actual: f64, threshold: f64 },
18
19 #[error("Invalid input: {0}")]
20 InvalidInput(String),
21
22 #[error("Numerical instability: {0}")]
23 NumericalInstability(String),
24}