[Feat] Introduce checks of the provided inverse matrix for correlated fits (#259)

Co-authored-by: Simon Kuberski <simon.kuberski@cern.ch>
This commit is contained in:
s-kuberski 2025-02-19 18:15:55 +01:00 committed by GitHub
parent 6ed6ce6113
commit 5f5438b563
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 0 deletions

View file

@ -223,6 +223,9 @@ def test_inv_cov_matrix_input_least_squares():
diff_inv_cov_combined_fit.gamma_method()
assert(diff_inv_cov_combined_fit.is_zero(atol=1e-12))
with pytest.raises(ValueError):
pe.least_squares(x_dict, data_dict, fitf_dict, correlated_fit = True, inv_chol_cov_matrix = [corr,chol_inv_keys_combined_fit])
def test_least_squares_invalid_inv_cov_matrix_input():
xvals = []
yvals = []