Preface |
|
1 | (6) |
|
Chapter 1 Geo-Spatial Development Using Python |
|
|
7 | (14) |
|
|
7 | (2) |
|
|
9 | (2) |
|
Applications of geo-spatial development |
|
|
11 | (6) |
|
Analyzing geo-spatial data |
|
|
12 | (1) |
|
Visualizing geo-spatial data |
|
|
13 | (3) |
|
Creating a geo-spatial mash-up |
|
|
16 | (1) |
|
|
17 | (2) |
|
|
19 | (2) |
|
|
21 | (26) |
|
|
21 | (16) |
|
|
22 | (3) |
|
|
25 | (2) |
|
|
27 | (1) |
|
|
28 | (1) |
|
|
29 | (2) |
|
|
31 | (1) |
|
|
31 | (1) |
|
The nature of map projections |
|
|
32 | (1) |
|
|
32 | (3) |
|
|
35 | (1) |
|
|
36 | (1) |
|
|
37 | (2) |
|
Working with GIS data manually |
|
|
39 | (7) |
|
|
46 | (1) |
|
Chapter 3 Python Libraries for Geo-Spatial Development |
|
|
47 | (24) |
|
Reading and writing geo-spatial data |
|
|
47 | (7) |
|
|
48 | (1) |
|
|
48 | (2) |
|
|
50 | (1) |
|
|
51 | (1) |
|
|
52 | (1) |
|
|
53 | (1) |
|
|
53 | (1) |
|
|
54 | (5) |
|
|
54 | (1) |
|
|
54 | (1) |
|
|
55 | (1) |
|
|
56 | (1) |
|
|
57 | (1) |
|
|
58 | (1) |
|
|
58 | (1) |
|
Analyzing and manipulating geo-spatial data |
|
|
59 | (4) |
|
|
59 | (1) |
|
|
60 | (1) |
|
|
61 | (1) |
|
|
62 | (1) |
|
|
62 | (1) |
|
Visualizing geo-spatial data |
|
|
63 | (5) |
|
|
63 | (1) |
|
|
64 | (2) |
|
|
66 | (1) |
|
|
67 | (1) |
|
|
68 | (1) |
|
|
68 | (3) |
|
Chapter 4 Sources of Geo-Spatial Data |
|
|
71 | (30) |
|
Sources of geo-spatial data in vector format |
|
|
72 | (13) |
|
|
72 | (1) |
|
|
73 | (1) |
|
Obtaining and using OpenStreetMap data |
|
|
74 | (2) |
|
|
76 | (1) |
|
|
77 | (1) |
|
Obtaining and using TIGER data |
|
|
78 | (1) |
|
Digital Chart of the World |
|
|
79 | (1) |
|
|
80 | (1) |
|
|
80 | (1) |
|
Obtaining and using DCW data |
|
|
80 | (2) |
|
|
82 | (1) |
|
|
83 | (1) |
|
Obtaining the GSHHS database |
|
|
84 | (1) |
|
|
84 | (1) |
|
|
85 | (1) |
|
Obtaining the World Borders Dataset |
|
|
85 | (1) |
|
Sources of geo-spatial data in raster format |
|
|
85 | (9) |
|
|
86 | (1) |
|
|
86 | (1) |
|
Obtaining Landsat imagery |
|
|
87 | (3) |
|
|
90 | (1) |
|
|
90 | (1) |
|
Obtaining and using GLOBE data |
|
|
91 | (1) |
|
National Elevation Dataset |
|
|
92 | (1) |
|
|
92 | (1) |
|
Obtaining and using NED data |
|
|
93 | (1) |
|
Sources of other types of geo-spatial data |
|
|
94 | (4) |
|
|
94 | (1) |
|
|
95 | (1) |
|
Obtaining and using GEOnet Names Server data |
|
|
95 | (1) |
|
|
96 | (1) |
|
|
97 | (1) |
|
Obtaining and using GNIS data |
|
|
97 | (1) |
|
|
98 | (3) |
|
Chapter 5 Working with Geo-Spatial Data in Python |
|
|
101 | (44) |
|
|
101 | (1) |
|
Reading and writing geo-spatial data |
|
|
102 | (13) |
|
Task: Calculate the bounding box for each country in the world |
|
|
102 | (2) |
|
Task: Save the country bounding boxes into a Shapefile |
|
|
104 | (4) |
|
Task: Analyze height data using a digital elevation map |
|
|
108 | (7) |
|
Changing datums and projections |
|
|
115 | (7) |
|
Task: Change projections to combine Shapefiles using geographic and UTM coordinates |
|
|
115 | (4) |
|
Task: Change datums to allow older and newer TIGER data to be combined |
|
|
119 | (3) |
|
Representing and storing geo-spatial data |
|
|
122 | (5) |
|
Task: Calculate the border between Thailand and Myanmar |
|
|
123 | (3) |
|
Task: Save geometries into a text file |
|
|
126 | (1) |
|
Working with Shapely geometries |
|
|
127 | (5) |
|
Task: Identify parks in or near urban areas |
|
|
128 | (4) |
|
Converting and standardizing units of geometry and distance |
|
|
132 | (9) |
|
Task: Calculate the length of the Thai-Myanmar border |
|
|
133 | (6) |
|
Task: Find a point 132.7 kilometers west of Soshone, California |
|
|
139 | (2) |
|
|
141 | (2) |
|
|
143 | (2) |
|
Chapter 6 GIS in the Database |
|
|
145 | (46) |
|
Spatially-enabled databases |
|
|
145 | (1) |
|
|
146 | (3) |
|
Open source spatially-enabled databases |
|
|
149 | (15) |
|
|
149 | (3) |
|
|
152 | (1) |
|
Installing and configuring PostGIS |
|
|
152 | (3) |
|
|
155 | (2) |
|
|
157 | (1) |
|
Advanced PostGIS features |
|
|
157 | (1) |
|
|
158 | (1) |
|
|
158 | (1) |
|
|
159 | (1) |
|
Accessing SpatiaLite from Python |
|
|
160 | (1) |
|
|
160 | (1) |
|
|
161 | (2) |
|
|
163 | (1) |
|
Commercial spatially-enabled databases |
|
|
164 | (1) |
|
|
164 | (1) |
|
|
165 | (1) |
|
Recommended best practices |
|
|
165 | (13) |
|
Use the database to keep track of spatial references |
|
|
166 | (2) |
|
Use the appropriate spatial reference for your data |
|
|
168 | (1) |
|
Option 1 Use a database that supports geographies |
|
|
169 | (1) |
|
Option 2 Transform features as required |
|
|
169 | (1) |
|
Option 3 Transform features from the outset |
|
|
169 | (1) |
|
When to use unprojected coordinates |
|
|
170 | (1) |
|
Avoid on-the-fly transformations within a query |
|
|
170 | (1) |
|
Don't create geometries within a query |
|
|
171 | (1) |
|
Use spatial indexes appropriately |
|
|
172 | (1) |
|
Know the limits of your database's query optimizer |
|
|
173 | (1) |
|
|
174 | (1) |
|
|
175 | (2) |
|
|
177 | (1) |
|
Working with geo-spatial databases using Python |
|
|
178 | (11) |
|
|
179 | (1) |
|
|
179 | (3) |
|
|
182 | (2) |
|
|
184 | (4) |
|
|
188 | (1) |
|
|
189 | (2) |
|
Chapter 7 Working with Spatial Data |
|
|
191 | (68) |
|
|
191 | (4) |
|
Designing and building the database |
|
|
195 | (4) |
|
|
199 | (2) |
|
|
200 | (1) |
|
|
200 | (1) |
|
|
200 | (1) |
|
|
200 | (1) |
|
|
201 | (9) |
|
|
201 | (2) |
|
|
203 | (2) |
|
|
205 | (3) |
|
|
208 | (2) |
|
Implementing the DISTAL application |
|
|
210 | (25) |
|
The "Select Country" script |
|
|
212 | (2) |
|
|
214 | (1) |
|
Calculating the bounding box |
|
|
215 | (1) |
|
Calculating the map's dimensions |
|
|
216 | (2) |
|
Setting up the datasource |
|
|
218 | (2) |
|
|
220 | (3) |
|
The "Show Results" script |
|
|
223 | (1) |
|
Identifying the clicked-on point |
|
|
223 | (2) |
|
Identifying features by distance |
|
|
225 | (8) |
|
|
233 | (2) |
|
Application review and improvements |
|
|
235 | (22) |
|
|
236 | (1) |
|
|
237 | (1) |
|
|
237 | (1) |
|
Lat/Long coordinate problems |
|
|
238 | (1) |
|
|
239 | (1) |
|
|
240 | (2) |
|
|
242 | (2) |
|
Calculating the tiled shorelines |
|
|
244 | (6) |
|
Using the tiled shorelines |
|
|
250 | (2) |
|
Analyzing the performance improvement |
|
|
252 | (1) |
|
Further performance improvements |
|
|
252 | (1) |
|
|
253 | (4) |
|
|
257 | (2) |
|
Chapter 8 Using Python and Mapnik to Generate Maps |
|
|
259 | (62) |
|
|
260 | (5) |
|
|
265 | (4) |
|
|
269 | (40) |
|
|
269 | (1) |
|
|
270 | (1) |
|
|
270 | (2) |
|
|
272 | (1) |
|
|
273 | (1) |
|
|
274 | (1) |
|
|
275 | (1) |
|
|
276 | (1) |
|
Rules, filters, and styles |
|
|
277 | (1) |
|
|
277 | (2) |
|
|
279 | (1) |
|
|
280 | (1) |
|
|
281 | (1) |
|
|
281 | (6) |
|
|
287 | (2) |
|
|
289 | (9) |
|
|
298 | (3) |
|
|
301 | (2) |
|
|
303 | (1) |
|
|
304 | (1) |
|
Map attributes and methods |
|
|
305 | (1) |
|
Layer attributes and methods |
|
|
306 | (1) |
|
|
307 | (2) |
|
|
309 | (5) |
|
The MapGenerator's interface |
|
|
309 | (1) |
|
Creating the main map layer |
|
|
310 | (2) |
|
Displaying points on the map |
|
|
312 | (1) |
|
|
313 | (1) |
|
What the map generator teaches us |
|
|
313 | (1) |
|
|
314 | (3) |
|
|
317 | (4) |
|
Chapter 9 Web Frameworks for Python Geo-Spatial Development |
|
|
321 | (42) |
|
|
322 | (12) |
|
Web application architecture |
|
|
322 | (1) |
|
|
322 | (1) |
|
|
323 | (1) |
|
Web application frameworks |
|
|
324 | (1) |
|
|
325 | (2) |
|
|
327 | (1) |
|
|
327 | (3) |
|
|
330 | (1) |
|
|
331 | (1) |
|
|
332 | (2) |
|
The geo-spatial web application stack |
|
|
334 | (1) |
|
|
334 | (10) |
|
The Web Map Service (WMS) protocol |
|
|
334 | (3) |
|
|
337 | (1) |
|
The Web Feature Service (WFS) protocol |
|
|
337 | (2) |
|
The TMS (Tile Map Service) protocol |
|
|
339 | (5) |
|
|
344 | (15) |
|
|
344 | (1) |
|
|
345 | (1) |
|
|
346 | (1) |
|
|
347 | (1) |
|
|
347 | (1) |
|
|
348 | (3) |
|
|
351 | (2) |
|
Web application frameworks |
|
|
353 | (1) |
|
|
353 | (3) |
|
|
356 | (1) |
|
|
357 | (2) |
|
|
359 | (4) |
|
Chapter 10 Putting it All Together: A Complete Mapping Application |
|
|
363 | (34) |
|
|
363 | (4) |
|
Designing the application |
|
|
367 | (4) |
|
|
367 | (2) |
|
|
369 | (1) |
|
|
370 | (1) |
|
|
371 | (1) |
|
|
371 | (1) |
|
The structure of a Django application |
|
|
372 | (7) |
|
|
374 | (1) |
|
|
374 | (3) |
|
|
377 | (2) |
|
|
379 | (1) |
|
Setting up the GeoDjango project |
|
|
380 | (2) |
|
Setting up the ShapeEditor application |
|
|
382 | (1) |
|
|
383 | (5) |
|
|
383 | (1) |
|
|
384 | (1) |
|
|
384 | (1) |
|
|
385 | (1) |
|
|
385 | (3) |
|
Playing with the admin system |
|
|
388 | (7) |
|
|
395 | (2) |
|
Chapter 11 ShapeEditor: Implementing List View, Import, and Export |
|
|
397 | (28) |
|
Implementing the "List Shapefiles" view |
|
|
397 | (4) |
|
|
401 | (16) |
|
The "import shapefile" form |
|
|
402 | (3) |
|
Extracting the uploaded Shapefile |
|
|
405 | (3) |
|
Importing the Shapefile's contents |
|
|
408 | (1) |
|
|
408 | (1) |
|
Add the Shapefile object to the database |
|
|
409 | (1) |
|
Define the Shapefile's attributes |
|
|
410 | (1) |
|
Store the Shapefile's features |
|
|
411 | (2) |
|
Store the Shapefile's attributes |
|
|
413 | (3) |
|
|
416 | (1) |
|
|
417 | (7) |
|
|
418 | (1) |
|
Saving the features into the Shapefile |
|
|
419 | (1) |
|
Saving the attributes into the Shapefile |
|
|
420 | (2) |
|
Compressing the Shapefile |
|
|
422 | (1) |
|
|
422 | (1) |
|
Returning the ZIP archive to the user |
|
|
423 | (1) |
|
|
424 | (1) |
|
Chapter 12 ShapeEditor: Selecting and Editing Features |
|
|
425 | (48) |
|
Selecting a feature to edit |
|
|
426 | (31) |
|
Implementing the Tile Map Server |
|
|
426 | (9) |
|
|
435 | (2) |
|
|
437 | (5) |
|
Using OpenLayers to display the map |
|
|
442 | (5) |
|
Intercepting mouse clicks |
|
|
447 | (4) |
|
Implementing the "find feature" view |
|
|
451 | (6) |
|
|
457 | (7) |
|
|
464 | (3) |
|
|
467 | (1) |
|
|
468 | (2) |
|
|
470 | (1) |
|
Further improvements and enhancements |
|
|
470 | (1) |
|
|
471 | (2) |
Index |
|
473 | |