[pgrouting-dev] testing TSP example fails

Stephen Mather stephen at smathermather.com
Sat Jun 15 14:27:33 PDT 2013


Ok, definitely some failures:

$stats = {
            'src/apsp_johnson/test/test.conf' => [
                                                   {
                                                     'comment' => 'APSP 
Johnson test for any versions.',
'src/apsp_johnson/test/apsp_johnson-any-00.test' => 'Passed'
                                                   }
                                                 ],
            'src/apsp_warshall/test/test.conf' => [
                                                    {
                                                      'comment' => 'APSP 
Warshall test for any versions.',
'src/apsp_warshall/test/apsp_warshall-any-00.test' => 'Passed'
                                                    }
                                                  ],
            'src/astar/test/test.conf' => [
                                            {
                                              'comment' => 'astar test 
for any versions.',
'src/astar/test/spas-any-00.test' => 'Passed',
'src/astar/test/spas-any-01.test' => 'Passed'
                                            }
                                          ],
            'src/bd_astar/test/test.conf' => [
                                               {
                                                 'comment' => 
'Bi-directional AStar test for any versions.',
'src/bd_astar/test/bd_astar-any-01.test' => 'Passed',
'src/bd_astar/test/bd_astar-any-02.test' => 'Passed',
'src/bd_astar/test/bd_astar-any-03.test' => 'Passed',
'src/bd_astar/test/bd_astar-any-04.test' => 'Passed',
'src/bd_astar/test/bd_astar-any-05.test' => 'Passed',
'src/bd_astar/test/bd_astar-any-06.test' => 'Passed'
                                               }
                                             ],
            'src/bd_dijkstra/test/test.conf' => [
                                                  {
                                                    'comment' => 
'Bi-directional Dijkstra test for any versions.',
'src/bd_dijkstra/test/bd_dijkstra-any-01.test' => 'Passed',
'src/bd_dijkstra/test/bd_dijkstra-any-02.test' => 'Passed',
'src/bd_dijkstra/test/bd_dijkstra-any-03.test' => 'Passed',
'src/bd_dijkstra/test/bd_dijkstra-any-04.test' => 'Passed',
'src/bd_dijkstra/test/bd_dijkstra-any-05.test' => 'Passed',
'src/bd_dijkstra/test/bd_dijkstra-any-06.test' => 'Passed'
                                                  }
                                                ],
            'src/common/test/test.conf' => [
                                             {
                                               'comment' => 
'pgr_createTopology, pgr_analyzegraph, and pgr_analyzeOneway tests for 
any versions.',
'src/common/test/common-any-01.test' => 'FAILED: 1,3d0
< psql:src/common/test/common-any-01.test:1: NOTICE:  table 
"vertices_tmp" does not exist, skipping
< CONTEXT:  SQL statement "DROP TABLE IF EXISTS vertices_tmp"
< PL/pgSQL function pgr_createtopology(character varying,double 
precision,character varying,character varying) line 48 at SQL statement
6c3
< PL/pgSQL function pgr_createtopology(character varying,double 
precision,character varying,character varying) line 49 at SQL statement
---
 > PL/pgSQL function "pgr_createtopology" line 49 at SQL statement',
'src/common/test/common-any-02.test' => 'Passed',
'src/common/test/common-any-03.test' => 'Passed',
'src/common/test/common-any-04.test' => 'FAILED: 3c3
< PL/pgSQL function pgr_nodenetwork(text,text,text,text,double 
precision) line 23 at SQL statement
---
 > PL/pgSQL function "pgr_nodenetwork" line 23 at SQL statement
9c9
< PL/pgSQL function pgr_nodenetwork(text,text,text,text,double 
precision) line 58 at SQL statement
---
 > PL/pgSQL function "pgr_nodenetwork" line 58 at SQL statement
12c12
< PL/pgSQL function pgr_nodenetwork(text,text,text,text,double 
precision) line 71 at EXECUTE statement
---
 > PL/pgSQL function "pgr_nodenetwork" line 71 at EXECUTE statement
62c62
< PL/pgSQL function pgr_createtopology(character varying,double 
precision,character varying,character varying) line 49 at SQL statement
---
 > PL/pgSQL function "pgr_createtopology" line 49 at SQL statement',
'src/common/test/versionless-any-01.test' => 'Passed'
                                             }
                                           ],
            'src/dijkstra/test/test.conf' => [
                                               {
                                                 'comment' => 'Dijkstra 
test for any versions.',
'src/dijkstra/test/spd-any-00.test' => 'Passed',
'src/dijkstra/test/spd-any-01.test' => 'Passed',
'src/dijkstra/test/spd-any-02.test' => 'Passed',
'src/dijkstra/test/spd-any-03.test' => 'Passed'
                                               }
                                             ],
            'src/driving_distance/test/test.conf' => [
                                                       {
'comment' => 'Driving Distance test for any versions.',
'src/driving_distance/test/drivingdistance-any-00.test' => 'Passed'
                                                       }
                                                     ],
            'src/kdijkstra/test/test.conf' => [
                                                {
                                                  'comment' => 'Dijkstra 
test for any versions.',
'src/kdijkstra/test/kdijkstra-any-01.test' => 'Passed',
'src/kdijkstra/test/kdijkstra-any-02.test' => 'Passed'
                                                }
                                              ],
            'src/ksp/test/test.conf' => [
                                          {
                                            'comment' => 'KSP test for 
any versions.',
'src/ksp/test/ksp-any-01.test' => 'Passed',
'src/ksp/test/ksp-any-02.test' => 'Passed'
                                          }
                                        ],
            'src/trsp/test/test.conf' => [
                                           {
                                             'comment' => 'TRSP test for 
any versions.',
'src/trsp/test/trsp-any-00.test' => 'Passed',
'src/trsp/test/trsp-any-01.test' => 'Passed',
'src/trsp/test/trsp-any-02.test' => 'Passed',
'src/trsp/test/trsp-any-03.test' => 'Passed'
                                           }
                                         ],
            'src/tsp/test/test.conf' => [
                                          {
                                            'comment' => 'TSP test for 
any versions.',
'src/tsp/test/tsp-any-00.test' => 'Passed',
'src/tsp/test/tsp-any-01.test' => 'Passed',
'src/tsp/test/tsp-any-02.test' => 'Passed'
                                          }
                                        ],
            'z_crash' => 0,
            'z_fail' => 2,
            'z_pass' => 35
          };





