Hi @juraj, thanks for clarifying, that’s helpful. The workflow I would recommend is that you embed the CRS of your data in the LAS file before tiling it in ion. When I ran the Python script you provided, I saw that it output 6.40429397482618 lon, 60.65092204339487 lat, 0 alt
as the geodetic origin of the data. When I passed this origin into the tiler manually via command line, the KML and LAS data were aligned after tiling. (Almost. When I zoom way in, I still see a slight difference, and I’m wondering if that is the result of error being introduced during the initial processing.)
Some information about the tiler and LAS files:
The variable length records may contain information about the Coordinate Reference System (CRS); in LAS 1.3 and earlier the CRS is stored as GeoTIFF keys and in LAS 1.4 the CRS may be stored as Well Known Text. The tiler supports all versions of the spec, 1.0 through 1.4, though most LAS files are either LAS 1.2 or LAS 1.4.
I’m not familiar with laspy, but hopefully it allows you to put CRS information in the LAS header. An alternative solution would be to store the points in ECEF.
The tiler may recompute the bounding box, so the original bounding box can’t necessarily be relied upon to georeference the data after the fact. Positions are stored relative-to-center.
Hopefully this information is helpful, but please feel free to ask any follow-up questions. I’m happy to clarify or investigate further.
For your reference, below is the tileset.json
file outputted by the point-cloud tiler when no CRS or origin is supplied:
{
"asset":{
"extras":{
"ion":{
"georeferenced":false,
"movable":true
}
},
"version":"1.0"
},
"geometricError":4958.606108514771,
"root":{
"boundingVolume":{
"box":[
0.0,
0.0,
613.4449999999999,
1223.7150000000001,
0.0,
0.0,
0.0,
2067.16,
0.0,
0.0,
0.0,
613.4449999999999
]
},
"children":[
{
"boundingVolume":{
"box":[
-263.78499999999985,
755.9499999999998,
976.365,
1223.7150000000001,
0.0,
0.0,
0.0,
2067.16,
0.0,
0.0,
0.0,
613.4449999999999
]
},
"content":{
"uri":"0/0.pnts"
},
"geometricError":0.0,
"transform":[
1.0,
0.0,
0.0,
0.0,
0.0,
1.0,
0.0,
0.0,
0.0,
0.0,
1.0,
0.0,
263.78499999999997,
-755.95,
-362.92,
1.0
]
}
],
"geometricError":4958.606108514771,
"refine":"ADD"
}
}
And here it is after I specified the geodetic origin (note the “transform” block toward the end):
{
"asset":{
"extras":{
"ion":{
"georeferenced":true,
"movable":true
}
},
"version":"1.0"
},
"geometricError":4958.606108514771,
"root":{
"boundingVolume":{
"box":[
0.0,
0.0,
613.4449999999999,
1223.7150000000001,
0.0,
0.0,
0.0,
2067.16,
0.0,
0.0,
0.0,
613.4449999999999
]
},
"children":[
{
"boundingVolume":{
"box":[
-263.78499999999985,
755.9499999999998,
976.365,
1223.7150000000001,
0.0,
0.0,
0.0,
2067.16,
0.0,
0.0,
0.0,
613.4449999999999
]
},
"content":{
"uri":"0/0.pnts"
},
"geometricError":0.0,
"transform":[
1.0,
0.0,
0.0,
0.0,
0.0,
1.0,
0.0,
0.0,
0.0,
0.0,
1.0,
0.0,
263.78499999999997,
-755.95,
-362.92,
1.0
]
}
],
"geometricError":4958.606108514771,
"refine":"ADD",
"transform":[
-0.11154340883487353,
0.9937595624422921,
0.0,
0.0,
-0.866210285377921,
-0.09722678568387881,
0.4901292621860905,
0.0,
0.4870706411302129,
0.05467068867395802,
0.8716497612854136,
0.0,
3114085.343231913,
349271.51667731546,
5537068.5816861205,
1.0
]
}
}