<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">Le 28/10/2013 14:19, Peter K a écrit :<br>
</div>
<blockquote cite="mid:526E646D.3040200@yahoo.de" type="cite">
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
<div class="moz-cite-prefix">The removal will especially improve
query performance on Android, not sure if there is a big
difference for the contraction process or the query performance
on the server. So probably you do not need this optimization at
all.<br>
</div>
</blockquote>
<br>
Some exotic algorithm descend in the hierarchy instead of climbing,
<br>
and make use of a previous exploration to mark nodes to funnel the
descending search. <br>
<br>
<blockquote cite="mid:526E646D.3040200@yahoo.de" type="cite">
<div class="moz-cite-prefix"> > My question is: to reconnect an
edge, can I simply put is as head of the list of edges leaving
the node?<br>
<br>
Yes, this should work.<br>
</div>
</blockquote>
<br>
Thank you. <br>
<br>
Just curious, when a new edge is created, it is always inserted at
the end of this list, <br>
as shown in the following code: <br>
<br>
private void connectNewEdge( int fromNodeId, int
newOrExistingEdge )<br>
{<br>
long nodePointer = (long) fromNodeId * nodeEntryBytes;<br>
int edge = nodes.getInt(nodePointer + N_EDGE_REF);<br>
if (edge > EdgeIterator.NO_EDGE)<br>
{<br>
// append edge and overwrite EMPTY_LINK<br>
long lastEdge = getLastEdge(fromNodeId, edge);<br>
edges.setInt(lastEdge, newOrExistingEdge);<br>
} else<br>
{<br>
nodes.setInt(nodePointer + N_EDGE_REF,
newOrExistingEdge);<br>
}<br>
}<br>
<br>
Is there a reason for not inserting it at the beginning?<br>
I guess there is something related to the specific context of this
operation. <br>
<br>
<blockquote cite="mid:526E646D.3040200@yahoo.de" type="cite">
<div class="moz-cite-prefix"> <br>
Regards,<br>
Peter.<br>
<br>
<br>
</div>
<blockquote cite="mid:526E5E0F.7040907@cetic.be" type="cite">
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
Hi Peter, <br>
<br>
I am playing with the code of your contractor, and I have a
small question. <br>
<br>
The contractor can remove edges from lists of edges leaving a
node if the flag removesHigher2LowerEdges is set. <br>
This flag, when set, provides a quite important speedup to the
contraction process. <br>
<br>
Sometime, you do not want this flag to be set, because you do
not want edges to be disconnected, because you want to use some
exotic algorithms. In such cases, the contraction is slower. <br>
<br>
I was wondering about disconnecting such edges always, and
reconnecting them after the contraction is completed, to have a
fast contraction, and have the desired graph in the end. <br>
I am planning therefore to have a list of disconnected edges
saved somewhere, and reconnecting them after the contraction. <br>
<br>
My question is: to reconnect an edge, can I simply put is as
head of the list of edges leaving the node?<br>
<br>
Thank you. <br>
<div class="moz-signature">-- <br>
<table width="400" cellspacing="0">
<tbody>
<tr>
<td colspan="2" style="border-left: 1px solid rgb(0,
102, 0); background-color: rgb(255, 255, 255);
font-family: arial; font-style: normal; font-variant:
normal; font-weight: normal; font-size: 14px;
line-height: normal; font-size-adjust: none;
font-stretch: normal; vertical-align: top;"> <b>Renaud
De Landtsheer, Ir, Phd</b> </td>
</tr>
<tr>
<td colspan="2" style="border-left: 1px solid rgb(0,
102, 0); background-color: rgb(255, 255, 255);
font-family: arial; font-style: italic; font-variant:
normal; font-weight: normal; font-size: 14px;
line-height: normal; font-size-adjust: none;
font-stretch: normal; vertical-align: top;">Sr R&D
Engineer</td>
</tr>
<tr>
<td colspan="2" style="border-left: 1px solid rgb(0,
102, 0); background-color: rgb(255, 255, 255);
font-family: arial; font-style: normal; font-variant:
small-caps; font-weight: normal; font-size: 14px;
line-height: normal; font-size-adjust: none;
font-stretch: normal; vertical-align: top;"> CETIC <br>
Rue des Frères Wright, 29/3 <br>
B-6041 Charleroi <br>
Phone: +32 71 490 754 </td>
</tr>
<tr>
<td colspan="2" style="border-top: 1px solid rgb(0, 102,
0); background-color: rgb(255, 255, 255); font-family:
arial; font-style: italic; font-variant: normal;
font-weight: normal; font-size: 12px; line-height:
normal; font-size-adjust: none; font-stretch: normal;
vertical-align: top;" align="top">
<p><br>
</p>
</td>
</tr>
</tbody>
</table>
</div>
<br>
</blockquote>
<br>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
GraphHopper mailing list
<a class="moz-txt-link-abbreviated" href="mailto:GraphHopper@openstreetmap.org">GraphHopper@openstreetmap.org</a>
<a class="moz-txt-link-freetext" href="https://lists.openstreetmap.org/listinfo/graphhopper">https://lists.openstreetmap.org/listinfo/graphhopper</a>
</pre>
</blockquote>
<br>
<br>
<div class="moz-signature">-- <br>
<table width="400" cellspacing="0">
<tbody>
<tr>
<td colspan="2" style="border-left: 1px solid rgb(0, 102,
0); background-color: rgb(255, 255, 255); font-family:
arial; font-style: normal; font-variant: normal;
font-weight: normal; font-size: 14px; line-height: normal;
font-size-adjust: none; font-stretch: normal;
vertical-align: top;"> <b>Renaud De Landtsheer, Ir, Phd</b>
</td>
</tr>
<tr>
<td colspan="2" style="border-left: 1px solid rgb(0, 102,
0); background-color: rgb(255, 255, 255); font-family:
arial; font-style: italic; font-variant: normal;
font-weight: normal; font-size: 14px; line-height: normal;
font-size-adjust: none; font-stretch: normal;
vertical-align: top;">Sr R&D Engineer</td>
</tr>
<tr>
<td colspan="2" style="border-left: 1px solid rgb(0, 102,
0); background-color: rgb(255, 255, 255); font-family:
arial; font-style: normal; font-variant: small-caps;
font-weight: normal; font-size: 14px; line-height: normal;
font-size-adjust: none; font-stretch: normal;
vertical-align: top;">
CETIC <br>
Rue des Frères Wright, 29/3 <br>
B-6041 Charleroi <br>
Phone: +32 71 490 754 </td>
</tr>
<tr>
<td colspan="2" style="border-top: 1px solid rgb(0, 102, 0);
background-color: rgb(255, 255, 255); font-family: arial;
font-style: italic; font-variant: normal; font-weight:
normal; font-size: 12px; line-height: normal;
font-size-adjust: none; font-stretch: normal;
vertical-align: top;" align="top">
<p><br>
</p>
</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>