optirs_learned/adaptive/
compressionparams_traits.rs1use scirs2_core::numeric::Float;
12use std::fmt::Debug;
13
14use super::types::CompressionParams;
15
16impl<T: Float + Debug + Send + Sync + 'static> Default for CompressionParams<T> {
17 fn default() -> Self {
18 Self {
19 target_ratio: scirs2_core::numeric::NumCast::from(0.5).unwrap_or_else(|| T::zero()),
20 quality_threshold: scirs2_core::numeric::NumCast::from(0.95)
21 .unwrap_or_else(|| T::zero()),
22 max_time: 1000,
23 strength: scirs2_core::numeric::NumCast::from(1.0).unwrap_or_else(|| T::zero()),
24 }
25 }
26}