Logo Lanfrica

KingDavidJnr/sitesafety-ai

Domaine:

peace and security

Type de record:

project
Créateur:
Kin
Hôte:
A machine learning project for predicting construction site accidents in Lagos, Nigeria. # Construction Site Safety Prediction Model 🏗️👷‍♂️ ## Project Overview This project implements a machine learning-based predictive safety framework for accident prevention on construction sites in Lagos, Nigeria. The model analyzes various site conditions and safety parameters to predict the likelihood of accidents, helping site managers take preventive measures. ## 🎯 Key Features - Synthetic data generation mimicking real construction site conditions - Multiple machine learning models (Logistic Regression, Random Forest, XGBoost) - Comprehensive model evaluation and interpretation - Interactive visualizations for data analysis - Feature importance analysis for decision-making support ## 🔧 Technical Stack - Python 3.8+ - Key libraries: pandas, numpy, scikit-learn, matplotlib, seaborn, xgboost, shap - Jupyter Notebook for interactive analysis ## 📊 Data Features The model considers various factors including: - Time and weather conditions - Worker experience and safety compliance - Equipment usage - Site location - Historical accident data - Supervision status ## 🚀 Getting Started ### Prerequisites - Python 3.8 or higher - pip package manager ### Installation 1. Clone the repository: ```bash git clone github.com cd sitesafety-ai ``` 2. Create and activate a virtual environment (optional but recommended): ```bash python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate ``` 3. Install required packages: ```bash pip install -r requirements.txt ``` ### Running the Project 1. Start Jupyter Notebook: ```bash jupyter notebook ``` 2. Open `construction_safety_prediction.ipynb` in your browser 3. Run all cells to: - Generate synthetic data - Train models - View visualizations and results ## 📈 Model Performance The project includes multiple models with evaluation metrics: - Accuracy - Precision - Recall - F1-score - ROC-AUC curves ## 🎓 Academic Context This project was developed as part of academic research …