SlideShare a Scribd company logo
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308
__________________________________________________________________________________________
Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 545
GRADING AND QUALITY TESTING OF FOOD GRAINS USING NEURAL
NETWORK
Nandini Sidnal1
, Uttam V. Patil2
, Pankaja Patil3
1
Professor, 2
Assistant Professor, Computer Science and Engineering KLE Dr MSSCET, Belgaum, Karnataka, India,
3
Assistant Professor, Dept of Master of Computer Application, GIT Belgaum, Karnataka, India
sidnal.nandini@gmail.com, mail_uttam@yahoo.com, pankaja_kadalagi@yahoo.co.in
Abstract
The quality of food grains is referred to the every aspect of the profit of supply and marketing. The varietals purity is one of the factors
whose inspection is more difficult and more complicated than that of other factors. In the present grain-handling system, grain type
and quality are rapidly assessed by visual inspection. This evaluation process is, however, tedious and time consuming. The decision-
making capabilities of a grain inspector can be seriously affected by his/her physical condition such as fatigue and eyesight, mental
state caused by biases and work pressure, and working conditions such as improper lighting, climate, etc. The farmers are affected by
this manual activity. Hence, these tasks require automation and develop imaging systems that can be helpful to identify quality of
grain images. A model of quality grade testing and identification is built which is based on appearance features such as the
morphological and colour with technology of computer image processing and neural network. The morphological and colour features
are presented to the neural network for training purposes. The trained network is then used to identify the unknown grain types,
impurities and its quality.
Keywords: Grain quality, image processing, neural network
-----------------------------------------------------------------------***-----------------------------------------------------------------------
1. INTRODUCTION
Grains are the prime crop for our country’s peasants to
increase their agricultural income. The automation level of
testing grain quality is low and most work is done by
manpower. The workload is so mass that it will lead to
workers‟ fatigue and need them to have ample testing
experience. And it also makes the testing more costly and long
to be made. With the development of import and export trade
this contradiction is more and more outstanding [1]. During
grain handling operations, information on grain type and grain
quality is required at several stages before the next course of
operation can be determined and performed. The varietals
purity is one of the factors whose inspection is more difficult
and more complicated than that of other factors. In the present
grain handling system, grain type and quality are rapidly
assessed by visual inspection. This evaluation process is,
however, tedious and time consuming. The decision-making
capabilities of a grain inspector can be seriously affected by
his/her physical condition such as fatigue and eyesight, mental
state caused by biases and work pressure, and working
conditions such as improper lighting, climate, etc. [2].The
farmers are affected by this manual activity. Hence, these
tasks require automation and develop systems that can be
helpful to identify grain images, rectify it & then being
analyzed.
1.1 Problem Definition
In the food industry there are various food stuffs in the form of
grains. The food grain types and their quality are rapidly
assessed through visual inspection by human inspectors. The
decision-making capabilities of human-inspectors are
subjected to external influences. A model of quality testing
and identification is built which is based on appearance
features such as the shape and color with technology of image
processing and neural network. The system will take an image
of grain and identifies the grains and impurities if any and
gives the quality of the grain.
2. DESIGN AND IMPLEMENTATION DETAILS
2.1 System Architecture & Design
The work finds application in grain handling operations at
Agriculture Produce Market Committee (APMC), which is an
important organization that deals with farmers, produce,
measures quality and finally values the produce [3]. Different
food grains like wheat, horse gram, corn and rice are
considered in the study. Considering example of rice, rice is
one of the most important cereal grain crops. The quality of
rice has distinct effect on the yield of rice, so the proper
inspection of rice quality is very important. During grain
handling operations, information on grain type and grain
quality is required at several stages before the next course of
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308
__________________________________________________________________________________________
Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 546
operation can be determined and performed. The varietals
purity is one of the factors whose inspection is more difficult
and more complicated than that of other factors. In the present
grain handling system, grain type and quality are rapidly
assessed by visual inspection. This evaluation process is,
however, tedious and time consuming. The decision-making
capabilities of a grain inspector can be seriously affected by
his/her physical condition such as fatigue and eyesight, mental
state caused by biases and work pressure, and working
conditions such as improper lighting, climate, etc. Hence,
these tasks require automation and develop imaging systems
that can be helpful to identify rice grain images, rectify it &
then being analyzed [5].
Fig -1: Block diagram
2.2 The Work Process of System
 Capturing the image of grains/ images
