How shekhar-commit/multiple_crop_recommendation_system_ works
This Flask crop-advisory application takes soil and climate inputs, validates and averages climate ranges, predicts three crop options, and presents available profitability estimates. A selected crop can then be viewed on a detail page. The graph separates request handling, prediction and profit calculations, and the model/data assets. Source excerpts show the route and data relationships; template contents were not sampled, so their internal interactions are not inferred.
Main entry points: app.py Prediction route · index.html Home page · select_crop.html Crop options · crop_detail.html Crop detail page
Components 15
Web workflow
- Home route
app.py - Home page
templates/index.html - Prediction route
app.py - Crop options
templates/select_crop.html - Detail route
app.py - Crop detail page
templates/crop_detail.html
Recommendation logic
- Input validation
app.py - Crop predictor
app.py - Profit calculator
app.py
Models and crop data
- Crop classifier
models/model_gbc.pkl - Feature scaler
models/scaler.pkl - Crop encoder
models/encoder.pkl - Profit data
crop_data.json - Crop information
crop_agriculture_data.json
Other components
- Farmer
Connections 14
- Farmer → Home route: opens
app.py - Home route → Home page: renders
app.py - Farmer → Prediction route: submits inputs
app.py - Prediction route → Input validation: validates and averages
app.py - Prediction route → Crop predictor: requests predictions
app.py - Crop predictor → Feature scaler: scales features
app.py - Crop predictor → Crop classifier: predicts probabilities
app.py - Crop predictor → Crop encoder: decodes crops
app.py - Prediction route → Profit calculator: calculates options
app.py - Profit calculator → Profit data: reads economics
app.py - Prediction route → Crop options: renders options
app.py - Farmer → Detail route: selects crop
app.py - Detail route → Crop information: reads details
app.py - Detail route → Crop detail page: renders details
app.py