You are on page 1of 5

2018 Third International Conference on Electrical, Electronics, Communication, Computer Technologies and Optimization Techniques

(ICEECCOT) 14-15, December 2018

Segmentation of Arecanut Bunches using HSV Color


Model
Dhanesha R. Shrinivasa Naika C. L.
Dept. of studies in CS&E Dept. of studies in CS&E
U. B. D. T. College of Engineering, U. B. D. T. College of Engineering,
Davanagere, Karnataka, India 577004 Davanagere, Karnataka, India 577004
dhaneshphddoc@gmail.com naika2k6@gmail.com

Abstract—Arecanut is one of the commercial crop of south India. starts after 5 years of planting. Different stages of matured
Arecanut maturity level decides its price in the market. To arecanut are starts with spadix, which includes male and
maximize the profitability, Farmer needs expertise to determine female flowers. Male flowers become waste inflorescences
the maturity level of Arecanut. This lack of ability leads to low and female flowers become arecanuts. After spadix it will
profit for their crops. Use of Image Processing and Computer take 6 months to become matured arecanut. Farmer not able
Vision techniques in precision agriculture allowed farmers to to track which spadix completed 6 months, because in one
take necessary steps to harvest by identifying the maturity level hectare of land it may contain 1200 arecanut plants and each
of fruits and vegetables. To identify maturity level segmentation plant may contain 4 to 5 bunches. So, it is difficult for farmer
of Arecanut bunches is required for automated expertise. In this to identify ripeness level before harvest.
paper, proposed a segmentation method to segment Arecanut
bunches using HSV color model towards the view of identifying
automatic maturity level of arecanut bunches. The results of
experiment clarifies the proposed method effectiveness which is
better to segment the arecanut bunches for future analysis.
Index Terms—ripeness, harvesting, segmentation, erosion, closing,
arecanut bunches and HSV (Hue Saturation Value).

I. INTRODUCTION

Arecanut is the dried seed of the palm tree. Arecanut play


a prominent role in the religious, social, culture functions
and in economic life of the people in India. The fourth most
frequently used psychoactive substance is Areca catechu in
the world after nicotine, alcohol and caffeine. In India 4.73 Figure 1. Parts of Arecanut Plant
lakh hectares (HA) of land has been utilized for Arecanut
cultivation with the production of 7.06 lakh tons. Majority of Arecanut bunches are broadly classified into two types such
Arecanut grows in the states of Karnataka and Kerala [9]. as immature (unripe) and mature (ripe, overripe) bunches.
Harvesting immature arecanut bunches it is huge loss for
Arecanut is one of the major commercial crop of farmer. Figure 2, shows Api, Bette, Mine and Gotu are the
south India. Apart from chewing purpose, it is used as different levels of Arecanut in respect of maturity levels of
ingredients in making areca tea, soaps, diabetes formulations, Arecanut.. The different maturity level of Arecanut decides
tooth powder, pan masala, gutka, soft drinks, wines and the price of it in market. The maturity level increases, the
ayurvedic medicine [9]. cost of arecanut decreases.

Figure 1, shows parts of Arecanut plant. The maximum To maximize profitability of crop, Farmer needs to
height of Arecanut plant is 30 to 40 feet and maximum round know maturity level of Arecanut before harvesting. Nowadays
bark of stem is 15 to 20 cm. it is purely depends on varieties there is lack of expert labors to identify maturity level of
of Arecanut plants. Arecanut bunches. So, its very tiresome job for a farmer to
harvest Arecanut bunches with an accurate maturity level.
In Arecanut plantation (farming), the nut bearing As mentioned above different levels of arecanut are

978-1-5386-5130-8/18/$31.00
c 2018 IEEE
37

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 26,2020 at 01:38:10 UTC from IEEE Xplore. Restrictions apply.
of color gives more grayness of color and more fades of color
will appear. In proposed work, saturation value is normalised
in range of 0–1.

Figure 2. Analysis of Maturity level

