-
Notifications
You must be signed in to change notification settings - Fork 92
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
robust method won't work with verbose=True #530
Comments
That is really interesting, can you share the data that reproduces this? Does it happen consistently? |
The data comes from the package alchemtest, you can just pip install it.
|
Thanks! (I wasn't playing enough attention and just assumed the pandas data frame came from disk or something) |
Just happened to me and digging a bit it's fixed changing the following line in mbar.py: uzero = u_kn[k, indices] - u_kn[l, indices] to uzero = u_kn.iloc[k, indices] - u_kn.iloc[l, indices] because k, l and indices are 0-based indices coming from the execution of the builtin range() and np.arange() and not values from the index or columns of u_kn. |
I'd be a little careful about changing lines in pymbar without checking effects on everything else. More likely to be something off with the way that alchemlyb is passing data into pymbar? |
Let me be more precise. pymbar doesn't used pandas, so if it's a pandas error, it has to do with what is being passed into pymbar, i.e. something weird with the way the pandas dataframe is being interpreted as a numpy array as pymbar, which is not really a pymbar error, since it's expecting a numpy array - it's an issue with the way pandas are being cast as numpy arrays. |
I see. That's easy to solve then I shall just convert this to a numpy array. |
But it is still weird why would this only happen when verbose=True |
That whole block is inside an |
I see. Then casting the input to numpy array should be good. |
works but
Gives
The text was updated successfully, but these errors were encountered: