Closed corinwagen closed 10 months ago
@corinwagen I had the same issue with the ensemble models, but managed to get it work by swapping to a single model (e.g. models/aimnet2_wb97m-d3_1.jpt
)
Thanks, appreciate it - is the ensemble significantly more accurate, or are the single models a decent replacement?
The compiled ensembled models return forces, but do not keep graph to calculate higher order derivatives. This is for computational efficiency. I added the code of ensembled modes, if you need Hessian, you can re-compile ensemble with detach=False
.
https://github.com/isayevlab/AIMNet2/commit/fc671d8747ccb84a8630339bc59fc99fbbfba5a5
Hey all, congrats on a fantastic paper. I'm trying out some of the scripts included here, but I'm struggling to get autograd to work (for gradient/Hessian)...
Here is my minimal reproducible example, using water as a test case:
Energy works fine, but I get the following error for torch.autograd.grad():
This is confusing, because when I print
_in
before the energy call, it seems to require grad...Here's the result of
conda list
- I also tried the latest version of Pytorch w/ Python 3.11 and I got the same error:I'm new to PyTorch, so let me know what I'm doing wrong!