available, if the former failed to harvest the arecanut bunches Figure 3. Hue range [7].
in time, it leads to low profit for their crops.
Hue refers to color type, such as red (0◦ - 60◦ ), yellow
In precision agriculture Image processing and computer (60◦ - 120◦ ), green(120◦ - 180◦ ), cyan,(180◦ -240◦ ), blue(240◦ -
vision techniques are grown rapidly. Anuja Bhargava and 300◦ ), magenta(300◦ - 360◦ ). (as it is described in Figure 3).
Atul Bansal [1], described a detailed summary of various Figure 4, shows a decent illustration of HSV color space,
techniques to classify fruits and vegetables quality by where the hue is portrayed as a three-dimensional cone like
considering features as color, shape, texture and size. In formation of the color wheel. The saturation is delineated by
[2], a method was presented for detection of deficiency in the area from middle of a circular cross-sectional of the cone.
orange fruits. Segmentation technique are used for detection The value is the distance from the pointed end of the cone.
of defects in orange fruits. To classify defects orange fruits
graph based and k-means clustering techniques are used. To convert RGB image to HSV image, first need to
extract Red(r), Green (g) and Blue (b) components of an
Stephen Nuske et.al [5], presented an automated method image. To extract Red component make other two components
using shape and texture features to recognize and determine (Green and Blue) of RGB image as zero intensity. To extract
number of grape berries. The number of grape berries decides Green component make Red and Blue components of RGB
the crop yield to generate per vine estimation. Ajit Danti and image as zero intensity. Similarly, extract Blue component by
suresha [3], presented a method to classify two category of making Red and Green components as zero intensity.
raw Arecanut. Raw Arecanut are classified using the variation
of RGB components with upper and lower limits based on
red and green color as dominant color.

D. Stajnko et.al [8], proposed computerized vision