acquisition
 Image pre-processing
 Image Segmentation and Identifying region of
Interest
 Feature Extraction
 Training and Testing
2.2.1 Image Acquisition
Food grain images acquisition is considered as the most
critical step of the grain recognition system, as it determines
the final grain image quality, which has drastic effects on
overall system performance. A total of around 400 food grain
images are acquired. The images are acquired with a color
Digital Camera. Sony cyber-shot DSCS750 digital camera is
used to capture images. The acquired image is of 2592x1944
resolution. 2.5inch by 3.5 inch area is marked on background
of maroon color. Food grains are positioned beneath the focus
of a camera on that marked area of the background and the
image is captured.
2.2.2 Image Pre-processing
The images acquired with a color Digital Camera is resized to
a resolution of 640 by 480 saved as JPEG image. Further to
remove noise the image is converted to black and white image
and patches in an image are considered using matlab function
bwlabel, Label connected components in binary image. The
patches with size less than 70 pixels are assumed to be noise
and are ignored. The other patches are the region of interest.
2.2.3 Image Segmentation and Identifying Region of
Interest
Connected components labeling scans an image and groups its
pixels into components based on pixel connectivity, i.e. all
pixels in a connected component share similar pixel intensity
values and are in some way connected with each other. Once
all groups have been determined, each pixel is labeled with a
gray level or a color (color labeling) according to the
component it was assigned to. Connected component labeling
works by scanning an image, pixel-by-pixel (from top to
bottom and left to right) in order to identify connected pixel
regions, i.e. regions of adjacent pixels which share the same
set of intensity values V. (For a binary image Original image
is converted to black and white image and patches in an image
are considered using matlab function bwlabel, Label
connected components in binary image. The patches with size
more than 70 pixels are assumed to be the region of interest.
Once the patches (grains and impurities) are identified the top,
bottom, left and right is calculated to crop the segment from
original image.
2.2.4 Feature Extraction
The color features such as mean value of R, the mean value of
G, the mean value of B are calculated and four Morphological
feature namely Area, Major axis length, Minor axis length and
Aspect ratio are extracted and stored in knowledgebase, so a
total of 7 features as listed in table 1 are stored suitably for
later usage in training PNN.
Table -1: Morphological and color features used for grade and
grain classification
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308
__________________________________________________________________________________________
Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 547
2.2.5 Training and Testing Phase
Seven Morphological and color features are extracted from the
images and are stored in the knowledgebase. A probabilistic
neural network (PNN) is predominantly a classifier that maps
any input pattern to a number of classifications. The
probabilistic neural network is trained with eight different
types of food grains namely Sonamasuri rice, Basmati rice,
Horsegram brown, Horsegram white,yellow corn,Gujrat
Wheat, OrangeCorn and Khapli Wheat, with 200 samples.
Testing is the final step of the grain recognition system. In
case of testing phase an image from the testing set (different
from the training set) is selected and its features are extracted
as training images. Then those features are matched with the
feature from the database created for training image. It will
compute the shortest distance between the trained images
stored in the database and the image that was chosen for
testing. Then the image with the shorted distance is chosen to
be recognized. This process is repeated for all the testing
images in order to know the accuracy of the system.
3. THE ALGORITHM: RECOGNITION AND
CLASSIFICATION OF FOOD GRAIN
Input: Original Color Image
Output: Classified food grains along with Quality
Step1: Acquire the food grain images.
Step2: Enhance image to remove noise and resizing.
Step3: Identify Patches and Do the image segmentation.
Step4: Extract Color and morphological features.
Step5: Use these features to recognize and classify the food
grain image samples using Neural network
4. RESULTS AND ANALYSIS
4.1 Training Phase
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Features Extraction (TRAINING PHASE)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Enter Grain Type
1. Rice 2. Wheat 3.Corn 4.Horse Gram 5. Impurity 1
Enter Grain Grade
1. Basamati 2.Sona Masuri 1
Select the Grain image for training phase
Fig.2 Snapshot to select the Grain image
Fig.3: Original Resized Image of basmati rice
Snapshot of the selected basmati rice image after Background
subtraction
Fig.4: After Background subtraction
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308
__________________________________________________________________________________________
Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 548
Fig.5: Black and white Image to find ROI
Snapshot of the selected basmati rice image after segmentation
Fig.6: After Segmentation
The four Morphological feature namely and color features are
extracted and stored in knowledgebase, so a total of 7 features
for each segment of fig 6
4.2. Testing Phase
Select the Grain image for testing phase
Fig.7 Snapshot to select the Grain image during testing phase
The selected image for rice with impurities for testing phase
Fig.9: Original Resized Image of basmati rice
Output: The grain and the impurity is identified and its
quality is
Fig 10: The result after testing
5. RESULTS
More than 160 images were used to test the system and it was
found that accuracy of identifying grain and its grade is
100%.Where as the accuracy of identifying quality of grains
was 80-90% accurate for each grain type. The testing results
are as shown below in table 2. The result analysis is as shown
in figure 11
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308
__________________________________________________________________________________________
Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 549
Table 2: Consolidated results of all grains with accuracy of
testing
It is very clear from the graph below that accuracy of
identifying grain and its grade is 100%.Where as the accuracy
of identifying quality of grains is in the range of 80-90% for
each grain type.
Fig 11: Results of all grains with accuracy of testing
CONCLUSIONS
The system identifies the quality of grains which is based on
appearance features such as the shape and color, with
technology of image processing and neural network. More
than 160 Images were used to test the system and it was found
that accuracy of identifying grain and its grade is
100%.Quality testing of grains was 80-90% accurate for each
grain type. A very simple method is proposed for
classification of food grains which require limited features and
thus overcoming the disadvantages like tediousness and time
consumption. The quality of food grain includes not only
exterior quality but also the interior one such as the texture,
the nutrient component, the protein, moisture of the grain and
producing area. The latter is not researched in this work
because of the limitation of machine vision. It is difficult to
test the features by visual image.
REFERENCES
[1]. HAN Zhong-zhi; LI Yan-zhao; LIU Jing; ZHAO You-
gang, Quality Grade Testing of Peanut Based on Image
Processing, 2010,IEEE
[2]. Sanjivani Shantaiya, Mrs.Uzma Ansari, Identification Of
Food Grains And Its Quality Using Pattern lassification,
Special Issue of IJCCT Vol. 2 Issue 2, 3, 4; 2010 for
International Conference [ICCT-2010], 3rd December 2010
[3]. B. S. ANAMI, D. G. SAVAKAR,Improved Method for
Identification and Classification of Foreign Bodies Mixed
Food Grains Image Samples, ICGSTAIML Journal, ISSN:
1687-4846, Volume 9, Issue I, February 2009
[4]. Basavaraj .S. Anami and Vishwanath.C.Burkpalli, Texture
based Identification and Classification of Bulk Sugary Food
Objects, ICGST-GVIP Journal, ISSN: 1687-398X, Volume 9,
Issue 4, August 2009
[5]. Basavaraj S. Anami, Dayanand G. Savakar, Effect of
Foreign Bodies on Recognition and Classification of Bulk
Food Grain Image Samples, Journal of Applied Computer
Science, no. 6 (3) /2009, Suceava.
[6]. D. M. Hobson, R. M. Carter, Y. Yan, Characterisation and
Identification of Rice Grains through Digital Image
Analysis,2007,IMTC
[7]. ABDELLAOUI Mehrez , DOUIK Ali, Hybrid method for
cereal grain identification using morphological and color
features, 1-4244-0395-2/06/$20.00 ©2006 IEEE.
[8]. LIU Zhao-yan ,CHENG Fang , YING Yi-bin , RAO Xiu-
qin ,Identification of rice seed varieties using neural network,
Journal of Zhejiang University SCIENCE

More Related Content

PDF
Grading and quality testing of food grains using neural
PDF
Identification and Classification of Leaf Diseases in Turmeric Plants
PDF
Gw3512081212
PDF
IRJET - Calorie Detector
PDF
IRJET- A Fruit Quality Inspection Sytem using Faster Region Convolutional...
PDF
Classification of Macronutrient Deficiencies in Maize Plant Using Machine Lea...
PDF
Paper id 71201958
PDF
Analysis And Detection of Infected Fruit Part Using Improved k-means Clusteri...
Grading and quality testing of food grains using neural
Identification and Classification of Leaf Diseases in Turmeric Plants
Gw3512081212
IRJET - Calorie Detector
IRJET- A Fruit Quality Inspection Sytem using Faster Region Convolutional...
Classification of Macronutrient Deficiencies in Maize Plant Using Machine Lea...
Paper id 71201958
Analysis And Detection of Infected Fruit Part Using Improved k-means Clusteri...

What's hot (18)

PDF
A survey on content based medical image retrieval for
PDF
IRJET- A Food Recognition System for Diabetic Patients based on an Optimized ...
PDF
A Study of Image Processing in Agriculture
PDF
IRJET- Identify Quality Index of the Fruit Vegetable by Non Destructive or wi...
PPT
Defected fruit detection
PDF
Using k means cluster and fuzzy c means for defect segmentation in fruits
PPTX
Behavior-Based Authentication System Based on Smartphone Life-Logs Data
PDF
La2418611866
PDF
IRJET- Automatic Fruit Quality Detection System
PDF
Classification of Mango Fruit Varieties using Naive Bayes Algorithm
PDF
Computer Vision based Model for Fruit Sorting using K-Nearest Neighbour clas...
PDF
Machine learning application-automated fruit sorting technique
PPTX
Fruit detection using morphological
PDF
F010423541
PDF
Image Mining for Flower Classification by Genetic Association Rule Mining Usi...
PDF
Brain tumor pattern recognition using correlation filter
PDF
Weed and crop segmentation and classification using area thresholding
DOCX
Dip thesis
A survey on content based medical image retrieval for
IRJET- A Food Recognition System for Diabetic Patients based on an Optimized ...
A Study of Image Processing in Agriculture
IRJET- Identify Quality Index of the Fruit Vegetable by Non Destructive or wi...
Defected fruit detection
Using k means cluster and fuzzy c means for defect segmentation in fruits
Behavior-Based Authentication System Based on Smartphone Life-Logs Data
La2418611866
IRJET- Automatic Fruit Quality Detection System
Classification of Mango Fruit Varieties using Naive Bayes Algorithm
Computer Vision based Model for Fruit Sorting using K-Nearest Neighbour clas...
Machine learning application-automated fruit sorting technique
Fruit detection using morphological
F010423541
Image Mining for Flower Classification by Genetic Association Rule Mining Usi...
Brain tumor pattern recognition using correlation filter
Weed and crop segmentation and classification using area thresholding
Dip thesis
Ad

Viewers also liked (7)

DOCX
5G wireless technology Report
PDF
5G Technology
DOCX
Blue brain document
PPTX
Blue Brain
DOCX
5G technology documentation
PDF
5 g wireless system
PPTX
5G Wireless Technology
5G wireless technology Report
5G Technology
Blue brain document
Blue Brain
5G technology documentation
5 g wireless system
5G Wireless Technology
Ad

Similar to Grading and quality testing of food grains using neural network (20)

PDF
Quality Analysis and Classification of Rice Grains using Image Processing Tec...
PDF
Automatic Seed Classification by Shape and Color Features using Machine Visio...
PDF
Classification of Wheat Grains Using Machine Algorithms
PPTX
phase 1 ppt dal adulteration.pptx
PDF
Quality Analysis of Food Grains and Liquids
PDF
Am31268273
PDF
B04630510
PDF
IRJET-Next Generation Sequences Analysis using Pattern Matching Algorithm
PDF
Sorting of Raisins using Computer Vision Approach
PDF
IRJET- Comparative Study of Artificial Neural Networks and Convolutional N...
PDF
Gq3611971205
PPT
Application of soft computing in food processing sector
PDF
K010516270
PDF
Seeding precision: a mask region based convolutional neural networks classifi...
PDF
IMAGE BASED RECOGNITION - RECENT CHALLENGES AND SOLUTIONS ILLUSTRATED ON APPL...
PPTX
Recipe Detection Of Image Using Deep Learning.pptx
PPTX
systematic Literature Review for Classificatin of Wheat
PDF
IJSRED-V2I3P35
PDF
ResSeg: Residual encoder-decoder convolutional neural network for food segmen...
PDF
Non-Destructive Quality Analysis of Gujarat 17 Oryza Sativa SSP Indica (India...
Quality Analysis and Classification of Rice Grains using Image Processing Tec...
Automatic Seed Classification by Shape and Color Features using Machine Visio...
Classification of Wheat Grains Using Machine Algorithms
phase 1 ppt dal adulteration.pptx
Quality Analysis of Food Grains and Liquids
Am31268273
B04630510
IRJET-Next Generation Sequences Analysis using Pattern Matching Algorithm
Sorting of Raisins using Computer Vision Approach
IRJET- Comparative Study of Artificial Neural Networks and Convolutional N...
Gq3611971205
Application of soft computing in food processing sector
K010516270
Seeding precision: a mask region based convolutional neural networks classifi...
IMAGE BASED RECOGNITION - RECENT CHALLENGES AND SOLUTIONS ILLUSTRATED ON APPL...
Recipe Detection Of Image Using Deep Learning.pptx
systematic Literature Review for Classificatin of Wheat
IJSRED-V2I3P35
ResSeg: Residual encoder-decoder convolutional neural network for food segmen...
Non-Destructive Quality Analysis of Gujarat 17 Oryza Sativa SSP Indica (India...

More from eSAT Journals (20)

PDF
Mechanical properties of hybrid fiber reinforced concrete for pavements
PDF
Material management in construction – a case study
PDF
Managing drought short term strategies in semi arid regions a case study
PDF
Life cycle cost analysis of overlay for an urban road in bangalore
PDF
Laboratory studies of dense bituminous mixes ii with reclaimed asphalt materials
PDF
Laboratory investigation of expansive soil stabilized with natural inorganic ...
PDF
Influence of reinforcement on the behavior of hollow concrete block masonry p...
PDF
Influence of compaction energy on soil stabilized with chemical stabilizer
PDF
Geographical information system (gis) for water resources management
PDF
Forest type mapping of bidar forest division, karnataka using geoinformatics ...
PDF
Factors influencing compressive strength of geopolymer concrete
PDF
Experimental investigation on circular hollow steel columns in filled with li...
PDF
Experimental behavior of circular hsscfrc filled steel tubular columns under ...
PDF
Evaluation of punching shear in flat slabs
PDF
Evaluation of performance of intake tower dam for recent earthquake in india
PDF
Evaluation of operational efficiency of urban road network using travel time ...
PDF
Estimation of surface runoff in nallur amanikere watershed using scs cn method
PDF
Estimation of morphometric parameters and runoff using rs & gis techniques
PDF
Effect of variation of plastic hinge length on the results of non linear anal...
PDF
Effect of use of recycled materials on indirect tensile strength of asphalt c...
Mechanical properties of hybrid fiber reinforced concrete for pavements
Material management in construction – a case study
Managing drought short term strategies in semi arid regions a case study
Life cycle cost analysis of overlay for an urban road in bangalore
Laboratory studies of dense bituminous mixes ii with reclaimed asphalt materials
Laboratory investigation of expansive soil stabilized with natural inorganic ...
Influence of reinforcement on the behavior of hollow concrete block masonry p...
Influence of compaction energy on soil stabilized with chemical stabilizer
Geographical information system (gis) for water resources management
Forest type mapping of bidar forest division, karnataka using geoinformatics ...
Factors influencing compressive strength of geopolymer concrete
Experimental investigation on circular hollow steel columns in filled with li...
Experimental behavior of circular hsscfrc filled steel tubular columns under ...
Evaluation of punching shear in flat slabs
Evaluation of performance of intake tower dam for recent earthquake in india
Evaluation of operational efficiency of urban road network using travel time ...
Estimation of surface runoff in nallur amanikere watershed using scs cn method
Estimation of morphometric parameters and runoff using rs & gis techniques
Effect of variation of plastic hinge length on the results of non linear anal...
Effect of use of recycled materials on indirect tensile strength of asphalt c...

Recently uploaded (20)

PPT
Project quality management in manufacturing
PPTX
Foundation to blockchain - A guide to Blockchain Tech
PDF
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
PPTX
bas. eng. economics group 4 presentation 1.pptx
PPTX
Construction Project Organization Group 2.pptx
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PPTX
OOP with Java - Java Introduction (Basics)
PPTX
UNIT 4 Total Quality Management .pptx
PPTX
UNIT-1 - COAL BASED THERMAL POWER PLANTS
PDF
Digital Logic Computer Design lecture notes
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
PPTX
Geodesy 1.pptx...............................................
PDF
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
PPTX
additive manufacturing of ss316l using mig welding
PDF
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PDF
Unit I ESSENTIAL OF DIGITAL MARKETING.pdf
PDF
PPT on Performance Review to get promotions
Project quality management in manufacturing
Foundation to blockchain - A guide to Blockchain Tech
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
bas. eng. economics group 4 presentation 1.pptx
Construction Project Organization Group 2.pptx
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
OOP with Java - Java Introduction (Basics)
UNIT 4 Total Quality Management .pptx
UNIT-1 - COAL BASED THERMAL POWER PLANTS
Digital Logic Computer Design lecture notes
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
Geodesy 1.pptx...............................................
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
additive manufacturing of ss316l using mig welding
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
Unit I ESSENTIAL OF DIGITAL MARKETING.pdf
PPT on Performance Review to get promotions

Grading and quality testing of food grains using neural network

  • 1. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 545 GRADING AND QUALITY TESTING OF FOOD GRAINS USING NEURAL NETWORK Nandini Sidnal1 , Uttam V. Patil2 , Pankaja Patil3 1 Professor, 2 Assistant Professor, Computer Science and Engineering KLE Dr MSSCET, Belgaum, Karnataka, India, 3 Assistant Professor, Dept of Master of Computer Application, GIT Belgaum, Karnataka, India sidnal.nandini@gmail.com, mail_uttam@yahoo.com, pankaja_kadalagi@yahoo.co.in Abstract The quality of food grains is referred to the every aspect of the profit of supply and marketing. The varietals purity is one of the factors whose inspection is more difficult and more complicated than that of other factors. In the present grain-handling system, grain type and quality are rapidly assessed by visual inspection. This evaluation process is, however, tedious and time consuming. The decision- making capabilities of a grain inspector can be seriously affected by his/her physical condition such as fatigue and eyesight, mental state caused by biases and work pressure, and working conditions such as improper lighting, climate, etc. The farmers are affected by this manual activity. Hence, these tasks require automation and develop imaging systems that can be helpful to identify quality of grain images. A model of quality grade testing and identification is built which is based on appearance features such as the morphological and colour with technology of computer image processing and neural network. The morphological and colour features are presented to the neural network for training purposes. The trained network is then used to identify the unknown grain types, impurities and its quality. Keywords: Grain quality, image processing, neural network -----------------------------------------------------------------------***----------------------------------------------------------------------- 1. INTRODUCTION Grains are the prime crop for our country’s peasants to increase their agricultural income. The automation level of testing grain quality is low and most work is done by manpower. The workload is so mass that it will lead to workers‟ fatigue and need them to have ample testing experience. And it also makes the testing more costly and long to be made. With the development of import and export trade this contradiction is more and more outstanding [1]. During grain handling operations, information on grain type and grain quality is required at several stages before the next course of operation can be determined and performed. The varietals purity is one of the factors whose inspection is more difficult and more complicated than that of other factors. In the present grain handling system, grain type and quality are rapidly assessed by visual inspection. This evaluation process is, however, tedious and time consuming. The decision-making capabilities of a grain inspector can be seriously affected by his/her physical condition such as fatigue and eyesight, mental state caused by biases and work pressure, and working conditions such as improper lighting, climate, etc. [2].The farmers are affected by this manual activity. Hence, these tasks require automation and develop systems that can be helpful to identify grain images, rectify it & then being analyzed. 1.1 Problem Definition In the food industry there are various food stuffs in the form of grains. The food grain types and their quality are rapidly assessed through visual inspection by human inspectors. The decision-making capabilities of human-inspectors are subjected to external influences. A model of quality testing and identification is built which is based on appearance features such as the shape and color with technology of image processing and neural network. The system will take an image of grain and identifies the grains and impurities if any and gives the quality of the grain. 2. DESIGN AND IMPLEMENTATION DETAILS 2.1 System Architecture & Design The work finds application in grain handling operations at Agriculture Produce Market Committee (APMC), which is an important organization that deals with farmers, produce, measures quality and finally values the produce [3]. Different food grains like wheat, horse gram, corn and rice are considered in the study. Considering example of rice, rice is one of the most important cereal grain crops. The quality of rice has distinct effect on the yield of rice, so the proper inspection of rice quality is very important. During grain handling operations, information on grain type and grain quality is required at several stages before the next course of
  • 2. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 546 operation can be determined and performed. The varietals purity is one of the factors whose inspection is more difficult and more complicated than that of other factors. In the present grain handling system, grain type and quality are rapidly assessed by visual inspection. This evaluation process is, however, tedious and time consuming. The decision-making capabilities of a grain inspector can be seriously affected by his/her physical condition such as fatigue and eyesight, mental state caused by biases and work pressure, and working conditions such as improper lighting, climate, etc. Hence, these tasks require automation and develop imaging systems that can be helpful to identify rice grain images, rectify it & then being analyzed [5]. Fig -1: Block diagram 2.2 The Work Process of System  Capturing the image of grains/ images acquisition  Image pre-processing  Image Segmentation and Identifying region of Interest  Feature Extraction  Training and Testing 2.2.1 Image Acquisition Food grain images acquisition is considered as the most critical step of the grain recognition system, as it determines the final grain image quality, which has drastic effects on overall system performance. A total of around 400 food grain images are acquired. The images are acquired with a color Digital Camera. Sony cyber-shot DSCS750 digital camera is used to capture images. The acquired image is of 2592x1944 resolution. 2.5inch by 3.5 inch area is marked on background of maroon color. Food grains are positioned beneath the focus of a camera on that marked area of the background and the image is captured. 2.2.2 Image Pre-processing The images acquired with a color Digital Camera is resized to a resolution of 640 by 480 saved as JPEG image. Further to remove noise the image is converted to black and white image and patches in an image are considered using matlab function bwlabel, Label connected components in binary image. The patches with size less than 70 pixels are assumed to be noise and are ignored. The other patches are the region of interest. 2.2.3 Image Segmentation and Identifying Region of Interest Connected components labeling scans an image and groups its pixels into components based on pixel connectivity, i.e. all pixels in a connected component share similar pixel intensity values and are in some way connected with each other. Once all groups have been determined, each pixel is labeled with a gray level or a color (color labeling) according to the component it was assigned to. Connected component labeling works by scanning an image, pixel-by-pixel (from top to bottom and left to right) in order to identify connected pixel regions, i.e. regions of adjacent pixels which share the same set of intensity values V. (For a binary image Original image is converted to black and white image and patches in an image are considered using matlab function bwlabel, Label connected components in binary image. The patches with size more than 70 pixels are assumed to be the region of interest. Once the patches (grains and impurities) are identified the top, bottom, left and right is calculated to crop the segment from original image. 2.2.4 Feature Extraction The color features such as mean value of R, the mean value of G, the mean value of B are calculated and four Morphological feature namely Area, Major axis length, Minor axis length and Aspect ratio are extracted and stored in knowledgebase, so a total of 7 features as listed in table 1 are stored suitably for later usage in training PNN. Table -1: Morphological and color features used for grade and grain classification
  • 3. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 547 2.2.5 Training and Testing Phase Seven Morphological and color features are extracted from the images and are stored in the knowledgebase. A probabilistic neural network (PNN) is predominantly a classifier that maps any input pattern to a number of classifications. The probabilistic neural network is trained with eight different types of food grains namely Sonamasuri rice, Basmati rice, Horsegram brown, Horsegram white,yellow corn,Gujrat Wheat, OrangeCorn and Khapli Wheat, with 200 samples. Testing is the final step of the grain recognition system. In case of testing phase an image from the testing set (different from the training set) is selected and its features are extracted as training images. Then those features are matched with the feature from the database created for training image. It will compute the shortest distance between the trained images stored in the database and the image that was chosen for testing. Then the image with the shorted distance is chosen to be recognized. This process is repeated for all the testing images in order to know the accuracy of the system. 3. THE ALGORITHM: RECOGNITION AND CLASSIFICATION OF FOOD GRAIN Input: Original Color Image Output: Classified food grains along with Quality Step1: Acquire the food grain images. Step2: Enhance image to remove noise and resizing. Step3: Identify Patches and Do the image segmentation. Step4: Extract Color and morphological features. Step5: Use these features to recognize and classify the food grain image samples using Neural network 4. RESULTS AND ANALYSIS 4.1 Training Phase ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Features Extraction (TRAINING PHASE) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Enter Grain Type 1. Rice 2. Wheat 3.Corn 4.Horse Gram 5. Impurity 1 Enter Grain Grade 1. Basamati 2.Sona Masuri 1 Select the Grain image for training phase Fig.2 Snapshot to select the Grain image Fig.3: Original Resized Image of basmati rice Snapshot of the selected basmati rice image after Background subtraction Fig.4: After Background subtraction
  • 4. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 548 Fig.5: Black and white Image to find ROI Snapshot of the selected basmati rice image after segmentation Fig.6: After Segmentation The four Morphological feature namely and color features are extracted and stored in knowledgebase, so a total of 7 features for each segment of fig 6 4.2. Testing Phase Select the Grain image for testing phase Fig.7 Snapshot to select the Grain image during testing phase The selected image for rice with impurities for testing phase Fig.9: Original Resized Image of basmati rice Output: The grain and the impurity is identified and its quality is Fig 10: The result after testing 5. RESULTS More than 160 images were used to test the system and it was found that accuracy of identifying grain and its grade is 100%.Where as the accuracy of identifying quality of grains was 80-90% accurate for each grain type. The testing results are as shown below in table 2. The result analysis is as shown in figure 11
  • 5. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 02 Issue: 11 | Nov-2013, Available @ http://www.ijret.org 549 Table 2: Consolidated results of all grains with accuracy of testing It is very clear from the graph below that accuracy of identifying grain and its grade is 100%.Where as the accuracy of identifying quality of grains is in the range of 80-90% for each grain type. Fig 11: Results of all grains with accuracy of testing CONCLUSIONS The system identifies the quality of grains which is based on appearance features such as the shape and color, with technology of image processing and neural network. More than 160 Images were used to test the system and it was found that accuracy of identifying grain and its grade is 100%.Quality testing of grains was 80-90% accurate for each grain type. A very simple method is proposed for classification of food grains which require limited features and thus overcoming the disadvantages like tediousness and time consumption. The quality of food grain includes not only exterior quality but also the interior one such as the texture, the nutrient component, the protein, moisture of the grain and producing area. The latter is not researched in this work because of the limitation of machine vision. It is difficult to test the features by visual image. REFERENCES [1]. HAN Zhong-zhi; LI Yan-zhao; LIU Jing; ZHAO You- gang, Quality Grade Testing of Peanut Based on Image Processing, 2010,IEEE [2]. Sanjivani Shantaiya, Mrs.Uzma Ansari, Identification Of Food Grains And Its Quality Using Pattern lassification, Special Issue of IJCCT Vol. 2 Issue 2, 3, 4; 2010 for International Conference [ICCT-2010], 3rd December 2010 [3]. B. S. ANAMI, D. G. SAVAKAR,Improved Method for Identification and Classification of Foreign Bodies Mixed Food Grains Image Samples, ICGSTAIML Journal, ISSN: 1687-4846, Volume 9, Issue I, February 2009 [4]. Basavaraj .S. Anami and Vishwanath.C.Burkpalli, Texture based Identification and Classification of Bulk Sugary Food Objects, ICGST-GVIP Journal, ISSN: 1687-398X, Volume 9, Issue 4, August 2009 [5]. Basavaraj S. Anami, Dayanand G. Savakar, Effect of Foreign Bodies on Recognition and Classification of Bulk Food Grain Image Samples, Journal of Applied Computer Science, no. 6 (3) /2009, Suceava. [6]. D. M. Hobson, R. M. Carter, Y. Yan, Characterisation and Identification of Rice Grains through Digital Image Analysis,2007,IMTC [7]. ABDELLAOUI Mehrez , DOUIK Ali, Hybrid method for cereal grain identification using morphological and color features, 1-4244-0395-2/06/$20.00 ©2006 IEEE. [8]. LIU Zhao-yan ,CHENG Fang , YING Yi-bin , RAO Xiu- qin ,Identification of rice seed varieties using neural network, Journal of Zhejiang University SCIENCE