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
479 stars 168 forks source link

Build ASP using modern tools #279

Closed oleg-alexandrov closed 3 years ago

oleg-alexandrov commented 4 years ago

Nowadays there is infrastructure to find dependencies, build, and test software in the cloud, for Linux and Mac (heck, even for Windows for almost all ASP dependencies). A nifty tool is conda-smithy that can automate most of this and connect to GitHub and TravisCI, etc, for fetching latest code and do the build and testing.

Almost all of our dependencies apparently exist already on conda-forge, including all ISIS dependencies, then also bzip2, pbzip2, imagemagick, chrpath, openjpeg, geos, xz, gdal, hdf5, parallel, cspice, laszip, gflags, glog, and ceres. Just a handful will need come custom recipes. It is nice to see how the software ecosystem is evolving and we should take advantage of that.

dshean commented 4 years ago

An official conda-forge ASP/ISIS install would be fantastic. Bonus for ASP Windows build, which would definitely expand the user base.

jomey commented 4 years ago

Started an initial conversation with @ocefpaf and how he could see a path for ASP to be available as a conda package. Hopefully there will be not too many custom recipes.

oleg-alexandrov commented 4 years ago

Any thoughts and ideas are appreciated. I think the core stereo and bundle adjustment tool would not need any custom packages. Those are needed for pc_align and camera_solve, which could be dealt with later.

One issue I ran into recently was that the imagemagick on conda-forge could not gets its dependencies reconciled with the system I inherited from ISIS. But this one is again needed just for peripheral tools.

The key check would be if the GDAL in conda-forge can play nice with the rest of our conda packages and if ASP would build with that version (we now are at GDAL 2.0, I don't know what changed in the latest GDAL, which is 3.0). If there is no big pain here, other things are manageable.

In the meantime I learned that conda-build is good at not just building but packaging as well, so dealing with rpaths and other portability adjustments. That is also some logic we have a homegrown tool for and I'd be happy to have it offloaded..

jlaura commented 4 years ago

Some thoughts:

oleg-alexandrov commented 4 years ago

Thanks a lot. Good to know about GDAL.

Yes, hoping to have ASP and ISIS in the same env, it just makes sense.

I guess we will ship our stuff as a single package. I meant to say, we've been doing our homegrown packaging, and that is extra code to maintain.

We already have cmake logic to find ISIS. Not something terribly standard but it works.

Good to know about having to change the testing framework.

All this will add up to some work, especially since some of these things I will have to learn about and hack around. But will make longer term maintenance much easier.

jomey commented 3 years ago

Hey Oleg, Awesome to see the added support to install asp via conda. 🎉 Are there more plans on using conda or is this ticket considered closed?

oleg-alexandrov commented 3 years ago

Good point. Conda support has been implemented.

There are probably things to do, particularly, making ASP and GDAL live in the same world, once that is figured by ISIS, but that is for later.