Considering totalPermittedWeight problem

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.
Post Reply
qsku
Posts: 9
Joined: Thu Jun 16, 2016 8:08 am

Considering totalPermittedWeight problem

Post by qsku »

I have a problem to make xServer consider totalPermittedWeight while routing.
For testing purposes I'm using Request Runner at https://xroute-eu-n-test.cloud.ptvgroup ... quest.html
I'm passing totalPermittedWeight='7500' within ProfileXMLSnippet.
In spite of this parameter I'm getting segments marked by maxWeight=3500 in the response.
Why does it work that way?
Here is my test request:

Code: Select all

{
  "waypoints": [
    {
      "$type": "WaypointDesc",
      "linkType": "NEXT_SEGMENT",
      "fuzzyRadius": 0,
      "coords": [
        {
          "$type": "Point",
          "point": {
            "$type": "PlainPoint",
            "x": 5.904121700218979,
            "y": 49.91983561437948
          }
        }
      ]
    },
    {
      "$type": "WaypointDesc",
      "linkType": "NEXT_SEGMENT",
      "fuzzyRadius": 0,
      "coords": [
        {
          "$type": "Point",
          "point": {
            "$type": "PlainPoint",
            "x": 5.939734590555138,
            "y": 49.93496515392465
          }
        }
      ]
    }
  ],
  "options": [],
  "exceptionPaths": [],
  "details": {
    "manoeuvres": false,
    "texts": false,
    "nodes": false,
    "binaryPathDesc": false,
    "polygon": true,
    "detailLevel": "BORDERS",
    "dynamicInfo": false,
    "segments": true,
    "segmentAttributes": false,
    "manoeuvreAttributes": false,
    "brunnelManoeuvres": false,
    "urbanManoeuvres": false,
    "manoeuvreGroups": false,
    "tollManoeuvres": false,
    "boundingRectanglesC": 0,
    "boundingRectanglesOffset": 0,
    "totalRectangle": false,
    "featureDescriptions": true
  },
  "callerContext": {
    "properties": [
      {
        "key": "ResponseGeometry",
        "value": "PLAIN"
      },
      {
        "key": "CoordFormat",
        "value": "OG_GEODECIMAL"
      },
      {
        "key": "ProfileXMLSnippet",
        "value": "<?xml version='1.0' encoding='UTF-8'?><Profile xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:noNamespaceSchemaLocation=\"http:///xroute/schema/XRouteProfile.xsd\"><Routing majorVersion='2' minorVersion='0'><Vehicle><Physical><Weight totalPermittedWeight='7500'/></Physical></Vehicle><Course><AdditionalDataRules enabled='true'><VehicleSpecific enabled='true'><Malus residential='2501'/></VehicleSpecific></AdditionalDataRules></Course></Routing><FeatureLayer majorVersion='1' minorVersion='0'><Themes><Theme id='PTV_TruckAttributes' enabled='true'/></Themes></FeatureLayer></Profile>"
      }
    ]
  }
}
Edit by Joost: added code blocks for readability
Joost
Posts: 310
Joined: Fri Apr 25, 2014 1:46 pm

Re: Considering totalPermittedWeight problem

Post by Joost »

You are not referencing a specific vehicle profile for base values in you request. xRoute will then use the default profile witch is a carfast. Looking at the weight value you should reference a truckfast for more useful base values. When I tried your request with a truckfast profile, it is routing around the restriction.

Code: Select all

{
  "waypoints": [
    {
      "$type": "WaypointDesc",
      "linkType": "NEXT_SEGMENT",
      "fuzzyRadius": 0,
      "coords": [
        {
          "$type": "Point",
          "point": {
            "$type": "PlainPoint",
            "x": 5.904121700218979,
            "y": 49.91983561437948
          }
        }
      ]
    },
    {
      "$type": "WaypointDesc",
      "linkType": "NEXT_SEGMENT",
      "fuzzyRadius": 0,
      "coords": [
        {
          "$type": "Point",
          "point": {
            "$type": "PlainPoint",
            "x": 5.939734590555138,
            "y": 49.93496515392465
          }
        }
      ]
    }
  ],
  "options": [],
  "exceptionPaths": [],
  "details": {
    "manoeuvres": false,
    "texts": false,
    "nodes": false,
    "binaryPathDesc": false,
    "polygon": true,
    "detailLevel": "BORDERS",
    "dynamicInfo": false,
    "segments": true,
    "segmentAttributes": false,
    "manoeuvreAttributes": false,
    "brunnelManoeuvres": false,
    "urbanManoeuvres": false,
    "manoeuvreGroups": false,
    "tollManoeuvres": false,
    "boundingRectanglesC": 0,
    "boundingRectanglesOffset": 0,
    "totalRectangle": false,
    "featureDescriptions": true
  },
  "callerContext": {
    "properties": [
      {
        "key": "ResponseGeometry",
        "value": "PLAIN"
      },
      {
        "key": "CoordFormat",
        "value": "OG_GEODECIMAL"
      },
      {
        "key": "Profile",
        "value": "truckfast"
      },
      {
        "key": "ProfileXMLSnippet",
        "value": "<?xml version='1.0' encoding='UTF-8'?><Profile xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:noNamespaceSchemaLocation=\"http:///xroute/schema/XRouteProfile.xsd\"><Routing majorVersion='2' minorVersion='0'><Vehicle><Physical><Weight totalPermittedWeight='7500'/></Physical></Vehicle><Course><AdditionalDataRules enabled='true'><VehicleSpecific enabled='true'><Malus residential='2501'/></VehicleSpecific></AdditionalDataRules></Course></Routing><FeatureLayer majorVersion='1' minorVersion='0'><Themes><Theme id='PTV_TruckAttributes' enabled='true'/></Themes></FeatureLayer></Profile>"
      }
    ]
  }
}
Joost Claessen
Senior Technical Consultant
PTV Benelux
Post Reply