NeoGeographyToolkit / StereoPipeline

The NASA Ames Stereo Pipeline is a suite of automated geodesy & stereogrammetry tools designed for processing planetary imagery captured from orbiting and landed robotic explorers on other planets.
Apache License 2.0
492 stars 173 forks source link

Sparse sub-pixel options in stereo_rfne #289

Closed jchollingsworth closed 1 year ago

jchollingsworth commented 4 years ago

Hi guys,

This is a feature request...

So I mentioned this problem on the forum: https://groups.google.com/forum/m/#!msg/ames-stereo-pipeline-support/iHepqQ-4Boc/L4PS6VfvBwAJ

Basically, when running stereo_rfne with phase option, a large(ish) window (e.g. ~21) is needed to avoid sub-pixel bias. However, this means there is a lot of nearly redundant computation, which by default is done at every pixel location (i.e. we're oversampling a lot).

It would be great if stereo_rfne had an option to step the displacement calculation every n pixels. Then, the full sub-pixel refinement can be interpolated for all points (I suspect a sinc kernel would be best).

This would give a dramatic speed up, when correlating orthorectified images. e.g. correlating at every pixel location vs stepping every 8 pixels would reduce the run time to only 1/64 (plus interpolating over the full grid). I'm not sure if stereo_rfne is simply updating the integer value pixel-wise as it goes (?), or if it computes the sub-pixel displacement component everywhere, then updates the integer displacement field... so I guess this stepping feature, with interpolation, might need some thought how to implement... but Scott thought it would probably not be too much trouble.

So maybe an option in stereo_rfne to step the refinement calculation... this should make ASP much more practical for correlating orthorectified images :)

Cheers,

James