Skip to content

Commit

Permalink
Fix save_history bug
Browse files Browse the repository at this point in the history
  • Loading branch information
me-pic committed Aug 22, 2024
1 parent 5228f8a commit 7f8c14e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion peakdet/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,10 @@ def wrapper(data, *args, **kwargs):
# the way there
provided = {k: params[k] for k in sorted(params.keys()) if k not in ignore}
for k, v in provided.items():
if isinstance(v, list):
provided[k] = np.array(v).tolist()
if hasattr(v, "tolist"):
provided[k] = v.tolist()

# append everything to data instance history
data._history += [(name, provided)]

Expand Down

0 comments on commit 7f8c14e

Please sign in to comment.