How markongithub/clever_buses_py works
Project type and purpose
• From the file tree and README, “clever_buses_py” is a Python-based data-processing and reporting tool. Its primary purpose is to parse input data (e.g. Clever XML or Parquet), compute metrics (wait times, trip quantities), and output reports (CSV, Parquet, TXT, HTML, plots).
• There is no frontend web UI or microservice network; instead, this is a command-line/CLI pipeline that reads raw data, transforms it, and emits analysis outputs and documentation.
File structure
• Top-level scripts:
• parse_clever_xml.py – ingestion of XML data
• separate_trips.py – splitting or filtering trip data
• calculate_wait_times.py – computing wait-time metrics
• state_fair_quantities.py – aggregating trip quantities for “state_fair” context
• state_fair_report.py – composing final text or tabular report
• graph_wait_times.ipynb – exploratory analysis & plotting
• Configuration / dependencies:
• Pipfile & Pipfile.lock – defines Python runtime & libraries (likely pandas, plotly, etc.)
• .gitignore
• Output directories:
• output/ – final .txt, .csv, .parquet artifacts
• docs/ – Jekyll (or MkDocs) source for project documentation and embedded HTML snippets
• test_data/ – sample inputs for testing or CI
• Patterns: a simple data pipeline with discrete stages (ingest → transform → analyze → report).
README for additional insights
• The README is minimal, so architecture must be inferred from code and docs folder. The docs subfolder and HTML includes show that the project also exposes snippets and example outputs for documentation purposes.
Final advice
• How intermediate files in output/ feed into subsequent stages.
• Docs pipeline separately to illustrate how HTML includes are assembled into final docs.
• Test_data directory and any automated test or CI process as a validating component upstream of each stage.