Merge branch 'master' into develop

This commit is contained in:
Pieter Vander Vennet 2024-12-17 16:19:43 +01:00
commit 566a7e639e
2 changed files with 8 additions and 3 deletions

View file

@ -30,7 +30,7 @@ class Compare extends Script {
Object.keys(osmParking.properties).concat(Object.keys(veloParking.properties)) Object.keys(osmParking.properties).concat(Object.keys(veloParking.properties))
) )
for (const key of allKeys) { for (const key of allKeys) {
if (["name", "numberOfLevels"].indexOf(key) >= 0) { if (["name", "numberOfLevels", "id"].indexOf(key) >= 0) {
continue // We don't care about these tags continue // We don't care about these tags
} }
if (osmParking.properties[key] === veloParking.properties[key]) { if (osmParking.properties[key] === veloParking.properties[key]) {
@ -108,7 +108,12 @@ class Compare extends Script {
distanceBins[bin] += 1 distanceBins[bin] += 1
} }
fs.writeFileSync("report_diff.json", JSON.stringify({ diffs, distanceBins }, null, " ")) fs.writeFileSync("report_diff.json", JSON.stringify({
diffs,
distanceBins,
binSize,
"#binsize": "Every bin increases with this amount in meter"
}, null, " "))
console.log("Written report_diff.json") console.log("Written report_diff.json")
} }

View file

@ -256,7 +256,7 @@ class VeloParkToGeojson extends Script {
VeloParkToGeojson.exportExtraAmenities(allVelopark) VeloParkToGeojson.exportExtraAmenities(allVelopark)
await VeloParkToGeojson.createDiff(allVelopark) await VeloParkToGeojson.createDiff(allVelopark)
console.log( console.log(
"Use vite-node scripts/velopark/compare.ts to compare the results and generate a diff file" "Use \nvite-node scripts/velopark/compare.ts -- velopark_all_.geojson osm_with_velopark_link_.geojson\n to compare the results and generate a diff file"
) )
} }
} }