[OSRM-talk] Working with profiles and routes

2016-10-04 Thread Pedro Luiz Cumino
Hi all,
I'm new in here.

I'm trying to use the different lua profiles given by the project.
Before running the project I used the following commands inside the
'/build' directory in order to build the engine itself:

   - osrm-extract -p ../profiles/foot.lua bremen-latest.osm.pbf
   - osrm-contract bremen-latest.osrm
   - osrm-routed bremen-latest.osrm

At first, I made two requests with the same starting point and destination
as shown below.

   -
   
http://router.project-osrm.org/route/v1/driving/13.388860,52.517037;13.397634,52.529407;13.428555,52.523219?overview=false
   -
   
http://router.project-osrm.org/route/v1/foot/13.388860,52.517037;13.397634,52.529407;13.428555,52.523219?overview=false

However, the results given were exactly the same. Both JSON objects I
received showed the same duration. I didn't change any profile yet. But I
checked that there are different speeds. So there must be a difference at
least in the route duration.

Subsequently, after trying all the possible profiles, I realised that even
if I request using a random string value, the result will always be the
same.

Even so, I tried to use the original project server in order to compare
with the results given by the local server installed. The request URLs were:

   -
   
http://router.project-osrm.org/route/v1/foot/13.388860,52.517037;13.397634,52.529407;13.428555,52.523219?overview=false
   -
   
http://192.168.1.4:5000/route/v1/foot/13.388860,52.517037;13.397634,52.529407;13.428555,52.523219?overview=false

In this case, both results were totally different. Even if I change the
profile from 'foot' to 'driving', the result doesn't change. The result
from the local server shows me 0 for both duration and distance. It also
returns the string "{highway:cycleway}" as the name of all waypoints.

The requests were all made by the browser.
Am I missing something at the building procedure or during the requests?

-- 
Atenciosamente,
Kind regards,

Pedro Luiz Cumino.
___
OSRM-talk mailing list
OSRM-talk@openstreetmap.org
https://lists.openstreetmap.org/listinfo/osrm-talk


[OSRM-talk] Add costs on route sections.

2016-09-29 Thread Pedro Luiz Cumino
Hello all,


I'm a new user of the ORSM engine. I can run the basic setup and the server.


I'm working in build a route engine for web purpose in order to avoid
certain areas.


I'm wondering if it's possible to add costs to a certain group of route
sections. This costs must be considered during the route calculation. The
idea is better explained below:


I have the report coming from an external service, which comes as a JSON
object. It informs me the location where a sensor is present and must be
considered when calculating the route, like a cost to the lane stretch
pointed by the latitude and longitude from the sensors JSON object. The
sensors classify the region as *high*, *medium* or *low* level of
pollution. I need to set this cost to the lane stretch and then compare if
it's worthwhile to select the lane stretch where the issue is present or if
select another route is a better decision.



How open is the route solver service in order to implement this kind of
cost over a route? The idea at the end is to select the lower cost route by
comparing the issue level, the time travelling and the travelled distance
using my own algorithm.



The Figures 1 and 2 illustrate what I'm looking for. Figure 1 shows the
route A as the best one to be chosen, even with an issue place on it (the
issue with the lowest level). The route B is the worst since it has the
highest issue level/cost. The route D is possible to reach the end, but the
cost would be too high to be chosen, what makes it the worst route. Figure
2 shows the route B as the best route to be chosen because the cost of the
issue on B is lower than the cost that the total distance of D represents.



Figure 1
<https://geonet.esri.com/servlet/JiveServlet/showImage/2-630854-217931/route-solution.gif>



Figure 2
<https://geonet.esri.com/servlet/JiveServlet/showImage/2-630854-217935/route-solution-withBarriers.gif>







In summary, I need a way to insert a cost to certain routes (using the
information from coming from another service) and then calculate the route
considering such costs. At the end, the algorithm to be implemented will
consider both issues and route distances.


Which files should I modify in order to accomplish it? Where can I find the
routing algorithm used by the engine?



Thanks in advance!

-- 
Atenciosamente,
Kind regards,

Pedro Luiz Cumino.
___
OSRM-talk mailing list
OSRM-talk@openstreetmap.org
https://lists.openstreetmap.org/listinfo/osrm-talk