You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We should quantize the coordinates to a fixed precision to avoid database bloat and potential floating point rounding errors at the spatial index. Decimal degrees precision:
decimal
degree
@ 0° Lat
@ 30° Lat
@ 60° Lat
2
0.01°
~ 1 km
~ 0.9 km
~ 0.5 km
3
0.001°
~ 100 m
~ 90 m
~ 50 m
4
0.0001°
~ 10 m
~ 9 m
~ 5 m
5
0.00001°
~ 1 m
~ 0.9 m
~ 0.5 m
6
0.000001°
~ 0.1 m
~ 0.09 m
~ 0.05 m
7
0.0000001°
~ 0.01 m
~ 0.009 m
~ 0.005 m
8
0.00000001°
~ 0.001 m
~ 0.0009 m
~ 0.0005 m
8 decimal places would get us 1mm precision, I think that's more than enough. The GeoJSON Spec recommends 6 decimal places for <10cm precision. There may be use-cases for greater precision, e.g. drawing precise building footprints. I think 8 decimal places (1mm precision) would be more than enough. Perhaps configurable at a DB level? Would it need to be kept consistent across the whole db?
The text was updated successfully, but these errors were encountered:
We should quantize the coordinates to a fixed precision to avoid database bloat and potential floating point rounding errors at the spatial index. Decimal degrees precision:
8 decimal places would get us 1mm precision, I think that's more than enough. The GeoJSON Spec recommends 6 decimal places for <10cm precision. There may be use-cases for greater precision, e.g. drawing precise building footprints. I think 8 decimal places (1mm precision) would be more than enough. Perhaps configurable at a DB level? Would it need to be kept consistent across the whole db?
The text was updated successfully, but these errors were encountered: