You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Driving Distance calculation page (http://www.pgrouting.org/docs/1.x/dd.html) tells that output field "cost" is
"the cost associated to the current edge. It is 0 for the row after the last edge. Thus, the path total cost can be computated using a sum of all rows in the cost column." But it seems to me that cost attribute contains the total cost of travel from the starting node to the vertex_id node, isn't it?
Also in this document tells that "vertex_id: the identifier of source vertex of each edge". But when I perform the following query in my database:
SELECT _.*, gid, osm_id, source, target FROM driving_distance('SELECT gid AS id, source AS source, target AS target, length AS cost FROM network_part', 4260, 2000, false, false) AS _ INNER JOIN network_part ON _.edge_id = network_part.gid WHERE OSM_ID=84675642
As you can see vertex_id is not the same as source of edge.
What is edge_id? Here is part of my road network: http://gis-lab.info/share/DR/ifort/dd_graph2.png
If I perform query described above I get edge_id value the same for both vertex_id=3520 and 3521. I had assumed that vertex_id describes id of last edge but it is not correct. Please provide any information about edge_id field and how it can be used.
The text was updated successfully, but these errors were encountered:
What I've discovered so far:
for cost, vertex_id, edge_id,
'cost' is lowest cost to reach 'vertex_id'.
the edges to actually reach 'vertex_id' aren't necessarily included in the output
'edge_id' seems to be an edge that has 'vertex_id' either as its source or target, but, the other target/source isn't necessarily within the maximum_cost, and the edge shouldn't be considered part of the shortest path tree.
as far as I can tell, edge_id is fairly useless, unless you just want a general sense of some edges that might be reachable.
I'll have to dig into the C to figure out why this is.
Driving Distance calculation page (http://www.pgrouting.org/docs/1.x/dd.html) tells that output field "cost" is
"the cost associated to the current edge. It is 0 for the row after the last edge. Thus, the path total cost can be computated using a sum of all rows in the cost column." But it seems to me that cost attribute contains the total cost of travel from the starting node to the vertex_id node, isn't it?
Also in this document tells that "vertex_id: the identifier of source vertex of each edge". But when I perform the following query in my database:
SELECT _.*, gid, osm_id, source, target FROM driving_distance('SELECT gid AS id, source AS source, target AS target, length AS cost FROM network_part', 4260, 2000, false, false) AS _ INNER JOIN network_part ON _.edge_id = network_part.gid WHERE OSM_ID=84675642
it returns:
vertex_id | edge_id | cost | gid | osm_id | source | target
-----------+---------+------------------+--------+----------+--------+--------
3520 | 539658 | 881.303092499435 | 539658 | 84675642 | 3520 | 3521
3521 | 539658 | 911.340955617547 | 539658 | 84675642 | 3520 | 3521
(2 rows)
As you can see vertex_id is not the same as source of edge.
What is edge_id? Here is part of my road network: http://gis-lab.info/share/DR/ifort/dd_graph2.png
If I perform query described above I get edge_id value the same for both vertex_id=3520 and 3521. I had assumed that vertex_id describes id of last edge but it is not correct. Please provide any information about edge_id field and how it can be used.
The text was updated successfully, but these errors were encountered: