[pgrouting-dev] APSP Implementation

Jay Mahadeokar jai.mahadeokar at gmail.com
Mon Jan 24 11:54:02 EST 2011


Hi Anton,

Again sorry for late reply. My college restarted, I got busy with some
academic work. Anyways, I looked back again into the code and the NOTICE
commands helped a lot. The problem was that boost warshall algorithm expects
the vertex ids in sequence starting from 0 (according to the example in
their docs) and the node ids in database were random.I worked around it and
I am now able to see output.

Another problem is that the warshall algorithm expects distances between
nodes to be integers (again according to tutorial). So, I have converted the
float8 cost values to integers by multiplying by 10000000 as a temporary
fix, since all cost values in ways table seem to be much less than 1.

Can you suggest any better way of handling this? (May be a deeper look in
boost documentation can help!)

Also, there are negative costs to edges. How should we handle that scenario?

I will try and commit the code in the the gitHub repo i have forked here
https://github.com/jay-mahadeokar/pgrouting in next few days. (Still not
learned git commands! )

Regards,

On Wed, Jan 12, 2011 at 11:45 AM, Anton Patrushev <
anton.patrushev at georepublic.de> wrote:

> Hi Jay,
>
> Sorry for such late reply - some parts of our world still live offline :)
>
> It is quite difficult to debug PostgreSQL stored procedures. I use
> debug messages (NOTICE command) in pl/pgsql and same approach for C
> (good old print). It is possible to debug it with gdb and Valgrind
> (try to google for some tutorials - there must be few of them).
>
> Anton.
> _______________________________________________
> pgrouting-dev mailing list
> pgrouting-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev
>



-- 
Regards,
-Jay Mahadeokar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/pgrouting-dev/attachments/20110124/01dfdfa1/attachment.html


More information about the pgrouting-dev mailing list