This project builds a clean, physics-safe dataset of motorcycle specifications that can be used for route suitability analysis and scoring.
Instead of asking users to manually enter bike specifications, the system allows them to select a bike model, after which all required technical parameters are automatically available for downstream algorithms.
- Detail pages are authoritative β listing pages are not trusted for specs
- No guessing β ambiguous values are discarded, not repaired
- Unit-aware parsing β bhp/ps, Nm/kgm handled safely
- Physics validation β impossible values are rejected
- Completeness over quantity β missing data is better than wrong data
For each bike:
- brand
- model
- engine_cc
- power_bhp
- torque_nm
- kerb_weight_kg
- mileage_kmpl
- abs (if available)
- detail_url
bike-data-collector/ β βββ src/ β βββ main.py # Pipeline entry point β βββ brands.py # Brand discovery β βββ scraper.py # Bike URL extraction β βββ parser.py # Listing-page parsing β βββ detail_parser.py # Detail-page spec discovery β βββ spec_parser.py # Unit-safe spec parsing & validation β βββ save.py # Output writer β βββ filter_complete_bikes.py # Filters fully-usable bikes β βββ config.py # Headers & config β βββ enrich_data.py # (optional / experimental) β βββ normalize_data.py # (optional / experimental) β βββ output/ # Generated datasets (gitignored) βββ requirements.txt βββ README.md βββ .gitignore
pip install -r requirements.txt
python src/main.py
This will:
scrape all brands and bikes
extract authoritative specs
save results to output/bikes.json
π οΈ Manual Bike Entry (Future Use)
The system is designed to support manual bike entry as an optional path.
Manual input is validated using the same physics rules as scraped data.
β οΈ Disclaimer
This project is intended for analysis and research purposes.
Specifications may vary by region, variant, and year.