Type checking method parameters
Currently only algorithms have type
in parameter descriptions (in defparam.py
). Calculators do not have it. The same applies to their default values. The only information about calculators is units and is currently stored in units.py
. This should move to defparam.py
, should be extended with default values and types. Then in amml.AMMLMethod.__init__
there should be a systematic run-time type check of the parameters. Tests have to be added to cover the type checking code.
The lack of type checking causes various crashes due to non-handled exceptions if a parameter is entered inadvertently with wrong type.
Edited by Ivan Kondov