[GRASS-user] Importing Point-Cloud with v.in.lidar

Markus Metz markus.metz.giswork at gmail.com
Sat Feb 15 11:27:05 PST 2020


Hi Olivier,

when dealing with not so easy to handle input data, I recommend to use the
tools to handle these data directly instead of some interface like QGIS or
GRASS GIS that might hide some important information. For raster data, this
would be gdalinfo, for vector data ogrinfo, for point clouds lasinfo or
pdal info.

If you want to import geodata to GRASS GIS, the safest way is to first
create a GRASS location using the CRS of the input data. The CRS of the
input data can be obtained with the appropriate *info tool. Then you can
import the data. If import does not succeed, the error messages should
explain why import failed.

For regular raster or vector geodata recognized by GDAL/OGR, using GRASS
GIS via QGIS should work. But point clouds are not always recognized by OGR
and not as easy to handle, in which case you need to use other tools than
OGR. It also depends on what you want to do with these point clouds.

Markus M


On Wed, Feb 12, 2020 at 5:30 PM <Olivier.C.Canon at umwelt.uni-giessen.de>
wrote:

>
> Hello grass-community,
>
> Actually I’m working for a research project (master thesis) with point
> data, that were exported from dronedeploy one year ago.
> Unfortunately processing the exported LAS-files is quit challenging,
> as there are some issues with the file format (e.g. the projection).
> My aim is to import the data into Grass-GIS to process it there with
> the 3D-fragmentation tool. But till now I was not able to import it…
> So I thought I’ll ask for some help here.
>
> I tried to process the data with several tools, like lidR package in
> R-Studio and LAStools. First I had to change the projection with
> las2las to a appropriate (EPSG 3116) one, to be able to display it
> correctly in these tools. Now I can do further processing with the
> data, like creating grids. By the way, these grids are located
> correctly when loading them to a GIS-application. So coordinates seem
> to be correctly. Anyway loading the point-data to Grass-GIS (with
> v.in.lidar tool) fails, because the points are in a wrong
> location/projection. I did not use -r (limit to current region), so
> this can not be the problem. First it did calculate something and
> added a vector map that seemed to be empty, because there was nothing
> displayed.
> Actually it doesn’t even start calculating and there is no vector map
> produced. I copied the output below. I already got the hint to try
> importing a ASCII text by converting the LAS file with PDAL. So I will
> try installing PDAL on my PC. Anyway, maybe some has a solution for
> the v.in.lidar problem.
>
> Output:
> QGIS version: 3.10.2-A Coruña
> QGIS code revision: d4cd3cfe5a
> Qt version: 5.11.2
> GDAL version: 3.0.4
> GEOS version: 3.8.0-CAPI-1.13.1
> PROJ version: Rel. 6.3.0, January 1st, 2020
> Processing algorithm…
> Algorithm 'v.in.lidar' starting…
> Input parameters:
> { '-b' : False, '-c' : False, '-t' : False,
> 'GRASS_OUTPUT_TYPE_PARAMETER' : 0, 'GRASS_REGION_PARAMETER' :
> '1209933.8649246846,1210526.7738715957,820900.5310786865,821470.5180333158
>
> [EPSG:3116]', 'GRASS_VECTOR_DSCO' : '', 'GRASS_VECTOR_EXPORT_NOCAT' :
> True, 'GRASS_VECTOR_LCO' : '', 'class_filter' : '', 'input' :
> 'C:\\Users\\oc\\OneDrive - HH
> Gruppe\\Dokumente\\Uni\\Master\\Daten\\Daten_Stuktur\\points\\110_1.las',
> 'limit' : None, 'offset' : None, 'output' : 'TEMPORARY_OUTPUT',
> 'preserve' : None, 'return_filter' : [], 'skip' : None, 'spatial' :
> None, 'zrange' : [nan,nan] }
>
> g.proj -c proj4="+proj=tmerc +lat_0=4.59620041666667
> +lon_0=-74.0775079166667 +k=1 +x_0=1000000 +y_0=1000000 +ellps=GRS80
> +towgs84=0,0,0,0,0,0,0 +units=m +no_defs"
> g.region n=821470.5180333158 s=820900.5310786865 e=1210526.7738715957
> w=1209933.8649246846
> v.in.lidar -o input="C:\Users\oc\OneDrive - HH
> Gruppe\Dokumente\Uni\Master\Daten\Daten_Stuktur\points\110_1.las"
> output=output2221d86f3dd44a7c84ead4bac980f243 --overwrite
> v.out.ogr type="auto" input="output2221d86f3dd44a7c84ead4bac980f243"
> output="C:\Users\oc\AppData\Local\Temp\processing_073544cf878b4dd8b5311a6a5d27abcc\cc8523d5d751483b9922084e16845571\output.gpkg"
> format="GPKG" -c
> --overwrite
> Starting GRASS GIS...
> WARNING: Concurrent mapset locking is not supported on Windows
> Cleaning up temporary files...
> Executing
> <C:\Users\oc\AppData\Local\Temp\processing_073544cf878b4dd8b5311a6a5d27abcc\grassdata\grass_batch_job.cmd>
>
> ...
> C:\Users\oc\OneDrive - HH Gruppe\Dokumente>chcp 1252 1>NUL
> C:\Users\oc\OneDrive - HH Gruppe\Dokumente>g.proj -c
> proj4="+proj=tmerc +lat_0=4.59620041666667 +lon_0=-74.0775079166667
> +k=1 +x_0=1000000 +y_0=1000000 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0
> +units=m +no_defs"
> Default region was updated to the new projection, but if you have
> multiple mapsets `g.region -d` should be run in each to update the
> region from the default
> Projection information updated
> C:\Users\oc\OneDrive - HH Gruppe\Dokumente>g.region
> n=821470.5180333158 s=820900.5310786865 e=1210526.7738715957
> w=1209933.8649246846
> C:\Users\oc\OneDrive - HH Gruppe\Dokumente>v.in.lidar -o
> input="C:\Users\oc\OneDrive - HH
> Gruppe\Dokumente\Uni\Master\Daten\Daten_Stuktur\points\110_1.las"
> output=output2221d86f3dd44a7c84ead4bac980f243 --overwrite
> C:\Users\oc\OneDrive - HH Gruppe\Dokumente>v.out.ogr type="auto"
> input="output2221d86f3dd44a7c84ead4bac980f243"
> output="C:\Users\oc\AppData\Local\Temp\processing_073544cf878b4dd8b5311a6a5d27abcc\cc8523d5d751483b9922084e16845571\output.gpkg"
> format="GPKG" -c
> --overwrite
> ERROR: Vector map <output2221d86f3dd44a7c84ead4bac980f243> not found
> C:\Users\oc\OneDrive - HH Gruppe\Dokumente>exit
> Execution of
> <C:\Users\oc\AppData\Local\Temp\processing_073544cf878b4dd8b5311a6a5d27abcc\grassdata\grass_batch_job.cmd>
>
> finished.
> Cleaning up temporary files...
> Drücken Sie eine beliebige Taste . . .
> Execution completed in 13.86 seconds
> Results:
> {'output': <QgsProcessingOutputLayerDefinition
> {'sink':TEMPORARY_OUTPUT, 'createOptions': {'fileEncoding': 'System'}}>}
>
> Loading resulting layers
> The following layers were not correctly
> generated.<ul><li>C:\Users\oc\AppData\Local\Temp/processing_073544cf878b4dd8b5311a6a5d27abcc/cc8523d5d751483b9922084e16845571/output.gpkg</li></ul>You
> can check the 'Log Messages Panel' in QGIS main window to find more
> information about the execution of the
> algorithm.
>
> Kind regards, Olivier Canon
>
> _______________________________________________
> grass-user mailing list
> grass-user at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/grass-user
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-user/attachments/20200215/75a25c2e/attachment.html>


More information about the grass-user mailing list