MCPcopy Create free account
hub / github.com/andrewkchan/deepseek.cpp / arrayEquals

Function arrayEquals

src/test.cpp:17–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15}
16
17bool arrayEquals(const std::vector<float>& a, const std::vector<float>& b, float epsilon = 1e-4) {
18 if (a.size() != b.size()) {
19 return false;
20 }
21 for (size_t i = 0; i < a.size(); i++) {
22 if (!floatEquals(a[i], b[i], epsilon)) {
23 return false;
24 }
25 }
26 return true;
27}
28
29void assertArrayEquals(const std::vector<float>& actual, const std::vector<float>& expected, const std::string& message, float epsilon = 1e-4) {
30 if (!arrayEquals(actual, expected, epsilon)) {

Callers 1

assertArrayEqualsFunction · 0.85

Calls 1

floatEqualsFunction · 0.85

Tested by

no test coverage detected