Skip to content

Commit

Permalink
Update SKMeans.hpp
Browse files Browse the repository at this point in the history
Correct normalization dimension
  • Loading branch information
weefuzzy authored Nov 22, 2024
1 parent c76186c commit 00061f4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/algorithms/public/SKMeans.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class SKMeans : public KMeans
using namespace _impl;
assert(!mTrained || (dataset.pointSize() == mDims && mK == k));
MatrixXd dataPoints =
asEigen<Matrix>(dataset.getData()).colwise().normalized();
asEigen<Matrix>(dataset.getData()).rowwise().normalized();
MatrixXd dataPointsT = dataPoints.transpose();
if (mTrained) { mAssignments = assignClusters(dataPointsT);}
else
Expand Down

0 comments on commit 00061f4

Please sign in to comment.