source: subversion/applications/rendering/genericHeatmapRender/readme.txt @ 29094

Last change on this file since 29094 was 16175, checked in by stevefaeembra, 10 years ago

readme fix, added flickr api as prerequisite

File size: 2.8 KB
Line 
1Introduction
2============
3
4This code was an attempt at generating 'most photographed' heatmaps using the flickR API.
5The code has been donated in the hope that the OpenStreetMap community can find uses for it in
6other projects. I've separated out the various functions (location gathering, plotting and KML).
7
8Currently the data source is flickR, and output pngs have *manually* been merged with OSM exports
9(or displayed in KML using the supplied class).
10
11However I hope to remedy this and download appropriate images from OSM, maybe using PIL to do the overlay.
12Any pointers welcome!
13
14I'm new to FOSS and OSM, so any style/coding suggestions are welcome :)
15
16Quick Tour
17==========
18Location.py - a generic 'point marker'
19
20locationFinder.py - responsible for generating a list of Location objects of interest.
21This is a generic class which should be sub-classed for other applications.
22
23locationFinder_flickr_locations.py - an example sub-class, implementing a flickR API geo query.
24(*Needs flickR API key*)
25
26heatmapPNGgenerator.py - generates a heatmap using matplotlib and a supplied locationFinder object.
27Saves png file to given location.
28
29KMLGenerator.py - given a locationFinder, a PNG file and a filename for the KML, saves a KML file with
30an image overlay and placemarkers for the individual locations.
31
32heatmappr.py is an end-to-end example/demo.
33
34Prerequisites
35=============
36
37These are the libraries you'll need to install
38your mileage may vary if you use older libs than this.
39
40Matplotlib 0.98.5.2 (http://matplotlib.sourceforge.net/users/installing.html)
41Numpy 1.3.0
42Python Flickr API (http://stuvel.eu/projects/flickrapi)
43
44You'll need to be using Python 2.5 or later.
45
46If you wish to try using the example (which uses the flickR API) you will need
47to get yourself a flickR API key. If you're a flickR user, visit the following URL..
48
49http://www.flickr.com/services/api/keys/apply/
50
51..to apply for a key.
52
53Be careful not to commit a copy of locationFinder_flickr_locations.py with
54a copy of your API, as it this will breach the flickr api TOS.
55
56Known Issues
57============
58A number of asserts have been put in place to cope with known issues.
59
60Google Earth Issues with KML overlays
61========================
62My version of GE for testing is 5.0.11733.9347
63
64Sometimes, the photo overlay does not appear, but the pushpins do.
65
66If this happens, first try this:-
67
68[1] Right-click on the file in the places palette, then choose 'Revert'. This reloads the file.
69    You should also do this if you change the .kml file and want to see the changes in GE.
70[2] If that doesn't work, right click the file in places palette, and choose 'Delete'. This doesn't delete
71    the file, but simply removes it from the 'My Places' or 'My Temporary Places' folder.
72    Then open the file again.
73[3] If that doesn't work, try restarting GE.
Note: See TracBrowser for help on using the repository browser.