Skip to content

Commit

Permalink
Fix missing includes
Browse files Browse the repository at this point in the history
  • Loading branch information
csparker247 committed Aug 19, 2024
1 parent f1e3fda commit 847a17e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
7 changes: 4 additions & 3 deletions segmentation/src/EnergyMetrics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

#include <cstddef>
#include <iostream>
#include <numeric>

#include "vc/segmentation/lrps/Derivative.hpp"

Expand Down Expand Up @@ -110,8 +111,8 @@ auto EnergyMetrics::WindowedArcLength(const FittedCurve& curve, int windowSize)
}

double sum = 0;
for (std::size_t i = 0; i < curve.size(); ++i) {
sum += EnergyMetrics::LocalWindowedArcLength(curve, i, windowSize);
for (int i = 0; i < curve.size(); ++i) {
sum += LocalWindowedArcLength(curve, i, windowSize);
}
return sum / curve.size();
return sum / static_cast<double>(curve.size());
}
1 change: 1 addition & 0 deletions segmentation/test/EnergyMetricsTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

#include <cstddef>
#include <iostream>
#include <numeric>

#include "vc/segmentation/lrps/EnergyMetrics.hpp"
#include "vc/testing/TestingUtils.hpp"
Expand Down

0 comments on commit 847a17e

Please sign in to comment.