2

I've downloaded a tile of a freely accessible LiDAR DEM of the UK from http://environment.data.gov.uk/ds/survey#/download.

But I don't know how to open it. The files inside have the *.asc extension. I can see that this extension is not among those supported by Gdal. And, neither Sentinel Application Platform SNAP nor ENVI did manage to open it.

Which software is used to open these DEM files?

2

3 Answers 3

3

These are ESRI ASCII grid files:

$ head -6 sd5755_DSM_2m.asc 
ncols        500
nrows        500
xllcorner    357000
yllcorner    455000
cellsize     2
NODATA_value  -9999

with coordinates in OSGB grid references (EPSG code 27700). This is about the only thing GDAL doesn't know about them:

$ gdalinfo sd5755_DSM_2m.asc 
Driver: AAIGrid/Arc/Info ASCII Grid
Files: sd5755_DSM_2m.asc
Size is 500, 500
Coordinate System is `'
Origin = (357000.000000000000000,456000.000000000000000)
Pixel Size = (2.000000000000000,-2.000000000000000)
Corner Coordinates:
Upper Left  (  357000.000,  456000.000) 
Lower Left  (  357000.000,  455000.000) 
Upper Right (  358000.000,  456000.000) 
Lower Right (  358000.000,  455000.000) 
Center      (  357500.000,  455500.000) 
Band 1 Block=500x1 Type=Float32, ColorInterp=Undefined
  NoData Value=-9999

so you'll have to tell your GIS about the CRS if you need to project it to anything else.

3
  • Do you know why there are 41 files for 1m resolution DTM and DSM?
    – Hakim
    Commented Nov 8, 2015 at 19:07
  • 2
    Because the UK is quite big
    – Ian Turton
    Commented Nov 8, 2015 at 20:01
  • with most of the gdal commands you can add projection with -s_srs epsg:27700 (OSGB Grid)
    – nickves
    Commented Nov 9, 2015 at 0:10
3

GDAL can open this for you, it should be a ASCII file. You can easily translate to tif with

gdal_translate source.asc dest.tif

4
  • Does it mean that it's a vector?
    – Hakim
    Commented Nov 8, 2015 at 19:03
  • 2
    This might give you some more insight. Commented Nov 8, 2015 at 19:16
  • The elevation seems to be given in meters
    – Hakim
    Commented Nov 8, 2015 at 23:01
  • ASC (*.asc) files are rasters and will load into QGIS using the "Layer -> Add Layer -> Add Raster Layer..." dialogue.
    – nhopton
    Commented Mar 13, 2016 at 9:51
2

I would go with a two step approach to create a single file from all the downloaded ASCII format files using two GDAL utilities. From within the unzipped file:

  1. Create a 'Virtual Raster' with all the files:

    gdalbuildvrt merged_mosaic.vrt *asc

I'm not sure how the shell expansion will work if you are using windows - you could also pass in a list of files, see http://www.gdal.org/gdalbuildvrt.html for more details.

  1. Convert the VRT to a GeoTIFF (or any other format GDAL supports) and assign the OSGB projection:

    gdal_translate -of GTiff -a_srs EPSG:27700 merged_mosaic.vrt merged_mosaic.tif

If it is of any use I also wrote a script which will mosaic the files from within the zip file. It uses RSGISLib (http://rsgislib.org/) but could be adapted to use gdalbuildvrt / gdal_translate instead. See: https://spectraldifferences.wordpress.com/2015/09/02/mosaic-environment-agency-dtmdsm-tiles-using-rsgislib/ for details.

Update: I have also written a script which will mosaic tiles using GRASS: https://gist.github.com/arsf/fcf51a0dd8b7dcde8243

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.