Giter Site home page Giter Site logo

data_efficiency_in_iaps's People

Contributors

jvita avatar

Stargazers

 avatar

Watchers

 avatar

data_efficiency_in_iaps's Issues

Force calculation failing for Nequip due to no grad function

I am attempting to generate a loss landscape for a Nequip model I have trained by running "ip_explorer/landscape/main.py". When ip_explorer/models/nequip.py attempts to make a forward pass through the network in the compute_loss function, the following error arises: "RuntimeError: element 0 of tensors does not require grad and does not have a grad_fn".

This is occurring because the "total_energy" output field of the model for some reason did not record the gradient history of the forward pass. Therefore when we try to differentiate the energy with torch.autograd.grad to calculate forces, there is an error.

I have verified that this same model can correctly calculate forces and perform MD simulation in my own codebases.

The command I am running is this:
python main.py
--num-nodes=1
--save-dir /home/sanjeevr/implicit-md/landscapes
--model-type=nequip --database-path=/home/sanjeevr/MDsim/MODELPATH/nequip/md17-aspirin_10k_nequip
--model-path=/home/sanjeevr/MDsim/MODELPATH/nequip/md17-aspirin_10k_nequip
--landscape-type=plane
--no-compute-initial-losses
--steps=10

Any ideas on why this may be occurring? I think it could be due to the way the model is being wrapped in the SimpleModelWrapper. Could it be that I'm not passing in other necessary command line arguments?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.