Skip to content

kennywang112/ST-RTA

Repository files navigation

ST-RTA: Spatio-Temporal Road Traffic Accident

Reanalyze it starting from here, but apply spatial and temporal analysis techniques. MacroCounty and MicroCounty calculates nearest neighbor based on county, while MacroGrid and MicroGrid is based on Grid we generated. Models folder include not only Mapper Algorithm from TDA, but also three machine learning methods to identify hotspot we generated from Getis-ord.

Data Sources:

  1. Youbike (deprecated) (New Taipei, Taipei, Taichung)
  2. Parking Lot
  3. Metro Rapid Transit: Transport Data Exchange(捷運站出入口基本資料)
  4. Youbike: 自行車租借站位資料
  5. Taiwan shape and 鄉鎮市區界線(TWD97經緯度)1140318

Additional Attributes

  1. Attractions
  2. School Data

Data source Update

  • Youbike, MRT, Attractions data sources installed in 2025/04/15
  • Parkinglot data sources installed in 2025/04/21
  • Taiwan shape 2025/06/06
  • Traffic accident data installed in 2025/10/18, include data until Sep

Env

conda create --name ST-RTA python=3.10
conda activate ST-RTA
pip install -r requirements.txt

Core

  • DataCombine: Combine A1 and A2 separately in each year, month
  • DataPreprocess: Preprocess data for grid analyze grid_gi and model input data all_features
  • Model: Run ML model from all_features
  • FilterforMapper: Get the filter function for Mapper from all_features data
  • GetCCforCombineddata: Add County name to combined data, get combineddata_with_CC

Paper

Some reference papers are stored in notion

About

Taiwan Traffic Accident: This project includes spatio-temporal analytic using multiple modelling method including Bayesian, GI, Morans, TDA, etc.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors