Skip to content

Commit

Permalink
[fix] Corrected an error message (#257)
Browse files Browse the repository at this point in the history
Co-authored-by: Simon Kuberski <[email protected]>
  • Loading branch information
s-kuberski and Simon Kuberski authored Feb 13, 2025
1 parent 7eabd68 commit 6ed6ce6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pyerrors/fits.py
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ def func_b(a, x):
if len(key_ls) > 1:
for key in key_ls:
if np.asarray(yd[key]).shape != funcd[key](np.arange(n_parms), xd[key]).shape:
raise ValueError(f"Fit function {key} returns the wrong shape ({funcd[key](np.arange(n_parms), xd[key]).shape} instead of {xd[key].shape})\nIf the fit function is just a constant you could try adding x*0 to get the correct shape.")
raise ValueError(f"Fit function {key} returns the wrong shape ({funcd[key](np.arange(n_parms), xd[key]).shape} instead of {np.asarray(yd[key]).shape})\nIf the fit function is just a constant you could try adding x*0 to get the correct shape.")

if not silent:
print('Fit with', n_parms, 'parameter' + 's' * (n_parms > 1))
Expand Down

0 comments on commit 6ed6ce6

Please sign in to comment.