Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

making quad iterator info stateless & adding tests #659

Merged

Conversation

mmahsereci
Copy link
Contributor

@mmahsereci mmahsereci commented Mar 10, 2022

In a Nutshell

This PR makes the following changes in quad:

  • Separates better the BQIterInfo and BQState: The former is now simply a container for info concerning the loop iteration. The latter contains the BQ belief.
  • BQIterInfo is now a simple dataclass and also stateless (it wasn't stateless before, and error prone due to inconsistent updating).
  • Tests added for both BQIterInfo and BQState as there were no tests at all before.
  • Some docstring fixes, mostly removing colons as discussed in Long-term global `pylint` ignores #470 (comment)

Detailed Description

This PR will be followed up by changes as in #620 .

Related Issues

Closes #...

@mmahsereci mmahsereci marked this pull request as draft March 10, 2022 18:44
@mmahsereci mmahsereci self-assigned this Mar 10, 2022
@mmahsereci mmahsereci added the quad Issues related to quadrature label Mar 10, 2022
@codecov
Copy link

codecov bot commented Mar 10, 2022

Codecov Report

Merging #659 (ce55cb8) into main (bc699dd) will decrease coverage by 0.00%.
The diff coverage is 97.87%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #659      +/-   ##
==========================================
- Coverage   90.02%   90.01%   -0.01%     
==========================================
  Files         194      194              
  Lines        7337     7343       +6     
  Branches     1159     1159              
==========================================
+ Hits         6605     6610       +5     
  Misses        489      489              
- Partials      243      244       +1     
Impacted Files Coverage Δ
src/probnum/quad/__init__.py 100.00% <ø> (ø)
src/probnum/quad/solvers/policies/_policy.py 100.00% <ø> (ø)
...rc/probnum/quad/solvers/policies/_random_policy.py 100.00% <ø> (ø)
src/probnum/quad/solvers/bayesian_quadrature.py 86.04% <93.33%> (-0.71%) ⬇️
src/probnum/quad/_bayesquad.py 94.44% <100.00%> (ø)
src/probnum/quad/solvers/__init__.py 100.00% <100.00%> (ø)
src/probnum/quad/solvers/bq_state.py 100.00% <100.00%> (ø)
...olvers/stopping_criteria/_bq_stopping_criterion.py 100.00% <100.00%> (ø)
.../quad/solvers/stopping_criteria/_immediate_stop.py 100.00% <100.00%> (ø)
...olvers/stopping_criteria/_integral_variance_tol.py 100.00% <100.00%> (ø)
... and 2 more

@mmahsereci mmahsereci marked this pull request as ready for review March 14, 2022 18:28
@mmahsereci mmahsereci marked this pull request as draft March 24, 2022 11:19
@mmahsereci mmahsereci marked this pull request as ready for review April 4, 2022 09:53
@mmahsereci mmahsereci merged commit 93895f1 into probabilistic-numerics:main Apr 6, 2022
@mmahsereci mmahsereci deleted the mm-bq-state-refactor branch April 6, 2022 16:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
quad Issues related to quadrature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants