This project focuses on network analysis using Python, specifically leveraging libraries such as NetworkX and OSMnx for creating and analyzing transportation networks. The analysis includes routing, network property evaluation, and geospatial operations such as buffering and intersection with building data.
requirements.txt: Lists the dependencies required for the project.network-analysis.ipynb: A Jupyter notebook for interactive code execution and analysis steps.
- Clone the repository or download the project files.
- Navigate to the project directory.
- Install the required dependencies using pip:
pip install -r requirements.txt
- Open the Jupyter notebook
network-analysis.ipynbto interactively run the analysis. - The notebook contains markdown cells with explanations and code cells for executing the analysis steps.
- You can modify the parameters in the notebook to analyze different areas or routing scenarios.
- Create a 50 m buffer around the route: This can be done using the
buffermethod from GeoPandas on the route geometry. - Select buildings intersecting the buffer: Use the
intersectsmethod to filter buildings that fall within the buffer zone. - Count buildings: Utilize the
value_countsmethod to count buildings by their tags and get the total count. - Export results: Save the filtered buildings to a GeoJSON file using the
to_filemethod from GeoPandas.
This project serves as a comprehensive guide to performing network analysis in Python, with a focus on geospatial data. The provided code snippets and instructions will help you extend the analysis and gain insights from transportation networks and their surrounding environments.