Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ift
NIFTy
Commits
39a06b44
Commit
39a06b44
authored
Jan 24, 2019
by
Philipp Arras
Browse files
Docs
parent
6b5818dc
Changes
2
Hide whitespace changes
Inline
Side-by-side
nifty5/library/inverse_gamma_operator.py
View file @
39a06b44
...
...
@@ -26,7 +26,7 @@ from ..sugar import makeOp
class
InverseGammaOperator
(
Operator
):
"""
Operator which t
ransforms a Gaussian into an inverse gamma distribution.
"""
T
ransforms a Gaussian into an inverse gamma distribution.
The pdf of the inverse gamma distribution is defined as follows:
...
...
nifty5/operators/energy_operators.py
View file @
39a06b44
...
...
@@ -95,7 +95,7 @@ class QuadraticFormOperator(EnergyOperator):
class
GaussianEnergy
(
EnergyOperator
):
"""C
lass for energies of fields with Gaussian probability distributio
n.
"""C
omputes a negative-log Gaussia
n.
Represents up to constants in :math:`m`:
...
...
@@ -162,8 +162,8 @@ class GaussianEnergy(EnergyOperator):
class
PoissonianEnergy
(
EnergyOperator
):
"""C
lass for
likelihood Hamiltonians of expected count field constrained
by
Poissonian count data.
"""C
omputes
likelihood Hamiltonians of expected count field constrained
by
Poissonian count data.
Represents up to an f-independent term :math:`log(d!)`:
...
...
@@ -200,8 +200,7 @@ class PoissonianEnergy(EnergyOperator):
class
InverseGammaLikelihood
(
EnergyOperator
):
"""This describes the negative log-likelihood of the inverse
gamma distribution.
"""Computes the negative log-likelihood of the inverse gamma distribution.
It negative log-pdf(x) is given by
...
...
@@ -341,7 +340,7 @@ class StandardHamiltonian(EnergyOperator):
class
AveragedEnergy
(
EnergyOperator
):
"""Averages an energy over samples
"""Averages an energy over samples
.
Parameters
----------
...
...
@@ -351,15 +350,15 @@ class AveragedEnergy(EnergyOperator):
Set of residual sample points to be added to mean field for
approximate estimation of the KL.
Note
----
Having symmetrized residual samples, with both v_i and -v_i being
present, ensures that the distribution mean is exactly represented.
Notes
-----
- Having symmetrized residual samples, with both :math:`v_i` and
:math:`-v_i` being present, ensures that the distribution mean is
exactly represented.
:class:`AveragedEnergy(h)` approximates
:math:`
\\
left< H(f)
\\
right>_{G(f-m,D)}` if the residuals
:math:`f-m` are drawn from a Gaussian distribution with covariance
:math:`D`.
- :class:`AveragedEnergy(h)` approximates
:math:`
\\
left< H(f)
\\
right>_{G(f-m,D)}` if the residuals :math:`f-m`
are drawn from a Gaussian distribution with covariance :math:`D`.
"""
def
__init__
(
self
,
h
,
res_samples
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment