Skip to content

Commit

Permalink
Update writting to parameter.txt with categorical values
Browse files Browse the repository at this point in the history
  • Loading branch information
xjules committed Dec 10, 2024
1 parent a670fcb commit af2fb0f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/ert/enkf_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,10 @@ def _value_export_txt(
with path.open("w") as f:
for key, param_map in values.items():
for param, value in param_map.items():
print(f"{key}:{param} {value:g}", file=f)
if isinstance(value, (int, float)):
print(f"{key}:{param} {value:g}", file=f)
else:
print(f"{key}:{param} {value}", file=f)


def _value_export_json(
Expand Down

0 comments on commit af2fb0f

Please sign in to comment.