10
votes
Extract raster value at each vertex from line, while keeping the line
You can use "Drape (set Z value from raster)" tool to set the z value of every vertex in the densified line to a value sampled from a raster.
- 69.9k
9
votes
Accepted
Extract raster value at each vertex from line, while keeping the line
Using QGIS expressions, use this expression:
raster_value( 'DEM', 1, start_point($geometry))
This is to get the elevation from the raster called DEM, raster band 1 for the line's start point. To get ...
- 55.3k
4
votes
Accepted
rasterstats zonal_stats - return cell position
You can grab the indices of the mini raster where the pixel value == the statistic value (i.e min or max) using numpy.argwhere, then use the transform/affine to work out the map coordinates.
e.g.
from ...
- 58.7k
3
votes
How do you interpret a DEM?
A DEM is to my understanding usually created from the interpolation from other data sources, typically point elevations and\or contour lines, the pixel being assigned an elevation value. When I use a ...
- 41.2k
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
dem × 1942qgis × 619
arcgis-desktop × 489
raster × 365
elevation × 206
lidar × 142
gdal × 108
slope × 100
arcmap × 99
contour × 97
spatial-analyst × 77
grass-gis × 75
srtm × 70
geotiff-tiff × 62
hydrology × 60
python × 59
coordinate-system × 56
data × 55
terrain × 54
arcgis-10.1 × 52
hillshade × 52
interpolation × 50
raster-calculator × 48
arcgis-10.0 × 43
arcgis-pro × 40