10
votes
Accepted
TooBig: Increasing OSRM # of coordinates
If you're running your own instance of OSRM, you can set this in the arguments you pass to osrm-routed:
--max-viaroute-size
--max-trip-size
--max-table-size
--max-matching-size
Use osrm-routed --...
9
votes
Accepted
Query for WAY that connects two INTERSECTIONS
The following description assumes that you have a list of GPS positions, as well as the OSRM map matching service and Overpass API available.
(1) Use OSRM Map Matching service to identify nearest ...
5
votes
Accepted
Using OSRM to create isochrones in R potentially problematic at < 10 minutes drive time?
I think it is using the right point but is generalising the polygons differently.
I tried comparing your isochrones up to 60 minutes:
iso_orig <- osrmIsochrone(loc = c(locations$lon, locations$...
4
votes
Accepted
OSRM doesn't show actual route while plotting from osrm-backend JSON response
The difference is that you plot only the intersections, whereas the OSRM Demo Server plots the whole route.
To plot the whole route, use the geometry element in routes[0] in the JSON. The route is ...
4
votes
Adjust leaflet routing machine draw (animate) route speed
I achieved this animation using only CSS. See the following tutorial: https://css-tricks.com/svg-line-animation-works/#article-header-id-7 (Note: the tutorial covers other interesting line animations ...
3
votes
OSRM foot / walking profile avoiding trunk roads
Modify foot.lua like so:
speeds = Sequence {
highway = {
primary = walking_speed,
primary_link = walking_speed,
secondary = walking_speed,
secondary_link = ...
3
votes
OSM routing database with high quality data?
OSM data is typically always the same, independent of the provider or routing-engine. Routers can interpret this data in a different way and it is possible that providers will enhance / modify this ...
3
votes
Accepted
Connecting own OSRM server on leaflet routing machine?
You have to configure the settings as mentioned here. so it would be like this
L.Routing.control({
waypoints: [
L.latLng(57.74, 11.94),
L.latLng(57.6792, 11.949)
],
router:...
3
votes
Accepted
Full address from OSM data
For obtaining the full address you have to use a geocoder such as Nominatim. There are other geocoders for OSM available, too.
Also see your very similar question at help.openstreetmap.org.
3
votes
Accepted
OSRM how to use my own map
You have to change the used speed profile (defined in a .lua file) depending on the specific attributes of your edges/ways.
By default, car.lua considers edges with common OSM attributes like ...
3
votes
Using OSRM with big queries?
You will need to set up your own instance of OSRM for a 5000x5000 input matrix. The hosted version at router.project-osrm.org only supports small matrices.
When working with your own instance, you can ...
2
votes
getting street distances locally
Set up a local instance of one of the OSM-based routers, e.g. GraphHopper or OSRM. Then just use their APIs. There should be python-bindings for the most popular routers available.
2
votes
OSRM: no walking directions
The Project OSRM demo server only provides car directions.
If you want walking directions, you can either use a third-party hosted service (such as that provided by Mapbox, who develop OSRM), or run ...
2
votes
Accepted
OSRM server for public transport not a trip on roads by cars
Bus routes in OpenStreetMap are mapped with relations.
Historically OSRM has not supported route relations, and so bus routing has not been possible unless you were prepared to pre-process the .osm....
2
votes
OSRM server for public transport not a trip on roads by cars
As far as I'm aware, Bus is not an available parameter to be extracted via OSRM server. OSRM does not do transit routing.
As mentioned here as well Routing of Public Transport based on GTFS #1961
...
2
votes
Accepted
OSRM Table service returns empty array when I use a HTTP Server
Your latitude and longitude are in the incorrect order.
For example, this query works:
http://router.project-osrm.org/table/v1/driving/-71.1936,-30.59464;-71.21342,-30.60386;-71.18429,-30.58654;-71....
2
votes
Accepted
How can I change OSRM server with leaflet-routing-machine
You need to specify the address of the routing server you're using as per the Leaflet Routing Machine tutorial: https://www.liedman.net/leaflet-routing-machine/tutorials/alternative-routers/
Routing ...
2
votes
Accepted
Nodes returned by OSRM map match service not found in the PostGIS database
It looks like you are using the wrong table. To obtain the node information you are looking for, you should be using the planet_osm_node table. Read more here.
2
votes
Retrieve map matched ways (and not just nodes) using OSRM and Overpass API
tl;dr: You can't, feasibly, and you shouldn't, really.
But:
If all you want is OSM way ids of ways that have been traversed at least partially, cross reference your list of input nodes (those sent to ...
2
votes
Accepted
Calculate the correct OSRM route distance in OpenLayers?
feature.getGeomentry().getLength() uses the units of the view projection (see respective section of the OpenLayers 7 API Documentation), which is Web Mercator (EPSG:3857) in the provided example. To ...
1
vote
Is it possible to use OSRM in order to calculate routing into a building?
Yes, as the comments suggest this can be done.
What has to happen is that the base geometries if the stadium, zoo, or other, have to be linear and they have to have measures applied to them. Typically ...
1
vote
OSRM giving different results
Those are not the same coordinates. Like ThomasG77 pointed out in the comments, those latitudes are different. If you compare
http://osrm.stackbox.xyz/table/v1/driving/78.4444076,11.6000205;78....
1
vote
Service Area or Catchment Area in R
I'm not aware of an R package that does this in one simple step but some packages that may help are:
dodgr Which can do routing over route networks within R
opentripplanner Can interface with a ...
1
vote
Extracting OSRM PBF file using Docker osrm/osrm-backend image?
When using PowerShell on Windows the proper command needs to have quotes around the paths:
docker run -t -v "$(pwd):/data" osrm/osrm-backend osrm-extract -p "/opt/car.lua" "/data/california-latest....
1
vote
Adjust leaflet routing machine draw (animate) route speed
It appears that there isn't a single way approach to achieve the outcome you are seeking. However, that are several ways that you may be able to have the change to adjust the speed of your route ...
1
vote
Identify OSM road ids based on coordinates
I suggest using Overpass API. You can test it at https://overpass-turbo.eu/
There you can find which ways are around certain coordinates. For example:
[out:json];
way(around:50,-38.01261, -57....
1
vote
Identify OSM road ids based on coordinates
You can use route-annotator, which was developed for use with OSRM, to look up way data given a set of OSRM-generated coordinates: https://github.com/mapbox/route-annotator
1
vote
Generating route from user's current location to desired location on web map created in QGIS?
As suggested by Mesa you can start by generating a route request which should provide you with an output json that you can parse to retrieve the route. You can then create a vector layer and add it to ...
1
vote
Generate polygon automatically based on locations
To create a box snapped to streets, take a street layer, make the polylines into polygons. Intersect your points with those polygons; merge those blocks together. If the blocks don't connect, create ...
1
vote
Accepted
OSRM Map Matching Output explanation
Referring to your second question: an empty street name is returned when the road where your original point snapped to has no name. In your example, the point is on a small service road without a name....
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
open-source-routing-machine × 81openstreetmap × 31
routing × 17
leaflet × 14
r × 7
map-matching × 7
postgis × 6
openlayers × 5
json × 4
isochrone × 4
navigation × 4
overpass-api × 3
osmosis × 3
qgis × 2
line × 2
pgrouting × 2
geocoding × 2
ubuntu × 2
route × 2
srtm × 2
server × 2
nodes × 2
docker × 2
graphhopper × 2
osmium × 2