deepmd-kit icon indicating copy to clipboard operation
deepmd-kit copied to clipboard

[BUG] Changing `nlayer` lead no error report while fine-tuning

Open QuantumMisaka opened this issue 5 months ago • 3 comments

Bug summary

When changing the nlayer parameter in input.json while fine-tune the DPA310-3M pre-trained model, deepmd-kit will throw no error and process the training for the model of this nlayer. I have no idea that it is correct or wrong. In my knowledge the nlayer should keep the same.

DeePMD-kit Version

3.1.0

Backend and its version

PyTorch

How did you download the software?

Offline packages

Input Files, Running Commands, Error Log, etc.

input is the same as any dpa3-fine-tuning input.json, only the nlayer parameter is changed

Steps to Reproduce

change the nlayer of input.json for dpa3 fine-tuning, and perform this fine-tuning

Further Information, Files, and Links

No response

QuantumMisaka avatar Jul 26 '25 09:07 QuantumMisaka

The configuration of the descriptor in input.json is dropped. There should be a clear message, though, if there is not.

njzjz avatar Jul 27 '25 09:07 njzjz

@iProzd Do we have such a warning?

njzjz avatar Jul 27 '25 09:07 njzjz

It seems that now only the missing keys in the checkpoint will through an error, but not for the extra keys (it is the case if you set a smaller nlayer). A warning should be added.

iProzd avatar Jul 28 '25 10:07 iProzd