Abdalllah/crop-irrigation-mlflow
๐พ Intelligent Crop Irrigation Advisor - MLflow Dashboard
  
Live ML Experiment Tracking & Model Registry for Smart Agriculture ๐
๐ Dashboard Overview
This MLflow server provides real-time tracking for 3 production-ready ML models that power an intelligent crop irrigation system:
๐ฏ Models Tracked
1๏ธโฃ Crop Recommendation Model
Algorithm: Random Forest Classifier
Accuracy: 99.32%
Precision: 99.37%
Purpose: Predict optimal crop for soil conditions
Features: NPK levels, pH, Temperature, Humidity, Rainfall
Classes: 22 different crops2๏ธโฃ Irrigation Optimization Model
Algorithm: CatBoost Regressor
Rยฒ Score: 0.974
MAE: 0.683 mm
RMSE: 2.603 mm
Purpose: Calculate precise water amount needed
Features: 30+ engineered features (soil, weather, crop data)3๏ธโฃ Smart Irrigation Classifier
Algorithm: CatBoost + Optuna Hyperparameter Tuning
Accuracy: 83.61%
F1 Score: 83.57%
Purpose: Binary classification - irrigate or not
Trials: 10 Optuna optimization runs tracked๐ How to Use This Dashboard
Navigate Through:
- ๐ Experiments โ View all training runs with metrics & parameters
- ๐ Compare โ Side-by-side comparison of multiple runs
- ๐ Models โ Model Registry with versioning
CropRecommendationModel(v2)IrrigationOptimizationModel(v1)SmartIrrigationClassifierModel(v1)
Quick Start:
- View Experiments: Click on any experiment name to see runs
- Compare Runs: Select multiple runs โ Click "Compare"
- Download Models: Go to "Models" tab โ Download .pkl files
- Visualize Metrics: Charts auto-generated for all logged metrics
๏ฟฝ Key Features
โ Real-time Tracking - Live experiment monitoring โ Parameter Comparison - Compare hyperparameters across runs โ Metric Visualization - Interactive charts for accuracy, loss, Rยฒ โ Model Registry - Versioned model storage with lineage โ Artifact Storage - Models, plots, and reports โ Optuna Integration - Hyperparameter optimization trials
๐ Metrics Dashboard
Tracked Metrics:
- Classification: Accuracy, Precision, Recall, F1 Score
- Regression: Rยฒ Score, MAE, RMSE, Adjusted Rยฒ
- Feature Importance: Top features for each model
- Training Time: Duration per run
Logged Parameters:
- Model hyperparameters (learning_rate, depth, iterations)
- Data split ratios (testsamples, trainsamples)
- Feature engineering settings
- Random seeds for reproducibility
๐ Related Links
- ๐ GitHub Repository: Intelligent-Crop-Irrigation-Advisor
- ๐ Documentation: Full project docs in repo
- ๐ฑ Dataset: Agricultural data with soil & weather features
- ๐ง MLflow Guide: Setup instructions in
MLFLOW_SETUP.md
๏ฟฝ Tech Stack
๐ Model Performance Summary
๐ Use Cases
- ๐พ Precision Agriculture: Optimize crop selection & water usage
- ๐ง Water Conservation: Reduce water waste by 20-30%
- ๐ Farm Management: Data-driven irrigation decisions
- ๐ฌ Agricultural Research: Analyze model performance over time
๐ ๏ธ Local Development
Want to run this locally? Clone the repo:
git clone https://github.com/Iabdallllah/Intelligent-Crop-Irrigation-Advisor.git
cd Intelligent-Crop-Irrigation-Advisor
pip install -r requirements.txt
python mlflow_tools/launch_mlflow.pyOpen: http://localhost:5000
๐ License
MIT License - See LICENSE for details
๐จโ๐ป Author
Abdallah - Agricultural AI Solutions ๐ GitHub Profile
๐ Acknowledgments
Built with passion for sustainable agriculture and smart farming ๐ฑ
Using AI to grow more with less ๐
โก This Space is powered by Hugging Face Spaces + Docker + MLflow
