Showing results for 
Search instead for 
Do you mean 

Import BIL32 elevation data (BIL / HDR)

by Technical Evangelist on ‎11-25-2019 01:33 PM - edited on ‎02-24-2020 03:11 AM by Community Manager (310 Views)

Download model and sample data



There's a generic binary BIL / HDR format out there for Floating point raster elevation data where the header does not conform to any of the BIL headers interpreted by ERDAS IMAGINE's direct reads. However it can be imported using the Generic Binary importer so long as you specify the number of rows / columns (usually 3001 x 3001), etc.

This Spatial Model shows how to parse the header to produce inputs to the Generic Binary importer and to the ImageCommand executables, both run via Command Line operators. This way the import process can be easily Batched if there are a large number of such BIL / HDR DSMs requiring conversion.

Data Requirements and Assumptions
  1. Main raster filename follows a *dsm.bil structure
  2. The .bil is a single band of data type float
  3. There is a matching *dsm.hdr file which must be structured with the first five Key / Value pairs  like this:

    NCOLS          3001
    NROWS          3001
    XLLCENTER      101.375
    YLLCENTER      3
    CELLSIZE       4.16666666667e-005
  4. Projection is Lat/Lon WGS84
  5. Pixel size is in Decimal Degrees (dd)
  6. NoData value is -10000

….but most of those can be easily changed (or variabalized) if you want. The ImageCommand executable could also be used to apply a vertical datum and other information normally associated with a raster elevation file. 





Example data:


n49e009h4dsm.bil – Band Interleaved by Line (BIL) generic binary raster file containing a single band of Floating-point elevation values

n49e009h4dsm.hdr – Corresponding ASCII header file consisting of Key / Value pairs denoting the size of the raster array, lower-left X and Y Lat/Lon, pixel size, etc.