GeoscienceAustralia / PyRate

A Python tool for estimating velocity and time-series from Interferometric Synthetic Aperture Radar (InSAR) data.
https://geoscienceaustralia.github.io/PyRate/
Apache License 2.0
200 stars 70 forks source link

Add switch to specify uncertainty communication in rate/velocity error maps #319

Closed richardt94 closed 3 years ago

richardt94 commented 3 years ago
  1. I have added a switch to the config file, which allows the user to specify whether they would like the velocity error maps to represent 1- or 2-sigma errors. This switch applies to the error maps produced by both stack and timeseries methods. The default is 2-sigma (95% confidence interval) because this is the standard for uncertainty communication in many fields of science.
  2. I modified the test suite, specifically test_timeseries.py and test_stackrate.py, to manually specify 1-sigma errors in the default parameters dictionary. This is for compatibility with the legacy test datasets which have 1-sigma error maps.
  3. I added a new test to test_timeseries.py which confirms that the switch actually produces a 2-sigma error map when this is specified.
mcgarth commented 3 years ago

Thanks @richardt94 , this is a good change to the code! I have a couple of suggested additions to your functionality. Depending how much effort they require you can include in this PR, or save for a later ticket.

richardt94 commented 3 years ago

I have rebased the changes on top of the latest develop and removed the restriction to only one or two sigma - can now be an arbitrary positive integer. I have not added metadata to the output geotiff because I can't understand the system for getting metadata into the geotiffs - it looks like merge is opening some stored metadata that is generated by correct and then only re-writing specific tags that are defined in ifgconstants.py? This represents a good opportunity for code rationalisation IMO, possibly as part of PIS-169 (merging products in memory instead of writing/reading to disk as an intermediate step).

@basaks this PR is now ready for your review, then if you approve I will squash and merge.

mcgarth commented 3 years ago

velocity error nsigma metadata has been added to the output error geotiffs in https://github.com/GeoscienceAustralia/PyRate/pull/327