mirror of
https://github.com/ParrotXray/Mantis.git
synced 2026-08-24 19:00:27 +09:00
31 lines
994 B
Rust
31 lines
994 B
Rust
use std::path::PathBuf;
|
|
|
|
use macros::traceable;
|
|
|
|
traceable! {
|
|
MLError {
|
|
#[no_source]
|
|
#[error("Initialize Machine Learning detection failed")]
|
|
InitializeFailed => tracing::Level::ERROR,
|
|
|
|
#[no_source]
|
|
#[error("Failed to load ONNX model from: {path:?}")]
|
|
ModelLoadFailed { path: PathBuf } => tracing::Level::ERROR,
|
|
|
|
#[no_source]
|
|
#[error("Failed to load inference configuration from: {path:?}")]
|
|
ConfigLoadFailed { path: PathBuf } => tracing::Level::ERROR,
|
|
|
|
#[no_source]
|
|
#[error("Failed to parse inference configuration: {reason}")]
|
|
ConfigParseFailed { reason: String } => tracing::Level::ERROR,
|
|
|
|
#[no_source]
|
|
#[error("Tracker mutex poisoned; skipping operation")]
|
|
TrackerLockPoisoned => tracing::Level::ERROR,
|
|
|
|
#[no_source]
|
|
#[error("Inference flow buffers mutex poisoned; skipping operation")]
|
|
InferenceLockPoisoned => tracing::Level::ERROR,
|
|
}
|
|
} |