Means, weights and covariances are similar in both implementations
Actual behaviour
Means and weights are similar in both implementations, but Rust's covariances are around 2/3 the size of Python's. I have observed this quite consistently.
Hi, thanks for the detailed report and good catch! The covariances were not updated during the iterative process. I've just open a PR to fix this issue.
There is a significant discrepancy between the covariance resulting from Gassian mixture calculations in
linfa-clustering
andscikit-learn
.To reproduce
Windows 10 Business, version 21H2, build 19044.3086
Python
Environment:
Code:
Output:
Rust
Environment: Cargo.lock.txt Cargo.toml.txt
main.rs
Output:
Expected behaviour
Means, weights and covariances are similar in both implementations
Actual behaviour
Means and weights are similar in both implementations, but Rust's covariances are around 2/3 the size of Python's. I have observed this quite consistently.