On 06/15/2013 05:09 PM, Stephen Mather wrote:
> Hmm.  I did a clone w -b develop, so I never did a checkout of the repository after the clone.  Also didn't configure the docs dependencies.  Otherwise, it looks the same.  About to rerun...
>
> Stephen Woodbridge <woodbri at swoodbridge.com> wrote:
>
>> If you are in the pgrouting git source tree like:
>>
>> git clone git://github.com/pgRouting/pgrouting.git
>> cd pgrouting
>> git checkout develop
>>
>> cat tools/doit        # this is my build script, it may not work for you
>>
>> tools/doit
>> tools/test-runner.pl  # this will run all the tests
>>
>> The test script make a test database, loads the data and runs the tests.
>> If you look in src/tsp/test
>>
>> CMakeLists.txt   tsp-any-00.rest  tsp-any-01.test  tsp-any-03.rest
>> test.conf        tsp-any-00.test  tsp-any-02.rest  tsp-any-03.test
>> tsp-any-00.data  tsp-any-01.rest  tsp-any-02.test
>>
>>
>> createdb runtests
>> psql runtests -c "create extension postgis"
>> psql runtests -c "create extension pgrouting"
>> psql runtests -f src/tsp/test/tsp-any-00.data  # load some data
>> psql runtests -A -t -f src/tsp/test/tsp-any-00.test
>> psql runtests -A -t -f src/tsp/test/tsp-any-01.test
>> psql runtests -A -t -f src/tsp/test/tsp-any-02.test
>> psql runtests -A -t -f src/tsp/test/tsp-any-03.test
>>
>> The output of each command should be the same as *.rest file.
>>
>> -Steve
>>
>> On 6/15/2013 4:39 PM, Stephen Mather wrote:
>>> Ubuntu 12.04LTS
>>>
>>> Postgis 2.0.1 r9979
>>> GEOS 3.3.8-capi-1.7.8
>>> proj 4.8.0
>>> gdal 1.9.2
>>> Libxml  2.7.8
>>>
>>> pgr_version ()
>>> 2.0.0-Dev
>>> V2.0.0-alpha,31,15ac46d,feature-travis,1.46.1
>>>
>>> When I run tests, it fails on every test w function not found.  Do I need to prep the database in any way to run the tests?
>>>
>>> Stephen Mather <stephen at smathermather.com> wrote:
>>>
>>>> I have not tried tests yet but have have run astar and djikstra w no problem.  When does vacation start... I can run tests asap...  :)
>>>>
>>>> Stephen Woodbridge <woodbri at swoodbridge.com> wrote:
>>>>
>>>>> On 6/15/2013 2:44 PM, Stephen Mather wrote:
>>>>>> Hi All,
>>>>>>
>>>>>> More TSP for today.  In testing the example in the docs against the
>>>>>> example data, I get what is to me a cryptic error:
>>>>>>
>>>>>> SELECT * FROM pgr_tsp('SELECT id AS source_id, x, y FROM
>>>>>> vertex_table','2,7,11',7);
>>>>>>
>>>>>> ERROR:  Error TSP fail to findEulerianPath, check your distance matrix
>>>>>> is valid.
>>>>> This typically means there is something bad happening in the distance
>>>>> matrix that is getting passed to the TSP function. Hmmm.
>>>>>
>>>>> I would start with can you run the test cases or do they fail on your
>>>>> system.
>>>>>
>>>>> What OS system and versions of stuff are you running?
>>>>>
>>>>> There TSP solution for 3 points is a triangle, it is a trivial case
>>>>> where the input is the output. I thought is tested for that case but
>>>>> maybe not.
>>>>>
>>>>> BTW, I will be away on vacation without net access through June 25th, so
>>>>> I will not be much help until I get back.
>>>>>
>>>>> -Steve
>>>>>
>>>>>> ********** Error **********
>>>>>>
>>>>>> ERROR: Error TSP fail to findEulerianPath, check your distance matrix is
>>>>>> valid.
>>>>>> SQL state: XX000
>>>>>>
>>>>>> I get an entirely different error against my OSM data, but one error at
>>>>>> a time... .
>>>>>>
>>>>>> Best,
>>>>>> Steve
>>>>>>
>>>>>>
>>>>>> _______________________________________________
>>>>>> pgrouting-dev mailing list
>>>>>> pgrouting-dev at lists.osgeo.org
>>>>>> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev
>>>>>>
>>>>> _______________________________________________
>>>>> pgrouting-dev mailing list
>>>>> pgrouting-dev at lists.osgeo.org
>>>>> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev
>>>> _______________________________________________
>>>> pgrouting-dev mailing list
>>>> pgrouting-dev at lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev
>>> _______________________________________________
>>> pgrouting-dev mailing list
>>> pgrouting-dev at lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev
>>>
>> _______________________________________________
>> pgrouting-dev mailing list
>> pgrouting-dev at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev
> _______________________________________________
> pgrouting-dev mailing list
> pgrouting-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/pgrouting-dev



More information about the pgrouting-dev mailing list