MCPcopy Create free account
hub / github.com/appdevforall/CodeOnTheGo / generate_data

Function generate_data

subprojects/llama.cpp/tests/test-quantize-fns.cpp:31–35  ·  view source on GitHub ↗

Generate synthetic data

Source from the content-addressed store, hash-verified

29
30// Generate synthetic data
31static void generate_data(float offset, size_t n, float * dst) {
32 for (size_t i = 0; i < n; i++) {
33 dst[i] = 0.1 + 2*cosf(i + offset);
34 }
35}
36
37// Calculate RMSE between two float arrays
38static float array_rmse(const float * a1, const float * a2, size_t n) {

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected