Skip to content

Commit

Permalink
fix(pt): use eval mode in the Python interface
Browse files Browse the repository at this point in the history
Same as deepmodeling#4402

Signed-off-by: Jinzhe Zeng <[email protected]>
  • Loading branch information
njzjz authored Nov 22, 2024
1 parent 7bd2e5a commit d1d59bb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions deepmd/pt/infer/deep_eval.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ def __init__(
self.model_def_script = {}
else:
raise ValueError("Unknown model file format!")
self.dp.eval()
self.rcut = self.dp.model["Default"].get_rcut()
self.type_map = self.dp.model["Default"].get_type_map()
if isinstance(auto_batch_size, bool):
Expand Down

0 comments on commit d1d59bb

Please sign in to comment.