petektools 0.0.2

Standalone numerics & geostatistics kernels for Rust: scattered-data gridding (minimum-curvature, IDW, nearest) and a curated numeric front-door. Pure leaf; PyO3 bindings planned.
Documentation
//! The crate error type and `Result` alias.

use thiserror::Error;

/// `Result<T>` specialised to [`AlgoError`].
pub type Result<T> = std::result::Result<T, AlgoError>;

/// Errors raised by petekTools kernels.
///
/// Kept small and `&'static str`-payloaded; kernels are pure numerics, so the
/// failure surface is narrow (bad inputs, degenerate geometry).
#[derive(Debug, Error)]
pub enum AlgoError {
    /// A kernel was handed no data to work with.
    #[error("empty input: {0}")]
    EmptyInput(&'static str),

    /// The target lattice is degenerate (e.g. zero node spacing).
    #[error("invalid geometry: {0}")]
    InvalidGeometry(&'static str),
}