CenteredRBMs.CenteredRBM
— MethodCenteredRBM(visible, hidden, w)
Creates a centered RBM, with offsets initialized to zero.
CenteredRBMs.CenteredRBM
— MethodCenteredRBM(rbm, λv, λh)
Creates a centered RBM, with offsets λv
(visible) and λh
(hidden). See http://jmlr.org/papers/v17/14-237.html for details. The resulting model is not equivalent to the original rbm
, unless λv = 0
and λh = 0
.
RestrictedBoltzmannMachines.RBM
— MethodRBM(centered_rbm::CenteredRBM)
Returns an (uncentered) RBM
which neglects the offsets of centered_rbm
. The resulting model is not equivalent to the original centered_rbm
. To construct an equivalent model, use the function uncenter(centered_rbm)
instead (see uncenter
). Shares parameters with centered_rbm
.
CenteredRBMs.CenteredBinaryRBM
— MethodCenteredBinaryRBM(a, b, w, λv = 0, λh = 0)
Construct a centered binary RBM. The energy function is given by:
\[E(v,h) = -a' * v - b' * h - (v - λv)' * w * (h - λh)\]
CenteredRBMs.center!
— Methodcenter!(centered_rbm, offset_v = 0, offset_h = 0)
Transforms the offsets of centered_rbm
. The transformed model is equivalent to the original one (energies differ by a constant).
CenteredRBMs.center
— Methodcenter(rbm::RBM, offset_v = 0, offset_h = 0)
Constructs a CenteredRBM
equivalent to the given rbm
. The energies assigned by the two models differ by a constant amount,
\[E(v,h) - E_c(v,h) = \sum_{i\mu}w_{i\mu}\lambda_i\lambda_\mu\]
where $E(v,h)$ is the energy assigned by the original rbm
, and $E_c(v,h)$ is the energy assigned by the returned CenteredRBM
.
This is the inverse operation of uncenter
.
To construct a CenteredRBM
that simply includes these offsets, call CenteredRBM(rbm, offset_v, offset_h)
instead.
CenteredRBMs.uncenter
— Methoduncenter(centered_rbm::CenteredRBM)
Constructs an RBM
equivalent to the given CenteredRBM
. The energies assigned by the two models differ by a constant amount,
\[E(v,h) - E_c(v,h) = \sum_{i\mu}w_{i\mu}\lambda_i\lambda_\mu\]
where $E_c(v,h)$ is the energy assigned by centered_rbm
and $E(v,h)$ is the energy assigned by the RBM
constructed by this method.
This is the inverse operation of center
.
To construct an RBM
that simply neglects the offsets, call RBM(centered_rbm)
instead.