Removing spurious holes in ASTER DEM data

1 view (last 30 days)
Jeremy Fyke
Jeremy Fyke on 17 Apr 2012
Hi there,
I am processing ASTER digital elevation data over glaciers (ASTER data obtained using wmsread from Mapping Toolbox), and have come across large anomalies in the data, likely due to cloud cover (they manifest as very low elevation 'pits'). I would like to either:
-automatically detect and remove these anomalies (i.e. set to NaN)
-automatically set the elevation values to interpolated values based on surrounding 'good' values
I would appreciate any ideas on how to proceed in detecting and removing these spurious points!
Automation is required as I have 10^5 glaciers to process. I have access to the statistics toolbox and the mapping toolbox at the moment. You can find the elevation data and the corresponding georeference object in glacier_DEM_problem.mat file, and a .png image of a problem glacier DEM all zipped together at the following link, if you are interested in looking at this problem in more detail.
Sincerely,
Jeremy Fyke

Answers (2)

Image Analyst
Image Analyst on 18 Apr 2012
You can use roifill() in the Image Processing Toolbox. First you have to get a 2D binary map of where your missing data are. What are the values of the missing data? Are they all zero?
Alternatively if you find them and can set them to nan's, you can use inpaint_nans, but again, you have to have your 2D image first.
  1 Comment
Image Analyst
Image Analyst on 18 Apr 2012
Well somehow you have to be able to specify which pixels you want to fix. Can you show us an image of what it looks like?

Sign in to comment.


Jeremy Fyke
Jeremy Fyke on 18 Apr 2012
Image Analyst - thanks for the reply. The values of the missing data are not necessarily zero, nor are they a constant value - they are just spurious data resulting from the ASTER satellite imaging clouds rather than the surface. So at the moment getting the 2D binary map is the main challenge in itself. However, the holes are visually obvious, which makes me think they should be algorithmically locatable. one method may be to search for unrealistically steep surface gradients or regional statistical outliers in elevation, but that may not be perfect either. I think the holes are definitely too big to just 'smooth over' either - it will just diffuse the error instead of remove it.
Another issue: I don't have the Image Processing Toolbox (yet) - we'll see if my boss will spring for it! I'm working with the Mapping and Stats toolbox at this point.

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!