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<Arc<dyn Error + Send + Sync>>,
}
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<Arc<dyn Error + Send + Sync>>
Trait Implementations§
Source§impl Clone for DivergenceInfo
impl Clone for DivergenceInfo
Source§fn clone(&self) -> DivergenceInfo
fn clone(&self) -> DivergenceInfo
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for DivergenceInfo
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more