record Weighted : (Type -> Type) -> Type -> Type Execute the program using the prior distribution, while accumulating likelihood.
Totality: total
Visibility: public export
Constructor: MkWeighted : StateT (Log Double) m a -> Weighted m a
Projection: .runWeighted' : Weighted m a -> StateT (Log Double) m a
Hints:
Monad m => Applicative (Weighted m) Functor m => Functor (Weighted m) Monad m => Monad (Weighted m) Monad m => MonadCond (Weighted m) MonadSample m => MonadInfer (Weighted m) MonadSample m => MonadSample (Weighted m) MonadTrans Weighted
.runWeighted' : Weighted m a -> StateT (Log Double) m a- Visibility: public export
runWeighted' : Weighted m a -> StateT (Log Double) m a- Visibility: public export
runWeighted : Weighted m a -> m (Log Double, a) Obtain an explicit value of the likelihood for a given value
Visibility: public exportprior : Functor m => Weighted m a -> m a Compute the sample and discard the weight.
This operation introduces bias.
Visibility: export Compute the weight and discard the sample.
Visibility: exportwithWeight : Monad m => m (Log Double, a) -> Weighted m a Embed a random variable with explicitly given likelihood
Visibility: exportflatten : Monad m => Weighted (Weighted m) a -> Weighted m a Combine weights from two different levels.
Visibility: exportapplyWeight : MonadCond m => Weighted m a -> m a Use the weight as a factor in the transformed monad.
Visibility: exporthoist : (m x -> n x) -> Weighted m a -> Weighted n a Apply a transformation to the transformed monad.
Visibility: export