From c8ac9ebfff1259f75517b2449b8bfd579ef3c927 Mon Sep 17 00:00:00 2001 From: Bradley J Chambers Date: Mon, 26 Jun 2017 14:52:56 -0400 Subject: [PATCH] Should be computing sample covariance --- pdal/EigenUtils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pdal/EigenUtils.cpp b/pdal/EigenUtils.cpp index 5526107cfd..449435dc11 100644 --- a/pdal/EigenUtils.cpp +++ b/pdal/EigenUtils.cpp @@ -92,7 +92,7 @@ Eigen::Matrix3f computeCovariance(PointView& view, std::vector ids) k++; } - return A * A.transpose(); + return A * A.transpose() / (ids.size()-1); } uint8_t computeRank(PointView& view, std::vector ids, double threshold)