hello andrew,
the functionality "-keep_random_fraction 0.2" is implemented as a
LASfilter that is available to pretty much all LAStools that consume
LAS/LAZ points. Instead of using lasthin you should simply use, for
example, las2las.
>las2las -i file.las -keep_random_fraction 0.2 -o file_thinned.las -v
reading 10000000 and writing all surviving points ...
total time: 64.515 sec. written 1999997 surviving points.
lasthin uses a grid to thin and keeps only the lowest (or highest)
points of each grid cell. but lasthin will also apply the "-
keep_random_fraction 0.2" filter which means that in general you will
not quite get the result you want as only the surviving 1999997 points
will be considered when looking for the lowest (or highest) points of
each grid cell so that many grid cells may remain empty or won't
contain the lowest point.
>lasthin -i file.las -keep_random_fraction 0.2 -o file_thinned.las -v
Please license from '
martin....@gmail.com' to use LAStools
commercially.
grid_spacing was unspecified. we set it to 1.
thinning points onto 2406 by 2192 grid (grid_spacing = 1.00 units)
first pass reading 10000000 points ...
took 52.375 sec.
there are 1573646 surviving points. grid saturation is 29.84 percent.
second pass reading 10000000 and writing 1573646 points ...
took 56.578 sec and wrote 9304962 bytes to thin 'file.las'.
for lasthin the "thinning" is controlled via the '-step 1' flag that
controls the grid spacing:
>lasthin -i out0000.las -o out_thinned.las -step 1 -v
Please license from '
martin....@gmail.com' to use LAStools
commercially.
thinning points onto 2406 by 2192 grid (grid_spacing = 1.00 units)
first pass reading 10000000 points ...
took 50.671 sec.
there are 4279937 surviving points. grid saturation is 81.15 percent.
second pass reading 10000000 and writing 4279937 points ...
took 70.61 sec and wrote 119844734 bytes to thin 'file.las'.
Cheers,
Martin @lastools