Skip to content

Latest commit

 

History

History
28 lines (21 loc) · 787 Bytes

README.md

File metadata and controls

28 lines (21 loc) · 787 Bytes

Traffix: HackHarvard 2024

Installation

  • Create a new virtual environment with: python3 -m venv env
  • Activate your virtual environment with: source env/bin/activate
  • Install necessary dependencies: pip install -r requirements.txt

Running FastAPI

  • Enter the following commands in the terminal:
    • cd api
    • source env/bin/activate
    • uvicorn main:app --reload
  • Navigate to localhost:8000 on your browser

Get All Intersection Names

  • localhost:8000/get_all_names/

Get All City Names

  • localhost:8000/get_all_cities/

Get Video Frames

  • localhost:8000/video/?name=NAME_HERE

Get All Intersection Data

  • localhost:8000/intersection/?name=NAME_HERE

Get Intersection Data Within a City

  • localhost:8000/city/?name=CITY_NAME_HERE