based approach using HSV color space for analysis of fruit
color to detect apples. Also described the estimation of
diameter and determination of number of apple fruit on a
Figure 4. Conical representation of the HSV model [7].
tree. Garrett M. Johnson et.al [6], presented a survey on
color spaces to derive new color space and also described The following expressions (eqs. (1)(2)(3) and(4)) are used
to calculate color differences using spatial filters. Dah-Jye to covert RGB color space to HSV color space.
Lee et.al [4], presented a color segmentation method by (
considering color as main feature to determine the quality of θ, if b Lessthan or equalto g
fruits and in turn decides the grading of fruits such as tomato Hue = (1)
360 − θ, if b Greaterthan g
and dates.

In this paper, in order to segment the arecanut bunches; with


a HSV color model is exploited to segment the bunches 
0.5 ∗ [(r − g) + (r − b)]

−1
which would be used towards attuning detection of automatic θ = cos (2)
[(r − g)2 + (r − b)(g − b)]0.5
maturity level of arecanut bunches.
The saturation(Sat) channel is computed by
A. RGB to HSV color model
3
HSV color model, in which H represents Hue (color-depth) Sat = 1 − [min(r, g, b)] (3)
(r + g + b)
, S represents Saturation (color-purity) and V represents value
of intensity (color-brightness). HSV is also referred as Finally, Value(Val) channel is computed by
HSB (Hue Saturation Brightness) and HSI (Hue Saturation
Intensity). Hue defines pure color in terms of green, red or 1
V al =
(r + g + b). (4)
magenta. When measured in degrees Hue ranges from 0◦ to 3
360◦ . Saturation refers to purity of color. It takes values from It is assumed that angle theta is computed in HSV space in
0% (gray) to 100% (pure color), means lower the saturation respect of Red axis and the values of rgb is normalized to

38

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 26,2020 at 01:38:10 UTC from IEEE Xplore. Restrictions apply.
span between 0 and 1. without image, processing of image is not possible. In this
proposed work, used mobile phone as device to capture
To classify the agricultural products it is found one images with fixed distance, angle and time. The Dataset
of vital step is segmentation. In computer vision applications contains different maturity levels of images such as immature,
before classification it is essential to segment natural matured and over-matured arecanut bunches. It is followed
images. Arecanut is an example of natural images. In Indian by preprocessing where image enhancement is done. Finally
market analysis of Arecanut is an important task.The visual with respect to region of interest, image is segmented.
descriptors of natural images are considered for segmentation
of Arecanut bunches. Figure 6, shows the steps to be followed for segmentation
of Arecanut bunches.
B. Segmentation performance metrics
Normally ground truth images are used to verify the
results of segmentation process. Different metrics are used to
measure the accuracy of segmentation. The most commonly
used statistical measures are Volumetric Overlap Error (VOE)
and Dice Similarity Coefficient (DSC). Considering S as
segmented region using proposed method and G as the ground
truth image. The VOE and DSC are calculated based on their
definitions.

Volumetric Overlap Error is the ratio of the amount


of pixels within the intersection of segmented region and
also the ground truth, and variety of pixels within the union
of segmental region and therefore the ground truth. Good
segmentation should have values close to 0 and increase in
the score shows the discrepancies in the segmented image.
The VOE is computed by applying given Equ. 5.
V OE = ((|S ∩ G|/|S ∪ G|) − 1)100. (5)
Dice Similarity Coefficient (DSC) gives the measure of
the segmentation of pixels of the region of interest. Good
segmentation should have values close to 1 and the score near
to zero shows the discrepancies in the segmented image. DSC
is obtaind by using Equ. 6.
DSC = 2|S ∩ G|/(|S| + |G|). (6)
In this proposed work, VOE and DSC segmentation metrics
are used to measure the accuracy of segmentation.

In proposed work, segmentation of Arecanut bunches


is done through various steps of image processing. The HSV
color model is used for segmentation of bunches of natural
Arecanut images. Methodology section describes the details
of how Arecanut bunches are segmented.

II. METHODOLOGY

The first step of the system architecture(Figure 5) is


Figure 6. Flow chart of proposed method

As shown in Figure 6, to segment an arecanut bunch, first


read an image which is a RGB image. It is followed by the
Figure 5. System Architecture preprocessing step, in which resizeing of image is performed.
The resized Image is converted to HSV image.
image acquisition. In image process, image acquisition is a
process of capturing an image by some source. Typically One of the main steps in image processing is to extract
hardware is used as source for capturing an image. It is needful features to segment an image. In detection of maturity
one of the fundamental task in image processing because level of Arecanut bunches before harvesting Arecanut bunches

39

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 26,2020 at 01:38:10 UTC from IEEE Xplore. Restrictions apply.
Image1
is to be segmented. Segmentation is a process of splitting an
image with respect to common properties. In this proposed
work, segmentation of arecanut bunches is performed by using
only saturation channel of HSV image. So, after converting
RGB to HSV image extract saturation image from HSV image.

To segment arecanut bunch from a saturation image


set the threshold and convert image to binary image. The Image2
resulted binary image consisting of unnecessary information.
To remove unnecessary information and filling gaps in an
image, morphological operations are used.

Morphological is a set of mathematical operations,


which is applied to input image and to produce output image
of same size by considering structuring element. Erosion
and Closing are the two important morphological operations. Image3
Object boundaries pixels are removed by applying erosion
operation. Erosion is performed by using disc as structuring
element. After applying erosion it is followed by closing
operation. Closing operation is used to fill the gaps in
an image. Considering disc as structuring element closing
operation is done by applying two operations in sequence;
dilution is followed by erosion. Then the resulted image
converted to original RGB image. Image4

III. RESULTS AND DISCUSSIONS

To put across our study, images are captured in-field at


different levels (unripe, ripe and overripe) of maturity of
arecanut bunches, because there are no dataset available for
arecanut bunches. In this proposed work, considering four (a) (b) (c)
images from dataset, the results of segmentation is discussed Figure 8. Segmentation of unripe, ripe, overripe and premature arecanut
below. Figure 7(a) shows the input image is RBG image, is bunch.(a) Input image (b) Segmented image (c)Ground truth image
converted to HSV image (Figure 7(b). The saturation channel
of HSV image is show in Figure 7(c), which is used to segment
Arecanut bunch. (Figure 8(b)) properly compare to ground truth image (Figure
8(c)). The value of VOE and DSC in Table 1 for Image4 shows
low performance, because input image contains more waste
inflorescences. Experiments were conducted on 200 images,
which includes different ripeness level of arecanut bunches.
The proposed segmentation method gives mean value of VOE
and DSC is -11.9380 and 0.9007 respectively. Hence, shows
that proposed technique is effective and simple to segment
(a) (b) (c) arecanut bunches from given image.
Figure 7. Process to extract saturation channel.(a) Input image(RGB image) TABLE 1. E VALUATION OF SEGMENTATION USING PERFORMANCE
(b) HSV image (c)Saturation image METRICS

Figure 8(a), shows input image of unripe (Image1), Input Images VOE DSC
ripe (Image2), overripe (Image3) and premature (Image4)
Image1 -13.9041 0.9253
Arecanut bunches. After applying proposed segmentation
method result is obtained as shown in Figure 8(b). To Image2 -14.7773 0.9202
compute performance of segmentation obtained result image Image3 -16.2947 0.9113
is compared with Ground truth image (Figure 8(c)).
Image4 -62.1387 0.5493

The computed value of VOE and DSC shown in Table 1, for


un-matured, matured, over-matured and premature Arecanut
bunches. As given earlier for better segmentation results, the
values of VOE close to 0 and DSC close to 1. Figure 8, for Im-
age4 it shows that input image (Figure 8(a)) is not segmented

40

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 26,2020 at 01:38:10 UTC from IEEE Xplore. Restrictions apply.
IV. CONCLUSION

In this paper, a segmentation method using HSV color


model was presented. Experiments were conducted on two
hundred Arecanut bunch images, which incorporate different
maturity levels. Experimental results show that, the projected
methodology segments Arecanut bunches from an associate
input image with the accuracy of 85% to 90%. The segmenta-
tion performance metrics VOE and DSC are used to measure
accuracy of obtained results. Ground truth images are used
to compare with the obtained results. The proposed technique
may not segment arecanut bunches properly once a picture
is captured in poor condition and additionally if a picture
contains more waste inflorescences(male flowers) in arecanut
bunch.

REFERENCES

[1] Anuja Bhargava and Atul Bansal. Fruits and vegetables quality evalua-
tion using computer vision: A review, Journal of King Saud University
Computer and Information Sciences, 2018.
[2] Van Huy Pham and Byung Ryong Lee. An image segmenta-
tion approach for fruit defect detection using K-means cluster-
ing and graph-based algorithm. Vietnam Journal of Computer Sci-
ence. Publication-Springer Berlin Heldelberg Volume 2,Issue 1,pp 25-
33,2015.doi:https:/doi.org/10.1007/s40595-014-0028-3.
[3] Ajit Danti and Suresha. ”Segmentation and Classification of Raw
Arecanuts Based on Three Sigma Control Limits.” Elsevier, Procedia
Technology 4 (2012): 215-219.
[4] Dah-Jye Lee, James K. Archibald and Guangming Xiong. Rapid color
grading for fruit quality evaluation using direct color mapping. IEEE
transactions on automation science and engineering. Volume 8, Number
2,2011.
[5] Stephen Nuske, Supreeth Achar, Terry Bates, Srinivasa Narasimhan
and Sanjiv Singh.” Yield Estimation in Vineyards by Visual Grape
Detection” . International Journal Of Agriculture and Biology.
[6] Garrett M. Johnson, Xioyan Song, Ethan D. Montag, Mark D.
Fairchild.Derivation of a Color Space for Image Color Difference
Measurement. Wiley Periodicals, Inc.; Volume 35, Number 6, December
2010.
[7] Jose M. Chaves-Gonzlez, Miguel A. Vega-Rodrguez, Juan A. Gmez-
Pulido,Juan M. Snchez-Prez.” Detecting skin in face recognition sys-
tems: A color spaces study”. Digital Signal Processing 20 (2010)
806823,publication-Elsevier.
[8] D. Stajnko, J. Rakun and M. Blanke. Modelling Apple Fruit Yield Using
Image Analysis for Fruit Color, Shape and Texture, Europ.J.Hort.Sci.,
74 (6). S. 260267, 2009, ISSN 1611-4426. Verlag Eugen Ulmer KG,
Stuttgart.
[9] Success story, Areca referral laboratory at UAHS(University of Agri-
culture and Horticulture Science), 2017, Shivamogga.

41

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 26,2020 at 01:38:10 UTC from IEEE Xplore. Restrictions apply.

You might also like