A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/pgRouting/pgrouting/issues/692 below:

pgr_nodeNetwork bug · Issue #692 · pgRouting/pgrouting · GitHub

Expected behavior and actual behavior

In release 2.3 pgr_nodeNetwork() often creates spurious nodes for intersections but not at the intersection. Looking at the source code, the following snippet in nodeNetwork.sql seems wrong:

--HAD TO CHANGE THIS QUERY
-- p_ret= 'create temp table inter_loc on commit drop as (
-- select l1id, l2id, ' || vst_line_locate_point || '(line,point) as locus from (
-- select DISTINCT l1id, l2id, line, (ST_DumpPoints(geom)).geom as point from intergeom) as foo
-- where ' || vst_line_locate_point || '(line,point)<>0 and ' || vst_line_locate_point || '(line,point)<>1)';
p_ret= 'create temp table inter_loc on commit drop as ( select * from (
(select l1id, l2id, ' || vst_line_locate_point || '(line,source) as locus from intergeom)
union
(select l1id, l2id, ' || vst_line_locate_point || '(line,target) as locus from intergeom)) as foo
where locus<>0 and locus<>1)';

It does not make any sense to use source (from ST_StartPoint) and target (from ST_EndPoint) rather than geom (from ST_Intersection) for the purpose of cutting line at intersection. The two sections above were switched recently, so I wonder whether it is some unintended leftover from testing?

Steps to reproduce the problem Specifications like the version of pgRouting/PostGIS and PostgreSQL as well as Operating System

PostgreSQL 9.5.2, compiled by Visual C++ build 1800, 64-bit | POSTGIS="2.3.0 r15146" GEOS="3.5.0-CAPI-1.9.0 r4090" PROJ="Rel. 4.9.1, 04 March 2015" GDAL="GDAL 2.1.1, released 2016/07/07" LIBXML="2.7.8" LIBJSON="0.12" RASTER | (2.3.0,pgrouting-2.3.0,8c86efd,master,1.59.0)

Use the commands:

SELECT version();
SELECT postgis_full_version();
SELECT pgr_version();

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4