Skip to content

← bayesian package

MultivariateNormalApprox

A multivariate normal variational approximation.

This approximation is the simplest that can capture correlations between variables in the posterior distribution, but it is not robust as the simple mean-field approximation (which uses a diagonal normal distribution) and more computationally costly. Particularly in high dimensions, this family of distributions may be challenging to fit, and you may need to experiment with optimizers to avoid issues. For higher-dimensional data, it is recommended to consider using the low-rank approximation, which can capture the dominant correlation structure in the data; see the max rank parameter for this. More Info... Version 1.0.0

Ports/Properties

initial_scale

The initial standard deviation for the variational distribution.

  • verbose name: Initial Scale
  • default value: 0.1
  • port type: FloatPort
  • value type: float (can be None)

max_rank

Optionally the maximum rank of the distribution, in which case a low-rank variant will be used. If this is not set, the full-rank variant will be used. Good values may be 5-10 or as much as 20 for very high-dimensional posterior distributions. One may also consider a rank that is on the order of log(N) where N is the dimensionality of the posterior distribution (sum of dimensions of all latent variables).

  • verbose name: Maximum Rank
  • default value: None
  • port type: IntPort
  • value type: int (can be None)

set_breakpoint

Set a breakpoint on this node. If this is enabled, your debugger (if one is attached) will trigger a breakpoint.

  • verbose name: Set Breakpoint (Debug Only)
  • default value: False
  • port type: BoolPort
  • value type: bool (can be None)

metadata

User-definable meta-data associated with the node. Usually reserved for technical purposes.

  • verbose name: Metadata
  • default value: {}
  • port type: DictPort
  • value type: dict (can be None)