xRoute calculateRoute not using Roundabout for turn

This forum deals with any kind of routing computation whether it is simple A:B-routing, calculation of isochrones, simple matrix computation or nearest search.

xRoute calculateRoute not using Roundabout for turn

Postby Ries » Fri Aug 02, 2019 12:22 pm

Hi,

I have a problem with xRoute's calculateRoute function: Having three waypoints the calculated route makes a long detour instead of using a roundabout for a much shorter route (on the attached image I have marked the expected route in green).

Any help/pointers would be appreciated.

Json Request:
Code: Select all
{
  "waypoints": [
    {
      "$type": "WaypointDesc",
      "linkType": "NEXT_SEGMENT",
      "fuzzyRadius": 0,
      "coords": [
        {
          "$type": "Point",
          "point": {
            "$type": "PlainPoint",
            "x":   10.805523,
            "y": 53.696013
          }
        }
      ]
    },
    {
      "$type": "WaypointDesc",
      "linkType": "NEXT_SEGMENT",
      "fuzzyRadius": 0,
      "coords": [
        {
          "$type": "Point",
          "point": {
            "$type": "PlainPoint",
            "x": 10.80550016454624,
            "y": 53.696549005418177

          }
        }
      ]
    },
    {
      "$type": "WaypointDesc",
      "linkType": "NEXT_SEGMENT",
      "fuzzyRadius": 0,
      "coords": [
        {
          "$type": "Point",
          "point": {
            "$type": "PlainPoint",
            "x": 10.805411578124581,
            "y": 53.695153428461083

           
          }
        }
      ]
    }
  ],
  "exceptionPaths": null,
  "details": {
    "manoeuvres": true,
    "polygon": true,
    "detailLevel": "STANDARD",
    "segments": true,
    "featureDescriptions": true
  },
  "callerContext": {
    "properties": [
      {
        "key": "CoordFormat",
        "value": "OG_GEODECIMAL"
      },
      {
        "key": "ResponseGeometry",
        "value": "WKB"
      },
      {
        "key": "Profile",
        "value": "Truck"
      }
    ]
  }
}


Image
Ries
 
Posts: 6
Joined: Wed Aug 16, 2017 7:57 am

Re: xRoute calculateRoute not using Roundabout for turn

Postby Bernd Welter » Mon Aug 05, 2019 1:59 pm

Hello Tobias,

which map (or Service URL) do you use?
WHat happens if you add a point of the roundabout to the input waypoints list?

Best regards,
Bernd
Bernd Welter
Senior Technical Consultant Developer Components
PTV GROUP - Germany

Bernd at Youtube
User avatar
Bernd Welter
Site Admin
 
Posts: 1370
Joined: Mon Apr 14, 2014 10:28 am

Re: xRoute calculateRoute not using Roundabout for turn

Postby Bernd Welter » Mon Aug 05, 2019 2:09 pm

Hi again,

I reproduced the scenario on the following service URL:
https://api-test.cloud.ptvgroup.com/pag ... quest.html
4stops.PNG
shorter distance (496m) but longer period (112sec)
3stops.PNG
longer distance (512m), but shorter period (105sec)

So by optimizing "by period" you get the track without the roundabout...

Any further questions?

Best regards,
Bernd
Bernd Welter
Senior Technical Consultant Developer Components
PTV GROUP - Germany

Bernd at Youtube
User avatar
Bernd Welter
Site Admin
 
Posts: 1370
Joined: Mon Apr 14, 2014 10:28 am

Re: xRoute calculateRoute not using Roundabout for turn

Postby Ries » Tue Aug 13, 2019 1:03 pm

Hi Bernd,

thanks for your reply, but it does not quite capture my problem.
In your case the difference between the two routes is only 7 seconds / 16 meters and depending on distance or time one or the other route is better.

However in my case, as displayed on the screenshot in my original post, the computed route is much worse in time as well as distance.

Computed Route (red): distance: 2869, time: 398
Expected Route (green): distance: ~568, time: ~86

I'm using the PTV xServer Raw Request Runner on a local server (JSON, xRoute, calculateRoute).

Best regards, Tobias
Ries
 
Posts: 6
Joined: Wed Aug 16, 2017 7:57 am

Re: xRoute calculateRoute not using Roundabout for turn

Postby Bernd Welter » Mon Aug 26, 2019 11:45 am

Hello Tobias,

which map is in use?

The screenshots on your map look like there's an older map in use - some roads are missing.

This doesn't answer the question as a whole but I need to know it to understand/reproduce the whole story,

Bernd
Bernd Welter
Senior Technical Consultant Developer Components
PTV GROUP - Germany

Bernd at Youtube
User avatar
Bernd Welter
Site Admin
 
Posts: 1370
Joined: Mon Apr 14, 2014 10:28 am

Re: xRoute calculateRoute not using Roundabout for turn

Postby frs » Tue Aug 27, 2019 8:22 am

Hi,

probably this is due to the "fast turning ban heuristic" which is enabled by default. It can be disabled with the routing profile parameter useFastTurningBanHeuristic (https://api-test.cloud.ptvgroup.com/manual/Content/Profile-Documentation/xserverbundle/Routing_xsd.html#Routing_Routing_Algorithm_useFastTurningBanHeuristic). The parameter can be set for example by the following caller context property ProfileXMLSnippet in the request:

Code: Select all
{
  "key": "ProfileXMLSnippet",
  "value": "<Profile><Routing majorVersion=\"2\" minorVersion=\"0\"><Algorithm useFastTurningBanHeuristic=\"false\"/></Routing></Profile>"   
}


Note that disabling the fast turning ban heuristic has an impact on the routing performance, the calculation time can increase by a factor of 2.

Hope that helps, best regards,

Frank
Frank Schulz
Senior Software Engineer
Logistics Software
PTV GROUP - Germany
frs
 
Posts: 6
Joined: Tue Jan 20, 2015 4:00 pm

Re: xRoute calculateRoute not using Roundabout for turn

Postby Ries » Fri Sep 13, 2019 11:08 am

Hi Frank,

Sorry for the delayed response.

Using your snippet results in the expected route :D

We will also update the map as proposed by Bernd (currently we use the map from Here: EUR2018_2aH_Master.zip with PTV xServer Bundle 1.24.0.4).

Thanks for your help,
Tobias
Ries
 
Posts: 6
Joined: Wed Aug 16, 2017 7:57 am


Return to PTV xRouteServer

cron