I want to get all location within a particular radius distance. Which API should I use? I have the longitude and latitude of locations available.
You can use Gisgraphy. The best services for your specific case are
reversegeocoding or maybe the even better geolocalisation.
That's the page with the above APIs and it's well documented.
While this is the UserGuide for specific info on the service that you will choose.
The best IP geocode API that I've found is available from IPDATA.CO (www.ipdata.com). It's not free, but their rates are very reasonable, and it works really well.
Related
I saw in articles that OpenStreet map provides an API that, given a route with an origin and destination and multiple (unlimited?) waypoints it sorts the waypoints according to the best route.
I couldn't tell which endpoint it was. Could someone point me to the part of the documentation that explains how to achieve this? Is there a ruby gem that wraps up this endpoint request?
Thank you very much
This is the traveling salesman problem. There is more than one OSM-based router for solving this problem. According to a similar question at help.openstreetmap.org:
All major OSM routing engines support this:
Mapzen's Valhalla
("Valhalla also includes tools like time+distance matrix computation,
isochrones, elevation sampling, map matching and tour optimization
(Travelling Salesman)."),
Mapbox's
OSRM ("The
trip plugin solves the Traveling Salesman Problem using a greedy
heuristic...")
Graphhopper uses the JSPrit
library
for route optimization ("TSP problem can be modelled by defining a
vehicle routing problem...")
None of these services have a free and unlimited online offering (it
would quickly be abused by people trying to save on their own AWS
cost). Mapzen has an offer where you register a free API key and use
that. OSRM doesn't need an API key, you can just use it. Graphhopper
requires registration and while they have a free trial, I don't think
they have a free tier.
All three are Open Source and you can install and use them without
limits locally.
For GraphHopper take a look at the Route Optimization API. For OSRM see the trip plugin.
Set up your own OpenStreetMap server - this way you won't be incurring data access fees every time your app needs to run maps queries.
Specifically, install the Valhalla maps server. It's a free application. Best to install it on a Linux box:
https://github.com/valhalla/valhalla
Or download and run the docker image in Docker instead:
https://hub.docker.com/r/abihf/valhalla/
https://github.com/interline-io/valhalla-docker
The server provides an API specifically for ordering waypoints:
https://valhalla.readthedocs.io/en/latest/api/optimized/api-reference/
I am working on a family networking app for Android that enables family members to share their location and track location of others simultaneously. You can suppose that this app is similar with Life360 or Sygic Family Locator. At first, I determined to use a MBaaS and then I completed its coding by using Parse. However, I realized that although a user read and write geolocation data per minute (of course, in some cases geolocation data is sent less frequently), the request traffic exceeds my forward-looking expectations. For this reason, I want to develop a well-grounded system but I have some doubts about whether Parse can still do its duty if number of users increases to 100-500k.
Considering all these, I am looking for an alternative method/service to set such a system. I think using a backend service like Parse is a moderate solution but not the best one. What are the possible ways to achieve this from bad to good? To exemplify, one of my friends say that I can use Sinch which is an instant messaging service in background between users that set the price considering number of active users. Nevertheless, it sounds weird to me, I have never seen such a usage of an instant messaging service as he said.
Your comments and suggestions will be highly appreciated. Thank you in advance.
Well sinch wouldn't handle location updates or storing of location data, that would be parse you are asking about.
And since you implied that the requests would be to much for your username maybe I wrongly assumed price was the problem with parse.
But to answer your question about sending location data I would probably throttle it if I where you to aile or so. No need for family members to know down to the feet in realtime. if there is a need for that I would probably inement a request method instead and ask the user for location when someone is interested.
I am working with geocoder gem and like to process more number of requests from an IP. By default Google API provides only 2500 requests per day.
Please share your thoughts on how I can do more requests than the limit?
As stated before: Using only Google API the only way around the limitation is to pay for it. Or in a more shady way make the requests form more than one IP/API-Key which i would not recommend.
But to stay on the save side i would suggest mixing the services up since there a few more Geocoding APIs out there - for free.
With the right gem mixing them is also not a big issue:
http://www.rubygeocoder.com/
Supports a couple of them with a nice interface. You would pretty much only have to add some rate-limiting counters making sure you stay within the limits of each provider.
Or go the heavy way of implementing your own geocoding. With for example your own running Openstreetmaps database. The Database can be downloaded here: http://wiki.openstreetmap.org/wiki/Planet.osm#Worldwide_data
Which is the best way depends on what your actual requirements are and what ressources you have available.
is there a way to find out the location without using GPS on the Windows phone 7. It's okay if ts approximate, as i want to get the city (not the precise longitude and latitude).
Use of the location API within Windows Phone 7 is described in this collection of MSDN articles. Pay special attention to the section in Location Programming: Best Practices about the right level of accuracy. When setting the GeoCoordinateWatcher to default instead of high accuracy it is optimzed for power-usage. In practice this means it will only resort to GPS of there is nothing else available.
All use of the location API will require you to ask the user for permission to use their location. The only way to get around that (if you really want to) is by using one of the tricks described in other answers.
I think it is not allowed by their policy. You have to use their Location services and include a on/off switch as well as privacy policy.
If you'll try to work around that, it may not pass the certification.
If you can find out the IP address assigned by an ISP (such as the IP address of the wireless router you connect to or the phone itself if it is on 4G (?)), you can use a GeoIP look-up. demo: http://www.geoiptool.com/
I want a real and honest opinion what do you think of Google Visualization API?
Is it reliable to use becasue when i was reading the documentation i noticed that there are alot of issues and defects to overcome and can i use it to retrieve data from mysql database.
Thank you.
I am currently evaluating it. As compared to other javascript data visualization frameworks, i think it has a lot going for it:
dynamic loading is built-in
diverse, many things to choose from.
looks really great!
framework mostly takes care of picking whatever implementation fits the current browser
service based, you don't need to download anything in advance
unified data source: just create one data table, and have multiple visalizations draw from that data.
As a disadvantage, I'd like to mention security. I mean, because it's all service based, it is not so transparent what happens when you pass data into these API calls. And as far as I know, the API is free, but not open source, so I can't really check what is going on behind the covers.
I think the Google visualization API really shines if you want to very quickly whip up a visualization gadget for use in a blog or so, and you are not interested in deploying all kinds of plugins and libraries (for eaxmple, with jQuery based frameworks, you need may need to manage multitple javascript libraries that work together to deliver the goods). If on the other hand you are creating an application that you want to sell, you might want to keep more control over what components you are using, and I would probably consider using something like Flot
But like I said, I am only evaluation atm, I am not using this in production.
Works really great for me. Can be customized fairly easily. Haven't seen any scaling issues. No data is exposed so security should not be an issue. - Arunabh Das
One point I want to add here is that, Google Visualization API cannot be downloaded, its not available for offline usage. So application which is going to use it must be always connected to internet, otherwise I think it wont be able to render charts. Due
to this limitation, this API cannot be used in some applications for which internet connection is not available.
I am currently working on a web based application that will have the Google Visualization API added to it and from the perspective of a developer the Google Visualization API is very limited in what you can do with each individual Chart and if I had a choice I would probably look at dojox charting just because of the extra flexibility that the framework gives you.
If you are doing any kind of large web application that will use charting extensively then I would not recommend the Google Visualizations API it does not have enough flexibility for a large web application.
I am using Google Visualization API and I want to stress that they still won't let you download it, which means if their servers are down, your app will be down if you depend on it. I have been using it for about 4 months, and they have crashed once me once so I'd say they pretty reliable and their documentation is really nice.