-
-
Notifications
You must be signed in to change notification settings - Fork 50
GSoC 2023: Yige Huang Week 8 #325
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@@ -115,46 +116,31 @@ IF min_version('3.6.0') THEN | |||
--- | |||
--- DIRECTED GRAPH | |||
--- | |||
-------- both driving sides |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test works for on 3.5.0
Please put it back and handle it in an if then else
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, this test works for 3.6.0. I didn't remove the tests work on 3.5.0, they still there.
And I added a TODO remove
comment before the tests work on old version.
-------- right driving side | ||
|
||
PREPARE q2 AS | ||
PREPARE q1 AS |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You will have to re-renumber the queries....
$$SELECT node, round(cost::numeric, 12) AS cost, round(agg_cost::numeric, 12) AS agg_cost FROM test4$$, | ||
'Should be aggregating individual costs: both driving sides, UNDI'); | ||
|
||
|
||
-------- right driving side |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These tests work on 3.5.0 so you will have to put them back
@@ -39,7 +34,7 @@ PREPARE q1 AS | |||
SELECT seq, node, edge, cost::TEXT, agg_cost::TEXT FROM pgr_withPointsDD( | |||
'SELECT id, source, target, cost, reverse_cost FROM edge_table ORDER BY id', | |||
'SELECT pid, edge_id, fraction, side from pointsOfInterest', | |||
-1, 4.8, 'b', details := true, directed:=false) | |||
-1, 4.8, driving_side := 'b', details := true, directed:=false) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: if "driving side" is compulsory parameter, then it must not be a named parameter
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you use the driving_side named parameter then you are using the old function, not the new function.
So, now my question is:
Are you testing the old signatures? or the new signatures?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A: I am testing the old signatures.
Reasons:
- What
undirected_driving_side.pg
does is:
verify that in an undirected graph, if the results ofr
,b
,l
driving side are equal. - I do the change as you mention here:
if graph is directed then valid values are 'R', 'L', 'r', 'l',
else valid values 'B', 'b'
- Because of the change, now if graph is undirected, there is only one valid input
b
. So there won't be a similar test in 3.6.0. - What I did in this file is removing changes I made last week and keep it as the same to main repo.
END IF; | ||
|
||
|
||
/* TODO remove tests on v4 of the old signatures */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR you are going to make to main repo is for V3.6
So you can not remove this test, they will be removed on Version V4.
Changes proposed in this pull request:
driving side
:r
&l
b
@pgRouting/admins