Answers:
ESRI具有可折叠的双车道到中心线工具。您可以获得与OSM一起使用的廉价版本。否则,您可以选择要素并另存为新图层。从用于导出的图层中删除选定的内容。缓冲特征在包括第二车道的车道一侧的范围内。将shapefile与原始文件合并,连接任何损坏的拓扑。
如果您可以编码和/或编写脚本,则可以通过节点匹配,通过段匹配来平均节点上通道之间的中心线,并以编程方式输出中心线,然后以编程方式删除用于生产过程的所选特征,检查并修复损坏的拓扑,然后完成。
我找到了一个包含的arcpy代码示例,如何在下面的注释中找到链接。
归功于ESRI ARCGis帮助
# Name: CollapseDualLinesToCenterline_Example.py
# Description: Creates street centerlines from a street casing coverage.
# Requirements: ArcInfo Workstation
# Import system modules
import arcpy
from arcpy import env
# Set environment settings
env.workspace = "C:/data"
# Set local variables
inCover = "streets"
outCover = "C:/output/centerlines"
maximumWidth = 50
# Execute CollapseDualLinesToCenterline
arcpy.CollapseDualLinesToCenterline_arc(inCover, outCover, maximumWidth, "")
也许这不是一个非常优雅的解决方案,它基于回答问题的方法:https : //gis.stackexchange.com/a/295348/120129。
这是解决您的问题的一种方法,设置一个地理仪器(对我来说,这是一条名称为“ road_border”的道路,宽11 m,类型-线(MultiLineString)),
运行一个geoinstrument :-),
WITH
tbla AS (SELECT id, ((ST_DumpPoints(geom)).geom) geom FROM road_border),
tblb AS (SELECT (ST_Buffer((ST_Dump(geom)).geom, 0.0001)) geom FROM tbla),
tblc AS (SELECT ST_Centroid(ST_UnaryUnion(Unnest(ST_ClusterWithin(geom, 0.0001)))) geom FROM tblb),
tbld AS (SELECT ((ST_Dump(ST_DelaunayTriangles(ST_Collect(geom)))).geom) geom FROM tblc),
tble AS (SELECT (ST_Boundary(geom)) geom FROM ST_Dump((SELECT ST_Polygonize(geom) geom FROM (SELECT ST_Union(geom) geom FROM
(SELECT ST_ExteriorRing(geom) geom FROM tbld) AS lines) AS foo))),
tblf AS (SELECT ST_MakeLine(p1, p2) geom FROM (SELECT ST_PointN(geom, generate_series(1, ST_NPoints(geom)-1)) p1,
ST_PointN(geom, generate_series(2, ST_NPoints(geom))) p2 FROM tble) AS geom),
tblj AS (SELECT ST_Buffer((ST_Dump(ST_Union(ST_Buffer(geom, 0.0005)))).geom, -0.0005) geom FROM road_border)
SELECT ST_Intersection (a.geom, b.geom) geom FROM tblf a JOIN tblj b ON ST_Within (a.geom, b.geom);
并查看结果。
祝大家好运:-),
原始解决方案...
该脚本称为-ST_RoadAxisFromDelaunayTriangulation ...