Skip to content

Commit

Permalink
Update util.py
Browse files Browse the repository at this point in the history
coercing `param_value` `int` to `float` allows unit tests to pass on the pyciemss side.
  • Loading branch information
djinnome authored Oct 1, 2024
1 parent 146205a commit 3120777
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mira/sources/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ def parameter_to_mira(parameter, param_symbols=None) -> Parameter:
processed_distr_parameters = {}
for param_key, param_value in distr_json.get("parameters", {}).items():
if isinstance(param_value, float) or isinstance(param_value, int):
processed_distr_parameters[param_key] = param_value
processed_distr_parameters[param_key] = float(param_value)
elif isinstance(param_value, str):
processed_distr_parameters[param_key] = \
safe_parse_expr(param_value)
Expand Down

0 comments on commit 3120777

Please sign in to comment.