Extra keyword arguments
At least in v0.4 (and probably v0.5), if a user mis-spells a keyword argument no error is raised and the user could easily think that the code was doing what they wanted. This happened when I used the new (v0.5) keyword model
instead of the v0.4 keyword regression
. When I specified model=NeuralNetwork(...)
it does not raise an error, and when it does not see anything specified for regression
it just sets it to its default, which happens to be a neural network. So it appears to run normally, except for any parameters I had specified to the NeuralNetwork are ignored.
This behavior comes from our passing **kwargs
to the ase.calculators.Calculator
object that Amp
inherits from. ASE takes these kwargs and puts them in its parameters
dictionary.
Do we actually ever need ASE to add random keyword arguments to a parameters dictionary? Perhaps we could solve this by just not passing **kwargs
to Calculator
?
Comments (3)
-
-
reporter Solved in v0.5 with commit 6ffdeb2.
-
reporter - changed status to resolved
- Log in to comment
This seems to be a problem with
Calculator
object. That is I can doand it will raise no error. Should we remove
**kwargs
fromAmp
input arguments?