-
Notifications
You must be signed in to change notification settings - Fork 484
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
[BUG] LookupError: No gradient defined for operation'ProdEnvMatA' #3724
Comments
you may need to import deepmd defined ops. deepmd-kit/deepmd/train/trainer.py Lines 23 to 24 in f8a0b31
|
I solved the issue with the updated version of 3.0.0a using Pytorch. Two lines are modified:
and
|
This issue is similar to #2594. To use deepmd-kit/deepmd/tf/op/_gelu.py Lines 30 to 32 in ee47e75
|
Bug summary
I modified the 'deepmd/train/trainer.py' file, and added some codes for gradient:
Then I run
CUDA_VISIBLE_DEVICES=0 dp train --restart model.ckpt input.json
for the simple CH4 case, it outputs an error:No gradient defined for operation'ProdEnvMatA'
DeePMD-kit Version
2.2.10
Backend and its version
TensorFlow v2.15.0
How did you download the software?
pip
Input Files, Running Commands, Error Log, etc.
The complete code for trainer.py is:
and the error code:
The text was updated successfully, but these errors were encountered: