pub trait SparsePredict {
// Required method
fn predict_sparse(&self, input: &SparseMatrix) -> Result<Array2<f64>>;
// Provided methods
fn n_features(&self) -> Option<usize> { ... }
fn n_outputs(&self) -> Option<usize> { ... }
}Expand description
Prediction contract for models with a native CSR input boundary.
Required Methods§
fn predict_sparse(&self, input: &SparseMatrix) -> Result<Array2<f64>>
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".