Struct nuts_rs::DivergenceInfo
source · pub struct DivergenceInfo {
pub start_momentum: Option<Box<[f64]>>,
pub start_location: Option<Box<[f64]>>,
pub start_gradient: Option<Box<[f64]>>,
pub end_location: Option<Box<[f64]>>,
pub energy_error: Option<f64>,
pub end_idx_in_trajectory: Option<i64>,
pub start_idx_in_trajectory: Option<i64>,
pub logp_function_error: Option<Box<dyn Error + Send>>,
}
Expand description
Details about a divergence that might have occured during sampling
There are two reasons why we might observe a divergence:
- The integration error of the Hamiltonian is larger than a cutoff value or nan.
- The logp function caused a recoverable error (eg if an ODE solver failed)
Fields§
§start_momentum: Option<Box<[f64]>>
§start_location: Option<Box<[f64]>>
§start_gradient: Option<Box<[f64]>>
§end_location: Option<Box<[f64]>>
§energy_error: Option<f64>
§end_idx_in_trajectory: Option<i64>
§start_idx_in_trajectory: Option<i64>
§logp_function_error: Option<Box<dyn Error + Send>>
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for DivergenceInfo
impl Send for DivergenceInfo
impl !Sync for DivergenceInfo
impl Unpin for DivergenceInfo
impl !UnwindSafe for DivergenceInfo
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more