Ames Stereo Pipeline: Making DTMs with CTX stereo pairs

A few weeks ago, I received good news about my application to three large image posters at LPSC. Unlike traditional posters, these are 88’x44′ spaces to showcase some cool pictures with no technicalities attached. So, I decided to make some simple mosaics of CTX images of the Hebrus Valles outflow channels. To add some more information, I wanted to colorize the grayscale images with elevation in the background. The currently available global elevation data, made with MOLA and HRSC stereo-derived digital terrain models (DTMs), is not bad, but often doesn’t capture the elevation change of smaller features. This is where the Ames Stereo Pipeline (ASP) and CTX come in handy.

Editing the USGS Ames Stereo Pipeline scripts

David Mayer at USGS wrote a collection of handy scripts that automate and greatly simplify making DTMs with ASP. Currently scripts are available for HiRISE and CTX stereo pairs only, but I believe they can be easily adapted to other cameras fairly easily. At first I made an attempt with the original code, and the results were already excellent, see below for an example. There are very few artifacts and holes, especially along steep scarps where shading often causes trouble. The USGS code takes advantage of two different techniques, solving problems with both featureless terrains and steep scarps. Right after, I decided to make my own tweaks to the code and optimize it fore my own purposes. I just forked the USGS code on GitHub and started working on my own repository, which you can find here. I kept working on the same stereo pair, so I could compare the results with the original code. Then, after some improvements, I tried my code elsewhere, including the north polar region. In the process, I quickly found that settings that work wonderfully in Hebrus Valles are bad choices in the polar regions, so you’ll find that some scripts and settings have a “-polar” version.

Ames Stereo Pipeline CTX Hebrus Valles
The first attempt at making a CTX stereo DTM with the ASP USGS code. Both images show the same DTM: the left is colorblind friendly, the right one has more dynamic range.

What’s next?

I’m continuously updating the CTX code, and soon I’ll try the HiRISE scripts too. A lot of it is debugging my own edits, and I’m still learning a lot. I also want to adapt the CTX code to HRSC, since that camera natively acquires stereo images. I made a few attempts a while ago by using one ASP command at a time, and I remember the results were not too bad. Also, in some rarer cases there is more than one stereo pair, so I want to experiment with merging multiple DTMs and maybe use the tool that takes advantage of shades to improve an already available DTM.

Leave a Reply

Your email address will not be published. Required fields are marked *