Rice Classification Model
A deep learning model that identifies rice varieties from images
- %98
- Accuracy
- CNN
- Architecture
- 2024
- Year
Overview
Classifying agricultural produce by expert eye in a lab is both slow and person-dependent. Distinguishing rice varieties is particularly hard; the difference between grains often comes down to a few millimetres of size and ratio.
The model was trained on the rice dataset from Kaggle. Images were normalised first, then data augmentation added rotation, zoom and brightness variation, making the model robust to the variable shooting conditions of the real world. The convolutional neural network was built with dropout layers to prevent overfitting.
It reached 98% accuracy on the test set. Inspecting the confusion matrix showed that most errors clustered between the two varieties that look most alike — which indicates the model learned a meaningful boundary rather than a random one. The model can be tried live on Hugging Face Spaces.
Highlights
- 98% classification accuracy on the test set
- Robustness to real shooting conditions via data augmentation
- Overfitting controlled with dropout layers
- A live demo you can try in the browser
Objectives
- Automate classification that depends on an expert eye
- Produce stable results under variable shooting conditions
- Publish the model so anyone can try it
Solution
- Designing a convolutional neural network architecture
- An image normalisation and augmentation pipeline
- Error analysis with a confusion matrix
- Serving the model on Hugging Face Spaces
Approach
- 01Reviewing and balancing the Kaggle dataset
- 02Model training and hyperparameter experiments
- 03Evaluation and publishing a live demo
Outcomes
- 98% accuracy, close to human expert level
- Errors clustered on visually closest varieties rather than at random
- The model can be tested by anyone through a browser
Challenges
- Separating varieties that look extremely similar
- Preventing overfitting with limited data
- Stability across different lighting conditions
Selected Work
Similar projects

Audio-to-News-Article Agent
An AI tool that turns an audio recording first into text, then into a structured news article, combining speech recognition and natural language processing in a single pipeline.
PDF Q&A Agent (ChatPDF)
A RAG-based assistant that analyses uploaded PDFs and answers user questions grounded in the document's own content.

Real-time Object Detection System
A computer vision application that detects objects in a camera feed in real time using OpenCV and a pre-trained YOLOv3 model.
