This is a project created at the Lausanne camp of the International Space Apps Challenge 2012.
We decided to create a mobile web app that allows users on mobile phones and tablets to browse the very high resolution map images of Mars, and a Web Standards based platform on top of which we would develop creative educational/citizen science applications.
Advisors: Dr. Anton Ivanov, EPFL Dr. Prasenjit Saha, University of Zurich
- Get the list of all images from http://hirise-pds.lpl.arizona.edu/PDS/RDR
- Process the JP2 format, programmatically extract a tileset of each image
- Web hosting of the tiles in a mobile HTML5 application to browse the map
- Extraction of relevant Mars metadata (geo-coordinates, features, etc.) from PDS
- Visualization of terrestrial objects as an overlay on the map for educational purposes
Our initial goal was to access the open data sets, in this case a combination of metadata labels in structured text format, and highly detailed images in various resolutions - from <1 MB JPEG thumbnails to 1900 MB full size JPEG2000 maps. The reason these maps are so huge is because the HiRISE experiment orbiting Mars takes photographs with a resolution of 25 cm! It is indeed possible to see medium sized boulders on these maps, and recently they have been used to detect cracks in the solar panels of the Voyager lander (still looking for the link to that news article).
Working with the image data proved to be a real challenge: despite working on current MacBooks and having access to a high bandwidth network at the EPFL, we struggled to find a way to process the full-size images in a reasonable time frame. David's machine crashed and burned as he tried one tool after another to read the files. Sometimes the applications would hang after 15-30 minutes of processing, and we quickly used up the full extents of the VPS compute instance kindly provided to us by Evolucix. In the end we could not come up with a system that works reliably with images greater than 300 MB in size. Lesson learned 1: having compute clusters and graphics workstations available before attempting to work with a project like this next time! Lesson learned 2: scientific data and commercial grade processing tools don't always make a match.
On the mapping side, Steven and Oleg deployed a standard solution based on the OpenStreetMap community OpenLayers libraries and tools. The challenge here was to understand how to work with space data with usually Earth-bound Geographical Information System (GIS) tools. We got some help from experts who tried to explain to us how the planetary radii and centroids should help us obtain a mapping of the coordinate systems, but this was all well above the expertise of our team members. In the end we had to use lots of guesstimates and experiment with the map boundaries until we could get some kind of overlap, which was definitely un-scientific.
To parse the metadata, Onja wrote a PHP script that made remote calls to the Planetary Data System servers, parsed the structured text, and output XML (the goal being RDF/XML). This was a more straightforward part of the project, but one which we gave too low a priority. In retrospect, it would have better idea to start with this, and have programmatic (API / semantic web) access to the data on the images and objects we were working with. This element boosts the educational aspect of our project significantly. A good reference on how this is currently used is the ENVI User Guide, a metadata browser capable of reading HiRISE data.
The easiest part of the solution was the mobile web app itself. Oleg quickly whipped up a jQuery Mobile framework and tweaked OpenLayers to work well inside of it. It was OpenLayers already excellent support for taps, swipes and pinches which allowed the mobile maps to look and feel as good as the native maps app inside of our solution.
We had lots of fun working on this Space Apps Challenge, and though the summit seems still above the clouds, we all learned much from it. Most of all, we all had a chance to have a real space science experience, both of the incredible opportunities it creates, and the frustratingly difficult challenges that are involved when breaking new ground. We are endeavoring to complete the five steps outlined in the process, and wish the HiRISE team and researchers around the world working with this exciting data the best of success in this incredible effort to become more familiar with the surface of another planet than we are of our own.
This project is licensed under the MIT License:
Copyright (c) 2012: David Portabella, Steven Suckow, Oleg Lavrovsky, Onja Ravelonjato:
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.