Skip to content

Crop Yield Predictor#1854

Merged
omroy07 merged 2 commits into
omroy07:mainfrom
Aditya8369:246
Jun 1, 2026
Merged

Crop Yield Predictor#1854
omroy07 merged 2 commits into
omroy07:mainfrom
Aditya8369:246

Conversation

@Aditya8369
Copy link
Copy Markdown
Contributor

Here is a summary of what was accomplished:

ML Training & Evaluation Script: Modified crop_yield_predictor.py to train a Random Forest model on the historical dataset with $97.30%$ $R^2$ accuracy. Integrated metric calculation (R2, MAE, RMSE) and plotted feature importance and test set actual-vs-predicted comparison charts (saved under assets/).
Interactive CLI Tool: Created predict_yield_cli.py, which interactively prompts the user for environmental and geographic parameters, suggests closest matches for unrecognized region names or crop types, runs inference using a Pandas DataFrame to align feature names, and yields prediction estimates safely.
Execution Safety: Removed emoji characters from stdout outputs in both files to prevent cp1252 Windows console encoding errors.
Verification: Executed the model training pipeline successfully and simulated CLI inputs to verify that the predictor outputs correct yields without warning.

closes #246

@vercel
Copy link
Copy Markdown

vercel Bot commented Jun 1, 2026

@Aditya8369 is attempting to deploy a commit to the Om Roy's projects Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 1, 2026

Thanks for creating a PR for your Issue! ☺️

We'll review it as soon as possible.
In the meantime, please double-check the file changes and ensure that all commits are accurate.

If there are any unresolved review comments, feel free to resolve them. 🙌🏼

@Aditya8369
Copy link
Copy Markdown
Contributor Author

@omroy07 please merge under NSOC

@omroy07 omroy07 merged commit db56761 into omroy07:main Jun 1, 2026
1 of 4 checks passed
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 1, 2026

🎉 Congrats @Aditya8369 on getting your PR merged! 🙌
Thanks for the contribution — looking forward to more from you 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Crop Yield Predictor

2 participants