Sunday, February 15, 2009

Spectral Python - Hyperspectral that is...

Spectral Python or "SPy" for short is a labor of love by Thomas Boggs. It is also one of the .001% of Python
projects that make this and not or

SPy has been around for about 7 years for remote sensing using hyperspectral (or multispectral) data. Amazingly SPy has only one dependency - NumPy. This lone dependency means Thomas wrote his own drivers for the supported raster formats! I mean who does that? Besides Frank Warmerdam, I thought everyone just plugged in GDAL/OGR. Seriously though - it makes sense.

In the GIS world data needs to be reasonably put together to do some useful GIS analysis whereas in true remote sensing every pixel counts and even minor errors in the data can lead to large errors in the end product. So SPy uses pure Python drivers to load the following file types into NumPy: AVIRIS, ERDAS .LAN, ENVI headers and data, pure BSQ, BIL, and BIP files.

SPy performs a variety of remote sensing operations including supervised and unsupervised classifications, NDVIs, hypercube renderings, and more.

At NVision our work often leads into precision agriculture. In 2003 we built a large, web-based precision Ag system for InTime Inc. in Cleveland, Miss. We were working with a lot of NDVIs and classified NDVIs using InTime's prototype system and the flashy, new, web-based processing system we were building for them. Our deadline was the growing season in 2003 and the development pace was frantic. We were testing the remote sensing output of the two in-house systems against the output of as many tools developed by other people that we could.
During this time I found SPy and used it as part of our test suite.

Our software worked, we shipped it on time, and InTime is now one of the most successful companies in their industry. But I never forgot SPy and sent Thomas an e-mail after the project ended. I was surprised to find it back then because it didn't show up in the usual forums or Google searches. Even now it lingers in obscurity. Try searching for "Python remote sensing" or "Python ndvi" and you won't see it readily. I was happy to see Thomas is still updating the software as late at Feb. 2008 so here's another Google hook for it.

No comments:

Post a Comment