Opened 5 years ago

Last modified 4 years ago

#545 closed task

DEM Scripts Rewrite/Restructure — at Version 1

Reported by: dac Owned by: dac
Priority: immediate Milestone: The Glorious Future
Component: Processing: general Keywords:
Cc: Other processors:

Description (last modified by dac)

There are currently a large number of scripts and libraries for DEM related tasks, most commonly used to:

  • Create DEMs for use in APL
  • Create DEMs from LiDAR data
  • Perform general tasks on DEMs (e.g., reprojection)

These scripts are a complicated mix of bash and Python which are very difficult to debug. Previous attempts to simplify them have only increased the complexity.

There are problems with the existing scripts which are proving difficult to fix given the current state of the code, the biggest one is that the DEMs produced are often much larger than needed.

A rewrite/restructure of the existing DEM scripts is therefore proposed with the following aims:

  • Use Python instead of bash where possible
  • Store common functions within a Python library
  • Make use of existing libraries both external (e.g., GDAL, Proj, GRASS Python bindings) and internal where possible.

Given these aims the following is proposed:

New DEM Scripts
Create DEM subset to navigation data for use in APL. Locations of existing DEMs (ASTER and NMB) will be hardcoded but will allow any DEM mosaic (real or virtual raster) to be provided.


--aster [bool]
--nmb [bool]
--demmosaic [File, if not ASTER or NMB]
--nav [Navigation file]
--projectpath [Path to project]


--outdem [File]
Create DEM from lidar data

lidar files(s)
--inproj [shouldn't be needed if projection is stored properly with lidar]
--outproj [default same as input]
--aster [bool - patch with aster]
--nmb [bool - patch with nmb]
--mosaic [mosaic if multiple input files are provided]


--outdem [File]
--screenshots [File(s) optional]

New DEM Library
Putting all the DEM functions in a separate module (arsf_dem) is proposed rather than multiple libraries.

|-- arsf_dem
|   |--
|   |-- dem_lidar
|   |   |--
|   |   |--
|   |   |--
|   |   |--
|   |   |--
|   |--
|   |--
|-- scripts
|   |--
|   |--

Change History (1)

comment:1 Changed 5 years ago by dac

  • Description modified (diff)

Updated library structure.

Note: See TracTickets for help on using tickets.