I am a skilled orienteer who works with maps using Ocad software. In Finland, we are happy because we have so much open source geospatial data. License CC 4.0, data open source National Land Survey of Finland
- Awot, my company
- Suunnistus.info, my orienteering pages
- Kalevan Rasti, my orienteering club
- Github kshji, my github
My geo programs use various software, including Lastools, PDAL and GDAL.
- PROJ
- GDAL
- PDAL
- Lastools
- Karttapullautin archive, toolbox/workflow for generating O training maps from Lidar materials. Thank you Jarkko Ryyppö.
- Karttapullautin Github, same pullautin software, but rewrited using Rust - use this fast pullautin
- Karttapullautin Perl, org perl version, still updated - some options has only in this version
- LasPy, Python library for lidar LAS/LAZ IO, Github
- OCAD, Cad for mapping
- Omapper, OMapper open source for mapping
- PurplePen, free course setting software for orienteering
The full licence terms can be found on the individual pages of the following tools.
- Shp2Dxf my online tool to make DXF from Shapefiles, ex. using in the Ocad
- Ocad angle correction GD: declination + convergence
- GeoTIFF.io GeoTiff viewer,
- Pullautuskartta
- MapAnt FI
- CloudCompare, CloudCompare is a 3D point cloud processing software. Also light CcViewer.
- QGIS, Spatial visualization and decision-making tools for everyone - Open Source
- Courses: Point cloud processing with QGIS and PDAL wrench
- Courses: Programming for Geospatial Hydrological Applications
- Geospatial School
- Awesome-Geospatial, list of geotools
- Proj Widard
- Virtual DOS, Github, also Linux, Windows98, ... nice.
This example is for Ubuntu, Debian, WSL2 Ubuntu, ...
Each software pages include also download for Windows, OS/X, ...
#sudo apt-get install proj-bin libproj-dev
sudo apt-get install python3-dev python3.8-dev python3-pip
# update PIP
pip3 install --upgrade pip
# GDAL install include PROJ
# Official stable UbuntuGIS packages.
sudo add-apt-repository ppa:ubuntugis/ppa
sudo apt-get update
sudo apt-get install gdal-bin libgdal-dev
# Check:
ogrinfo --version
sudo apt-get install python3-gdal python3-numpy
# If using perl and need GDAL, then
sudo apt-get install libgd-gd2-perl
# PDAL
sudo apt-get install -y pdal libpdal-plugins
If you get error free(): invalid pointer using cmds:
ogrinfo --version
gdalinfo --version
pdal --version
Then you have problem with libproj versions. Solutions is usually to find correct libproj = latest and then soft link to the older version numbers.
# User env
# - look version using: ogrinfo --version
# - in this example version is 3.3.2
pip install GDAL==3.3.2
pip install pygdal=="3.3.2.*"
pip install laspy[laszip]
pip install scipy numpy
pip install lasio
All example files are in the examples directory.
After you have get copy of awgeo, you need setup config/awgeo.ini file. Example if this directory is /home/user/awgeo then your configfile /home/user/awgeo/config/awgeo.ini has one line:
AWGEO=/home/user/awgeo
- draw polygon in Ocad
- get polygon info (button i)
- copy polycon text to the textfile ex. area.raw
Convert raw to the xy format:
../raw2xy.sh -i area.raw -o area.txt
Convert x,y polygon textfile to the WKT polygon format.
cd examples
cat area.txt
632162.5 6954655.8
632176.7 6954656.9
632200.1 6954651.5
632162.5 6954655.8
../xy2wkt.sh -i area.txt -o area.wkt
# or using pipe
cat area.txt | ../xy2wkt.sh > area.wkt
You can use Lastools lasclip or this small PDAL script to crop polygon area from laz file. lazcrop.sh need polygon in WKT Polygon format. Look xy2wkt.sh how to convert x,y textfile to the wkt format.
# using lastools
lasclip64 -i example.laz -o areax.las -poly area.txt
# using lazcrop.sh
../lazcrop.sh -i example.laz -p area.wkt -o areay.las
laz2tif.sh -i input.laz -o result.tif [ -d 0|1 ]
-i input laz file name
-o result tif file
-d 0|1 , default 0 - debug output
-v version
-h this help
Example from example.laz
cd examples
../laz2tif.sh -i example.laz -o example1.tif
Result file is example1.tif
hillshade.sh -i input.laz -o resultname [ -z NUMBER ] [ -g 0|1 ] [ -d 0|1 ]
-i input laz file name
-o resultname, result file is resultname.tif !!!
-g 0|1 , default 1, using ground filter or not
-z NUMBER , default is 3
-d 0|1 , default 0 - debug output
-v version
-h this help
Example hillshade from example.laz
cd examples
../hillshade.sh -i example.laz -o example1
Result file is example1.tif
Convert Tiff to PNG
gdal_translate -of PNG example1.tif example1.png
- default values, look hillshade.sh, funtion *json and set_def.
Calculate the volume from the Lidar data (LAZ-file) data above a certain height.
lidar_volume.py I have used to calculate volume of lidar, using some base z-index.
Here is example how to clip some area from LAZ-file and then calculate volume above level 112.
cd examples
# unzip laz and clip area using polycon area.txt
lasclip64 -i example.laz -o areax.las -poly area.txt -keep_class 2
# or drop below 112 data already in this step, lidar_volume.py also accept above level value
lasclip64 -i example.laz -o areax.las -poly area.txt -keep_class 2 -drop_z_below 112
# or using my lazcrop.sh
# or using Pdal to unzip laz to las
pdal translate example.laz example.las
# look lazcrop.sh how to clip polygon from the LAZ-file
# calculate volume
python3 ../lidar_volume.py areax.las 112
112.0 38780.31 m3
Source for this solution. Thanks for WaterFox.
python3 rotate.angle.py source.tif angle rotated.tif
# angle is +/- degrees
Need to remove geodata from GeoTiff => it is "only" tif image without geolocation.
gdal_translate -of GTiff -co PROFILE=BASELINE input.tif output.tif
# or
cp geotif.tif output.tif
gdal_edit.py -unsetgt output.tif
More documentation in the script.
forest.sh
Do both hillshade.sh and forest.sh
More documentation in the script.
forest_hillshade.sh
pullauta.run.sh is my version to batch pullauta process.
- mkdir input and output
- config/pullauta.ini use some variable = dynamic template , make your edits to this version
- edit awgeo.ini, set directory where is AwGeo binary's
Have to set:
batch=1
processes=4 # how many core you can use
batchoutfolder=./output
lazfolder=./input
Normal batch:
- put input files to the dir input: LAZ + Maastotietokanta SHP zipped (ZIP)
- execute pullauta
- make also hillshade and intermediate curves
pullauta.run.sh -a 11 -i 0.625 -s -z 3
# - northlineangle 11, intermediate curve 0.625, hillshade using z=3
Only map without hillshade and intermediate curves, nothlines angle 11: If angle=0, no northlines.
pullauta.run.sh -a 11
Re-run only using tempfiles hillshade:
- reuse temp files
pullauta.run.sh --onlyhillshade -s -z 3
Re-run only using tempfiles intermediate curves:
pullauta.run.sh --onlyintermediate -i 0.625
# - run only intermediate curves (0.625 m) after basic run - use temp files