Route calculation and PTV_TruckAttributes
Posted: Tue Apr 24, 2018 7:41 am
Hello,
I have a question about routing with PTV_TruckAttributes enabled. When this feature is enabled then all truck features are considered as blocking even when the vehicle does not violate the restrictions.
So I tried the example from the manuals. The example request is based on the Routing Use Case „How to Use Feature Layer Theme PTV_TruckAttributes“.
The manual states that the route for a vehicle with maxHeight=150 will be routed through a height (460 cm) restricted area. The route should be about 800 meters.
Here ist he JSON-Request:
But the route is about 4000 meter although the maxHeight oft he vehicle was set to 150 cm:
The only option to get a route through the height restricted segment is to allow seqment violation:
Then the route is shorter but contains violations:
Here is an example of one violating segment:
What could be the cause of this calculation/violation? I would expect that the Parameter maxHeight=150 would allow Routing throught the height restricted seqment?
Thanks in advance!
Best Regards,
Florian
I have a question about routing with PTV_TruckAttributes enabled. When this feature is enabled then all truck features are considered as blocking even when the vehicle does not violate the restrictions.
So I tried the example from the manuals. The example request is based on the Routing Use Case „How to Use Feature Layer Theme PTV_TruckAttributes“.
The manual states that the route for a vehicle with maxHeight=150 will be routed through a height (460 cm) restricted area. The route should be about 800 meters.
Here ist he JSON-Request:
Code: Select all
{
"waypoints": [
{
"$type": "WaypointDesc",
"linkType": "NEXT_SEGMENT",
"fuzzyRadius": 0,
"coords": [
{
"$type": "Point",
"point": {
"$type": "PlainPoint",
"x": 5.995894,
"y": 49.510518
}
}
]
},
{
"$type": "WaypointDesc",
"linkType": "NEXT_SEGMENT",
"fuzzyRadius": 0,
"coords": [
{
"$type": "Point",
"point": {
"$type": "PlainPoint",
"x": 5.999437,
"y": 49.50566
}
}
]
}
],
"details": {
"segments": true,
"featureDescriptions": true
},
"callerContext": {
"properties": [
{
"key": "CoordFormat",
"value": "OG_GEODECIMAL"
},
{
"key": "ProfileXMLSnippet",
"value": "<Profile xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'><FeatureLayer majorVersion='1' minorVersion='0'><Themes><Theme id='PTV_TruckAttributes' enabled='true'/></Themes></FeatureLayer><Routing majorVersion='2' minorVersion='0'><Course><AdditionalDataRules enabled='true'/></Course><Vehicle><Physical><Dimension maxHeight='150'/></Physical></Vehicle></Routing></Profile>"
}
]
}
}
Code: Select all
"info": {
"distance": 4033,
"time": 347,
"cost": 4223
},
Code: Select all
{
"waypoints": [
{
"$type": "WaypointDesc",
"linkType": "NEXT_SEGMENT",
"fuzzyRadius": 0,
"coords": [
{
"$type": "Point",
"point": {
"$type": "PlainPoint",
"x": 5.995894,
"y": 49.510518
}
}
]
},
{
"$type": "WaypointDesc",
"linkType": "NEXT_SEGMENT",
"fuzzyRadius": 0,
"coords": [
{
"$type": "Point",
"point": {
"$type": "PlainPoint",
"x": 5.999437,
"y": 49.50566
}
}
]
}
],
"details": {
"segments": true,
"featureDescriptions": true
},
"options": [
{
"parameter": "ALLOW_SEGMENT_VIOLATIONS",
"value": "true"
},
{
"parameter": "COST_OF_SEGMENT_VIOLATIONS",
"value": "0"
}
],
"callerContext": {
"properties": [
{
"key": "CoordFormat",
"value": "OG_GEODECIMAL"
},
{
"key": "ProfileXMLSnippet",
"value": "<Profile xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'><FeatureLayer majorVersion='1' minorVersion='0'><Themes><Theme id='PTV_TruckAttributes' enabled='true'/></Themes></FeatureLayer><Routing majorVersion='2' minorVersion='0'><Course><AdditionalDataRules enabled='true'/></Course><Vehicle><Physical><Dimension maxHeight='150'/></Physical></Vehicle></Routing></Profile>"
}
]
}
}
Code: Select all
"info": {
"distance": 845,
"time": 105,
"cost": 1210,
"hasViolations": true
},
Code: Select all
{
"firstPolyIdx": 14,
"polyC": 2,
"firstNodeIdx": 9,
"nodeC": 2,
"streetNoIdx": -1,
"streetNameIdx": -1,
"dirInfoIdx": -1,
"accTime": 90,
"accDist": 720,
"iuCode": 52,
"countryCode": "",
"violations": [
"FeatureLayer:themeId=PTV_TruckAttributes|ruleId=ptvTA_BM_2|maxHeight=460"
],
"featureDescriptions": [
{
"themeId": "PTV_TruckAttributes",
"description": "driveType=0|maxHeight=460"
}
],
"nC": "CITY_ROAD",
"vNorm": 0
},
Thanks in advance!
Best Regards,
Florian