Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
xiki-tempula committed Jun 6, 2023
1 parent 89f855f commit 9cf90c7
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,11 @@ Enhancements

Fixes
- Fix the case where visualisation.plot_convergence would fail when the final
error is NaN (issue #318, PR#319).
error is NaN (issue #318, PR#319).

DeprecationWarning
- The default MBAR error estimator will change from analytic to bootstrap
(issue #320, PR#322).


06/04/2023 xiki-tempula
Expand Down
2 changes: 1 addition & 1 deletion src/alchemlyb/tests/test_workflow_ABFE.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ def test_single_estimator_mbar(self, workflow, monkeypatch):

def test_mbar_n_bootstraps(self, workflow, monkeypatch):
monkeypatch.setattr(workflow, "estimator", dict())
workflow.estimate(estimators="MBAR", n_bootstraps=50)
workflow.estimate(estimators="MBAR", n_bootstraps=2)
summary = workflow.generate_result()
bootstrap_error = summary["MBAR_Error"]["Stages"]["TOTAL"]
monkeypatch.setattr(workflow, "estimator", dict())
Expand Down
4 changes: 4 additions & 0 deletions src/alchemlyb/workflows/abfe.py
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,10 @@ def estimate(self, estimators=("MBAR", "BAR", "TI"), **kwargs):
for estimator in estimators:
if estimator == "MBAR":
logger.info("Run MBAR estimator.")
warnings.warn(
"From 2.2.0, n_bootstraps=50 will be the default for estimating MBAR error.",
DeprecationWarning,
)
self.estimator[estimator] = MBAR(**kwargs).fit(u_nk)
elif estimator == "BAR":
logger.info("Run BAR estimator.")
Expand Down

0 comments on commit 9cf90c7

Please sign in to comment.