From ca4aa52f635ba46caf8927591ad13cd4bcbb1fc7 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Wed, 3 Apr 2019 11:07:05 +0200 Subject: dfatool: analytic model getter: Add arg support --- lib/dfatool.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib') diff --git a/lib/dfatool.py b/lib/dfatool.py index 1802acf..8f2e9e6 100755 --- a/lib/dfatool.py +++ b/lib/dfatool.py @@ -1075,6 +1075,8 @@ class AnalyticModel: } def model_getter(name, key, **kwargs): + if 'arg' in kwargs and 'param' in kwargs: + kwargs['param'].extend(map(soft_cast_int, kwargs['arg'])) if key in param_model[name]: param_list = kwargs['param'] param_function = param_model[name][key]['function'] @@ -1450,6 +1452,8 @@ class PTAModel: } def model_getter(name, key, **kwargs): + if 'arg' in kwargs and 'param' in kwargs: + kwargs['param'].extend(map(soft_cast_int, kwargs['arg'])) if key in param_model[name]: param_list = kwargs['param'] param_function = param_model[name][key]['function'] -- cgit v1.2.3