How luispv05/f1-analysis works
F1-Analysis is a Python package and set of command-line tools for race, season, constructor, teammate, and multi-season analysis. Users supply seasons, rounds, or drivers; the tools retrieve Jolpica-backed data, compute domain summaries, and generate charts or an interactive season report. The graph preserves the documented analysis branches and core modules. Edges are limited to calls visible in excerpts, indexed imports, or README-described workflows; unsampled implementation details are not inferred.
Main entry points: season.py Season analysis · main.py Race command · main_constructors.py Constructor command · history.py History analysis
Components 21
Race analysis
- Race command
src/main.py - Race calculations
src/f1analysis/analysis.py - Race charts
src/f1analysis/plots.py
Championship analysis
- Season command
src/main_season.py - Season analysis
src/f1analysis/season.py - Season charts
src/f1analysis/season_plots.py - Constructor command
src/main_constructors.py - Constructor analysis
src/f1analysis/constructors.py - Constructor charts
src/f1analysis/constructors_plots.py
Driver comparisons
- History command
src/main_history.py - History analysis
src/f1analysis/history.py - History charts
src/f1analysis/history_plots.py - Teammate command
src/main_teammates.py - Teammate analysis
src/f1analysis/teammates.py - Teammate charts
src/f1analysis/teammates_plots.py - Driver command
src/main_drivers.py
Shared data and presentation
- Race data
src/f1analysis/data.py - Chart styling
src/f1analysis/styling.py - Disk cache
src/f1analysis/cache.py
Other components
- CLI user
- Jolpica API
Connections 36
- CLI user → Race command: runs
README.md - Race command → Race data: loads results
src/main.py - Race command → Race calculations: calculates laps
src/main.py - Race command → Race charts: creates charts
src/main.py - Race data → Jolpica API: fetches data
src/f1analysis/data.py - Race data → Disk cache: reads and writes
src/f1analysis/data.py - Race charts → Race calculations: uses lap helpers
src/f1analysis/plots.py - Race charts → Chart styling: uses styles
src/f1analysis/plots.py - CLI user → Season command: runs
README.md - Season command → Season analysis: analyzes season
src/main_season.py - Season command → Season charts: creates reports
src/main_season.py - Season analysis → Jolpica API: fetches standings
src/f1analysis/season.py - Season analysis → Disk cache: reads and writes
src/f1analysis/season.py - CLI user → Constructor command: runs
README.md - Constructor command → Constructor analysis: analyzes teams
src/main_constructors.py - Constructor command → Constructor charts: creates charts
src/main_constructors.py - Constructor command → Season charts: creates heatmap
src/main_constructors.py - Constructor analysis → Disk cache: uses cached data
src/f1analysis/constructors.py - Constructor analysis → Season analysis: reuses season logic
src/f1analysis/constructors.py - Constructor charts → Season charts: uses heatmap
src/f1analysis/constructors_plots.py - Constructor charts → Chart styling: uses styles
src/f1analysis/constructors_plots.py - CLI user → History command: runs
README.md - History command → History analysis: compares seasons
src/main_history.py - History command → History charts: creates charts
src/main_history.py - History analysis → Disk cache: reads and writes
src/f1analysis/history.py - History analysis → Season analysis: uses retry logic
src/f1analysis/history.py - History charts → Chart styling: uses team colors
src/f1analysis/history_plots.py - CLI user → Driver command: runs
README.md - Driver command → History analysis: compares drivers
src/main_drivers.py - Driver command → History charts: creates charts
src/main_drivers.py - CLI user → Teammate command: runs
README.md - Teammate command → Teammate analysis: analyzes duels
src/main_teammates.py - Teammate command → Teammate charts: creates charts
src/main_teammates.py - Teammate analysis → Race data: loads race data
src/f1analysis/teammates.py - Teammate analysis → Season analysis: uses retry logic
src/f1analysis/teammates.py - Teammate charts → Chart styling: uses styles
src/f1analysis/teammates_plots.py