DOI: 10.6084/m9.figshare.27160731
title: <b>Road intersections Data with branch information extracted from OSM</b> & <b>C</b><b>odes to implement the extraction </b>&<b> I</b><b>nstructions on how to </b><b>reproduce each reported finding</b>

description: <b>1. Overview</b>Road intersections are crucial nodes in urban networks, where transportation lanes converge and socioeconomic activity is concentrated. While methods to identify road intersections using raster maps, satellite images, and trace data have been explored, challenges in accuracy and consistency remain.<b>This paper proposes a method for identifying intersections based on OpenStreetMap data, which records networks at the lane level.</b> Unlike geometric line intersections in OpenStreetMap, t<b>he identified intersections “summarize” parallel lanes and incorporate branch information, such as counts and orientations.</b> The proposed method uses a vector-raster fusion approach to initially locate intersections, followed by hierarchical geometric configuration to improve accuracy and extract branch data.Experimental results show that the method effectively handles complex road networks in various cities, accurately identifying intersections and their branches. Experiments conducted on OpenStreetMap data from 7 cities yielded over <b>98% precision</b> and <b>97% recall</b>, outperforming the popular OSMnx tool. Additionally, lane synthesis at intersections achieved 99.43% precision and 98.34% recall. Urban characteristics can be quantitatively analyzed based on the identified road intersections. For instance, the proportion of four-way road intersections in New York is 52.6%, whereas in London, it is 9.6%, which may be attributed to the differing urban histories of these cities.<b>2. Instructions for data</b>This dataset contains road intersection data of seven cities (Berlin, Beijing, London, Nanjing, New York City, Rome, Shanghai) identified by our proposed method.The data of each city are stored in the folder named by its abbreviation.In each folder, there will be five *.shp files:(1) <b>Roadnetwork</b> (roads.shp)This layer stores the OSM road network with tag attributes.(2) <b>Intersection points</b> (cross-res.shp)This layer stores the location of the intersection point and the general characteristics of the road layout, including the number of intersecting roads and layout type. This provides the necessary location information for mapping and spatial analyses.(3) <b>Related road lines</b> (fullLine-res.shp/fail-fullLine.shp)The original road lines related to intersections extracted from the road networks were stored in this layer, preserving the inherent attributes of the original dataset. In addition, matching information, indicating whether the lines represent the same road, was stored as an attribute.(4) <b>Synthesized road lines</b> (simpleLine-res.shp)The geometries of this layer store synthesized road lines representing road orientations, whereas the attributes store acquired characteristics, including roadway configurations and match indices, which allow the synthesized road lines to be connected to the original roads from which they were derived. This connection is achieved through “pt_id” linked with cross-res.shp and “match_id” linked with fullLine-res.shp.<b>3. Instructions for codes</b>This code repository is organized into eight folders and two files:(1) Folder: <b>candidateIdentify</b>This folder contains code related to the identification of candidate junctions or intersections from the input data. Each script plays a specific role in the overall process:<b>bufferThin.py</b>: Implements a thinning algorithm to generate a skeleton of buffered road geometry.<b>candidateIdentify.py</b>: The core script for identifying candidate points for road intersections in a spatial dataset.<b>fastJunction.py</b>: Provides an optimized method for detecting junctions quickly in large datasets by leveraging a fast hit-or-miss operation.<b>junctionGeo.py</b>: Handles the geometric processing of junction points, focusing on transforming raster cells into geographical positions.(2) Folder: <b>compareEvaluation</b><b>clipByregion.py</b>: Clips spatial data to a specific region, which is useful for limiting analysis to a predefined geographic area. This is typically used to obtain intersections identified within the randomly selected regions.(3) Folder: <b>geometricConfigurationTemplateMatch</b>This folder includes tools for matching geometric templates of road intersections:<b>templateMatcher.py</b>: The main module that matches geometric configurations of road intersections to the determined templates.<b>utils_g.py</b>: Provides utility functions that assist in geometric operations and template matching processes.(4) Folder: <b>maxRadiusBuffer</b>This folder focuses on the code of a greedy algorithm that produces the largest nonoverlapping buffers for a given collection of points.:<b>maxRadBuffer.py</b>: Core script for this algorithm.(5) Folder: <b>intersectionDistanceAnalysis</b>This folder contains scripts for analyzing distances between intersection points for parameter determination:<b>distanceAnalysis.py</b>: Calculates the distances between identified intersections and analyze their distribution.(6) Folder: <b>proportionDrawer</b>This folder contains scripts using R to produce pie charts in Figure 14.(7) Folder: <b>refineCandidate</b>This folder contains a script that refines the previously identified intersection candidates.<b>refineCandidate.py</b>: This core script refines the set of candidate intersections by applying further geometric or statistical methods.(8) Folder: <b>resultAnalysis</b>This folder is used for analyzing the identified results for insights of urban characteristics:<b>angleAnalysis.py</b>: Compute and analyze angles between road branches at intersections.<b>4. Instructions on how to reproduce each reported findings</b>The file '<b>instructions_on_how_to_reproduce_each_reported_findings.md</b>' details the steps to reproduce the figures and the tables shown in the paper.