Using methods from ReactiveMP

In the Julia programming language (in contrast to Python for example) the most common way of loading a module is:

using ReactiveMP

A nice explanation about how modules/packages work in Julia can be found in the official documentation.

In a nutshell, Julia automatically resolves all name collisions and there is no a lot of benefit of importing specific names, e.g.:

import ReactiveMP: mean

One of the reasons for that is that Julia uses multiple-dispatch capabilities to merge names automatically and will indicate (with a warning) if something went wrong or names have unresolvable collisions on types. As a small example of this feature consider the following small import example:

import ReactiveMP: mean as mean_from_reactivemp
import Distributions: mean as mean_from_distributions
import BayesBase: mean as mean_from_bayes_base
mean_from_reactivemp === mean_from_distributions
true
mean_from_reactivemp === mean_from_bayes_base
true

Even though we import mean function from different packages they actually refer to the same object. Worth noting that this is not always the case - Julia will print a warning in case it finds unresolvable conflicts and usage of such functions will be disallowed unless user import them specifically. Read more about this in the section of the Julia's documentation.

# It is easier to let Julia resolve names automatically
# Julia will not overwrite `mean` that is coming from both packages
using ReactiveMP, Distributions, BayesBase, ExponentialFamily
mean(Normal(0.0, 1.0)) # `Normal` is an object from `Distributions.jl`
0.0
mean(NormalMeanVariance(0.0, 1.0)) # `NormalMeanVariance` is an object from `ReactiveMP.jl`
0.0

List of available methods

Below you can find a list of exported methods from ReactiveMP.jl. All methods (even private) can be always accessed with ReactiveMP. prefix, e.g ReactiveMP.mean.

Note

Some exported names are (for legacy reasons) intended for private usage only. As a result some of these methods do not have a proper associated documentation with them. We constantly improve ReactiveMP.jl library and continue to add better documentation for many exported methods, but a small portion of these methods could be removed from this list in the future.

foreach(println, names(ReactiveMP))
@average_energy
@call_marginalrule
@call_rule
@logscale
@marginalrule
@node
@rule
AND
AR
ARMeta
ARsafe
ARunsafe
AbstractApproximationMethod
AbstractFormConstraint
AbstractMessage
AbstractPipelineStage
AbstractVariable
Adam
AdditiveCouplingLayer
AddonDebug
AddonLogScale
AddonMemory
AsyncPipelineStage
Autoregressive
AverageEnergy
BIFM
BIFMHelper
BIFMMeta
CTMeta
CTransition
CVI
CVIProjection
CompanionMatrix
CompanionMatrixTransposed
CompiledFlowModel
CompositeFormConstraint
CompositePipelineStage
ConstVariable
ContinuousTransition
ContinuousTransitionMeta
CustomProdStrategy
DataVariable
DataVariableActivationOptions
DefaultFunctionalDependencies
DeferredMessage
DeltaFn
DeltaFnNode
DeltaMeta
Deterministic
DifferentialEntropy
DiscontinuePipelineStage
EmptyPipelineStage
FactorBoundFreeEnergy
FactorNode
Flow
FlowMeta
FlowModel
FoldLeftProdStrategy
FoldRightProdStrategy
FormConstraintCheckEach
FormConstraintCheckLast
FormConstraintCheckPickDefault
ForwardDiffGrad
GCV
GCVMetadata
GammaMixture
GammaMixtureNode
GaussHermiteCubature
GaussLaguerreQuadrature
GaussianMixture
GaussianMixtureNode
HalfNormal
IMPLY
ImportanceSamplingApproximation
IncludeAll
InputLayer
InverseWishart
LaplaceApproximation
Linearization
LoggerPipelineStage
Marginal
Marginalisation
Message
Mixture
MixtureNode
MomentMatching
MvNormalMeanScalePrecision
NOT
NodeFunctionRuleFallback
NormalMixture
NormalMixtureNode
OR
PermutationLayer
PermutationMatrix
PlanarFlow
Poisson
Probit
ProbitMeta
ProdCVI
RadialFlow
RandomVariable
RandomVariableActivationOptions
ReactiveMP
RequireEverythingFunctionalDependencies
RequireMarginalFunctionalDependencies
RequireMessageFunctionalDependencies
ScheduleOnPipelineStage
SkipClamped
SkipClampedAndInitial
SkipInitial
SoftDot
StandardBasisVector
Stochastic
Transition
UT
Uninformative
Unscented
UnscentedTransform
UnspecifiedFormConstraint
VariableBoundEntropy
apply_pipeline_stage
approximation_name
approximation_short_name
as_marginal
as_message
compile
constrain_form
constvar
datavar
default_form_check_strategy
default_prod_constraint
degree
diageye
dot
factorisation
factornode
functional_dependencies
functionalform
getapproximation
getdata
getinterfaces
getlayers
getlogscale
getmarginal
getmarginals
getmemory
getmodel
getprediction
getpredictions
ghcubature
huge
is_clamped
is_initial
isdeterministic
isstochastic
laplace
localmarginalnames
localmarginals
marginalrule
nr_params
randomvar
rule
schedule_updates
score
sdtype
setmarginal!
setmarginals!
setmessage!
setmessages!
skipindex
softdot
srcubature
tiny
update!