Skip to content

Conversation

@franckgaga
Copy link
Member

@franckgaga franckgaga commented Apr 17, 2025

Some matrix products were computed on normal dense matrix using M.data instead of M, in which M isa Hermitian. It was because of a bug in LinearAlgebra that produces a dynamic dispatch (JuliaLang/julia#53951). This bug is solved now so it's no longer needed.

It's also not the best idea for the numerical stability since covariance matrices are Hermitians, and the intermediate matrices in the computation should all be Hermitians also for the consistency.

@1-Bart-1 This branch solve the cholesky! issue in your exemple on my computer. Give it a try.

I did not try the Joseph form equation here since the .data was just bad for the numerical stability, and simply removing that solve the problem. After I merge these changes, If you have any other similar issue with a new piece of code, send it to me. I will try the Joseph form on it to see if it helps.

related to #98

Some matrix products were computed on normal dense matrix with `M.data` instead of `Hermitian`. It was because of a bug in `LinearAlgebra` that created a dynamic dispatch. This bug is resolved now so it's no longer needed.
@1-Bart-1
Copy link

1-Bart-1 commented Apr 18, 2025

Amazing, thanks for the help! The example works on my computer now.

@franckgaga
Copy link
Member Author

franckgaga commented Apr 18, 2025

P.s. the CI fails but everything pass locally on my side. I'm investigating on this.

franckgaga referenced this pull request in JuliaControl/ControlSystems.jl Apr 18, 2025
@franckgaga franckgaga merged commit 4511057 into main Apr 19, 2025
3 of 4 checks passed
@franckgaga
Copy link
Member Author

The next release will incorporate this change.

@franckgaga franckgaga deleted the debug_KF branch April 19, 2025 17:53
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.88%. Comparing base (2045d9a) to head (f60fcc9).
Report is 11 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #189   +/-   ##
=======================================
  Coverage   98.88%   98.88%           
=======================================
  Files          25       25           
  Lines        4205     4205           
=======================================
  Hits         4158     4158           
  Misses         47       47           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants