Skip to content

Commit

Permalink
Merge pull request #29 from kb-press/silence-lstsq-warning
Browse files Browse the repository at this point in the history
Pass rcond to lstsq to silence warning
  • Loading branch information
sixpearls committed Jun 23, 2019
2 parents a275698 + 142dba5 commit e2b879d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ndsplines/ndsplines.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ def make_lsq_spline(x, y, knots, orders, w=None, check_finite=True):

# TODO: implemnet weighting matrix, which I think is just matrix multiply by diag(w) on left for both observation matrix and output.

lsq_coefficients, lsq_residuals, rank, singular_values = np.linalg.lstsq(observation_matrix, y.T)
lsq_coefficients, lsq_residuals, rank, singular_values = np.linalg.lstsq(observation_matrix, y.T, rcond=None)
temp_spline.coefficients = lsq_coefficients.T.reshape((mdim,) + knot_shapes )

# TODO: I think people will want this matrix, is there a better way to give this to a user?
Expand Down

0 comments on commit e2b879d

Please sign in to comment.