Decoding the Google Maps embedded parameters

This intermediate is not the final answer, and the sequel follows)), just some thoughts Undocumented method. (with ftid instead of place_id parameter) Places API Web Service No warranty in future: https://maps.googleapis.com/maps/api/place/details/json?key=YOUR_API_KEY&ftid=0xd62377123a70817:0x85e89b65fcf7c648& The documented request is: https://maps.googleapis.com/maps/api/place/details/json?key=YOUR_API_KEY&placeid=ChIJFwinI3E3Yg0RSMb3_GWb6IU Need API KEY for this requests Setting up API keys Answer from Google: (JSON – light parsing) { “html_attributions”: … Read more

How to calculate the area of a polygon on the earth’s surface using python?

Let’s say you have a representation of the state of Colorado in GeoJSON format {“type”: “Polygon”, “coordinates”: [[ [-102.05, 41.0], [-102.05, 37.0], [-109.05, 37.0], [-109.05, 41.0] ]]} All coordinates are longitude, latitude. You can use pyproj to project the coordinates and Shapely to find the area of any projected polygon: co = {“type”: “Polygon”, “coordinates”: … Read more

Construct DbGeography point from Latitude and Longitude doubles?

In short, no there isn’t. SqlGeography has an appropriate method: Microsoft.SqlServer.Types.SqlGeography.Point(latitude, longitude, srid); … but you would then have to convert to DbGeography anyway. If you are interested in this, see a previous answer of mine on converting: DbGeography to SqlGeography (and back) That said, I completely agree with Raphael Althaus in that you should … Read more

R-Tree and Quadtree Comparison

Here’s paper which has pretty nice comparison of QuadTrees and R Trees: Quadtree and R-tree Indexes in Oracle Spatial: A Comparison using GIS Data Some differences: Quadtrees require fine-tuning by choosing appropriate tiling level in order to optimize performance. No specific tuning is required for R-Trees. Quadtree can be implemented on top of existing B-tree. … Read more