So, I hacked Google Maps tonight. Hammered out a Python script in about 10 minutes that fetches individual map tiles, then patches them together into one giant image. The result is a single image, 25600x25600 pixels in size (roughly 655 megapixels). If you printed it out, it would be almost 30ft by 30ft. It’s 57.6Mb and took just under 8 hours to generate. For reference, the image here is scaled to 1% of the original:
Also, there was a purpose to this. My robot project has a need for geolocation, but since it will likely operate over an ad hoc network in regions with no Internet connectivity, Google Maps and other such services are out.
I figured if I had a huge, high-res satellite map of, say, the entire Denver metro area, I could generate a matrix function wherein each pixel corresponds to a unique longitude-latitude pair. Then, based on the onboard GPS, the user interface would be able to overlay a marker on the map, centered on the appropriate pixel. Turns out it’s very expensive to acquire such imagery directly, hence this little script.
One major downside is that I didn’t capture the entire metro area. I’ll have to run some calculations and try again when I know I won’t need the computer for 12-14 hours.
Update: I would normally share the code or the resulting image, however it’s a bit of a gray area whether this is legally acceptable in this case. I feel my script falls under fair use of Google’s system, since it’s for my own personal study and use, and I’m not commercializing it. But making it all freely available to others who may not be as fair in their use could land me in some trouble. If you know how the read and write code, the results aren’t hard to replicate ;-)