Read ESRI Grid File

Read an ESRI ASCII grid file

from pyvista import examples

from PVGeo.grids import EsriGridReader

Download a sample ESRI grid file

filename, _ = examples.downloads._download_file('esri_grid.dem.zip')
dem = EsriGridReader().apply(filename)
dem
HeaderData Arrays
UniformGridInformation
N Cells4875263
N Points4879680
X Bounds3.666e+05, 3.732e+05
Y Bounds3.733e+06, 3.740e+06
Z Bounds0.000e+00, 0.000e+00
Dimensions2208, 2210, 1
Spacing3.000e+00, 3.000e+00, 3.000e+00
N Arrays1
NameFieldTypeN CompMinMax
DataPointsfloat641-3.936e+023.988e+02


Apply a filter to the DEM to have realistic topography

warped = dem.warp_by_scalar()
warped.plot(cmap='terrain', clim=[-100, 400])
read esri

Total running time of the script: ( 0 minutes 8.646 seconds)

Gallery generated by Sphinx-Gallery