Skip to content

Commit

Permalink
Number of equilibrium simulations and statistical inefficiency in rea…
Browse files Browse the repository at this point in the history
…l time output. (#572)
  • Loading branch information
ijpulidos authored Apr 12, 2022
1 parent 6dacd43 commit d16b9cc
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion openmmtools/multistate/multistatesampler.py
Original file line number Diff line number Diff line change
Expand Up @@ -1527,6 +1527,8 @@ def _offline_analysis(self):
try: # Trap errors for MBAR being under sampled and the W_nk matrix not being normalized correctly
mbar = analysis.mbar
free_energy, err_free_energy = analysis.get_free_energy()
n_equilibration_iterations = analysis.n_equilibration_iterations
statistical_inefficiency = analysis.statistical_inefficiency
except ParameterError as e:
# We don't update self._last_err_free_energy here since if it
# wasn't below the target threshold before, it won't stop MultiStateSampler now.
Expand Down Expand Up @@ -1570,7 +1572,9 @@ def _offline_analysis(self):
"percent_complete": self._iteration*100/self.number_of_iterations,
"mbar_analysis": {"free_energy_in_kT": float(free_energy),
"standard_error_in_kT": float(self._last_err_free_energy),
"number_of_uncorrelated_samples": float(analysis._equilibration_data[-1])
"number_of_uncorrelated_samples": float(analysis._equilibration_data[-1]),
"n_equilibrium_iterations": int(n_equilibration_iterations),
"statistical_inefficiency": float(statistical_inefficiency)
},
"timing_data": self._timing_data
}
Expand Down

0 comments on commit d16b9cc

Please sign in to comment.