mirror of
https://github.com/multipleof4/lynchmark.git
synced 2026-01-14 08:37:56 +00:00
Docs: Update benchmark results
This commit is contained in:
13
tests/11_geospatial/outputs/x-ai_grok-4.js
Normal file
13
tests/11_geospatial/outputs/x-ai_grok-4.js
Normal file
@@ -0,0 +1,13 @@
|
||||
async function analyzeGPS(readings, boundary) {
|
||||
const turf = await import('https://cdn.jsdelivr.net/npm/@turf/turf@6/turf.min.js');
|
||||
const valid = readings
|
||||
.filter(r => turf.booleanPointInPolygon(turf.point(r.loc), boundary))
|
||||
.sort((a, b) => a.ts - b.ts);
|
||||
if (valid.length < 2) return 0;
|
||||
const line = { type: 'LineString', coordinates: valid.map(r => r.loc) };
|
||||
const length = turf.length(line, { units: 'kilometers' });
|
||||
return Math.round(length * 100) / 100;
|
||||
}
|
||||
export default analyzeGPS;
|
||||
// Generation time: 17.976s
|
||||
// Result: FAIL
|
||||
Reference in New Issue
Block a user