Skip to content

Commit

Permalink
Fix errors from "make doc_pdf"
Browse files Browse the repository at this point in the history
  • Loading branch information
schoi32 committed Oct 23, 2022
1 parent 0998034 commit ab3613a
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 39 deletions.
38 changes: 20 additions & 18 deletions qmcpy/stopping_criterion/cub_qmc_bayes_lattice_g.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,31 +47,33 @@ class CubBayesLatticeG(_CubBayesLDG):
entropy 123456789
spawn_key ()
Adapted from
GAIL cubBayesLattice_g https://github.com/GailGithub/GAIL_Dev/blob/master/Algorithms/IntegrationExpectation/cubBayesLattice_g.m.
Adapted from `GAIL cubBayesLattice_g <https://github.com/GailGithub/GAIL_Dev/blob/master/Algorithms/IntegrationExpectation/cubBayesLattice_g.m>`_.
Reference
[1] Sou-Cheng T. Choi, Yuhan Ding, Fred J. Hickernell, Lan Jiang, Lluis Antoni Jimenez Rugama,
Da Li, Jagadeeswaran Rathinavel, Xin Tong, Kan Zhang, Yizhi Zhang, and Xuan Zhou,
GAIL: Guaranteed Automatic Integration Library (Version 2.3) [MATLAB Software], 2019.
Available from GAIL http://gailgithub.github.io/GAIL_Dev/.
Guarantees:
This algorithm attempts to calculate the integral of function :math:`f` over the
hyperbox :math:`[0,1]^d` to a prescribed error tolerance :math:`\mbox{tolfun} := max(\mbox{abstol},
\mbox{reltol}*| I |)` with a guaranteed confidence level, e.g., :math:`99\%` when alpha= :math:`0.5\%`.
If the algorithm terminates without showing any warning messages and provides
an answer :math:`Q`, then the following inequality would be satisfied:
Guarantee
This algorithm attempts to calculate the integral of function f over the
hyperbox [0,1]^d to a prescribed error tolerance tolfun:= max(abstol,
reltol*| I |)
with guaranteed confidence level, e.g., 99% when alpha=0.5%. If the
algorithm terminates without showing any warning messages and provides
an answer Q, then the following inequality would be satisfied:
Pr(| Q - I | <= tolfun) = 99%.
.. math::
Pr(| Q - I | <= \mbox{tolfun}) = 99\%.
This Bayesian cubature algorithm guarantees for integrands that are considered
to be an instance of a gaussian process that fall in the middle of samples space spanned.
to be an instance of a Gaussian process that falls in the middle of samples space spanned.
Where The sample space is spanned by the covariance kernel parametrized by the scale
and shape parameter inferred from the sampled values of the integrand.
For more details on how the covariance kernels are defined and the parameters are obtained,
please refer to the references below.
References:
[1] Jagadeeswaran Rathinavel and Fred J. Hickernell, Fast automatic Bayesian cubature using lattice sampling.
Stat Comput 29, 1215-1229 (2019). Available from `Springer <https://doi.org/10.1007/s11222-019-09895-9>`_.
[2] Sou-Cheng T. Choi, Yuhan Ding, Fred J. Hickernell, Lan Jiang, Lluis Antoni Jimenez Rugama,
Da Li, Jagadeeswaran Rathinavel, Xin Tong, Kan Zhang, Yizhi Zhang, and Xuan Zhou,
GAIL: Guaranteed Automatic Integration Library (Version 2.3) [MATLAB Software], 2019.
Available from `GAIL <http://gailgithub.github.io/GAIL_Dev/>`_.
"""

def __init__(self, integrand, abs_tol=1e-2, rel_tol=0,
Expand Down Expand Up @@ -219,4 +221,4 @@ def _shift_inv_kernel(self, xun, order, theta, avoid_cancel_error, kern_type, de

return vec_lambda, vec_lambda_ring, lambda_factor

class CubQMCBayesLatticeG(CubBayesLatticeG): pass
class CubQMCBayesLatticeG(CubBayesLatticeG): pass
42 changes: 21 additions & 21 deletions qmcpy/stopping_criterion/cub_qmc_bayes_net_g.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,34 +47,34 @@ class CubBayesNetG(_CubBayesLDG):
entropy 123456789
spawn_key ()
Adapted from
GAIL cubBayesNet_g https://github.com/GailGithub/GAIL_Dev/blob/master/Algorithms/IntegrationExpectation/cubBayesNet_g.m.
Adapted from `GAIL cubBayesNet_g <https://github.com/GailGithub/GAIL_Dev/blob/master/Algorithms/IntegrationExpectation/cubBayesNet_g.m>`_.
Guarantee:
This algorithm attempts to calculate the integral of function :math:`f` over the
hyperbox :math:`[0,1]^d` to a prescribed error tolerance :math:`\mbox{tolfun} := max(\mbox{abstol},
\mbox{reltol}*| I |)` with a guaranteed confidence level, e.g., :math:`99\%` when alpha= :math:`0.5\%`.
If the algorithm terminates without showing any warning messages and provides
an answer :math:`Q`, then the following inequality would be satisfied:
Reference
[1] Sou-Cheng T. Choi, Yuhan Ding, Fred J. Hickernell, Lan Jiang, Lluis Antoni Jimenez Rugama,
Da Li, Jagadeeswaran Rathinavel, Xin Tong, Kan Zhang, Yizhi Zhang, and Xuan Zhou,
GAIL: Guaranteed Automatic Integration Library (Version 2.3) [MATLAB Software], 2019.
Available from GAIL http://gailgithub.github.io/GAIL_Dev/.
Guarantee
This algorithm attempts to calculate the integral of function f over the
hyperbox [0,1]^d to a prescribed error tolerance
tolfun:= max(abstol, reltol*| I |)
with guaranteed confidence level, e.g., 99% when alpha=0.5%. If the
algorithm terminates without showing any warning messages and provides
an answer Q, then the following inequality would be satisfied:
Pr(| Q - I | <= tolfun) = 99%.
.. math::
Pr(| Q - I | <= \mbox{tolfun}) = 99\%.
This Bayesian cubature algorithm guarantees for integrands that are considered
to be an instance of a gaussian process that fall in the middle of samples space spanned.
to be an instance of a Gaussian process that falls in the middle of samples space spanned.
Where The sample space is spanned by the covariance kernel parametrized by the scale
and shape parameter inferred from the sampled values of the integrand.
For more details on how the covariance kernels are defined and the parameters are obtained,
please refer to the references below.
References:
[1] Jagadeeswaran Rathinavel, Fast automatic Bayesian cubature using matching kernels and designs,
PhD thesis, Illinois Institute of Technology, 2019.
[2] Sou-Cheng T. Choi, Yuhan Ding, Fred J. Hickernell, Lan Jiang, Lluis Antoni Jimenez Rugama,
Da Li, Jagadeeswaran Rathinavel, Xin Tong, Kan Zhang, Yizhi Zhang, and Xuan Zhou,
GAIL: Guaranteed Automatic Integration Library (Version 2.3) [MATLAB Software], 2019.
Available from `GAIL <http://gailgithub.github.io/GAIL_Dev/>`_.
"""

def __init__(self, integrand, abs_tol=1e-2, rel_tol=0,
Expand Down Expand Up @@ -244,4 +244,4 @@ def fwht_inplace(self, n, src):

class CubBayesSobolG(CubBayesNetG): pass
class CubQMCBayesSobolG(CubBayesNetG): pass
class CubQMCBayesNetG(CubBayesNetG): pass
class CubQMCBayesNetG(CubBayesNetG): pass

0 comments on commit ab3613a

Please sign in to comment.