Document 13135761

advertisement
2011 International Conference on Information Communication and Management
IPCSIT vol.16 (2011) © (2011) IACSIT Press, Singapore
Anti-housefly
Chomtip Pornpanomchai, Kasidis Nukornnavarat and Thanet Verojporn+
Faculty of Information and Communication Technology, Mahidol University
Rama 6 Road, Rajchatawee, Bangkok 10400, Thailand
Abstract. The objective of this system is to develop a computer system which can detect and chase
houseflies by using non-toxic chemical substances. The system is called “Anti-housefly”, which lures the
houseflies by using fresh squids. The system starts by taking housefly video frames. After that it uses the
image processing method to detect the houseflies. Finally, the system sends the signal to a high-power
speaker to chase the houseflies. The experiment was conducted on 100 video frames, with 954 houseflies.
The system precision rates for detecting and chasing houseflies were 83.23 percent and 69.18 percent,
respectively.
Keywords: Pest insect, Pest control, Housefly, Image processing.
1. Introduction
Thailand is a hot and humid country in Southeast Asia. There are various pest insects in every part of
Thailand. One of the most dangerous pest insects is a housefly. A housefly (Musca domestica L.) is a small
insect of which the size is around 7-9 millimeters. The houseflies not only carry a myriad of diseases to
people but also damage our daily food products. The houseflies contaminate germs in our drinking water and
food products. The vectors of diseases carried by the houseflies are, for instance: 1) cholera (caused by
Vibrio cholera), 2) typhoid (caused by salmonella typhi), 3) Staphylococcal food poisoning (caused by
Stephylococcus aureus) and 4) Shigelosis (caused by Shigella sp.) [1].
People used a lot of toxic chemical substances to protect themselves and their food products from the
houseflies. Some toxic chemical substances to control houseflies are: dichlorodiphenyltrichloroethane (DDT)
and Z-9-tricosene [2]. The toxic chemical substances damage not only animal food chains but also our good
environment. Therefore, some people try to avoid using toxic substances to control houseflies. Hence, the
objective of this research is to build a computer system which can detect and chase the houseflies without
using any toxic chemical substance. The system will use a webcam to take housefly video stream and use a
high-power speaker to generate both the sound and wind to chase the houseflies. Moreover, the system will
apply the image processing technique to detect and send the signal to chase the houseflies.
2. Literature Reviews
Many scientists try to apply various non-toxic technologies or green technologies to build a pest insect
control system. The applicable techniques used to detect the pest insects and alert people are briefly
described below.
2.1. Electronic Noses Technique
An electronic nose is a smart instrument that is designed to detect and discriminate among complex
odors. The arrays of sensors are treated with a variety of odor-sensitive biological or chemical materials.
+
Corresponding author. Tel.: +662-3544333; fax: +662-3547333.
E-mail address: itcpp@mahidol.ac.th.
102
Many researchers tried to use many materials to construct electronic noses such as metal oxide,
semiconductors, DNA, bacterial protein, enzymes and polymers [3]-[4]. Meanwhile, they used electronic
noses to smell pest insects such as stink bugs in cotton, Weevil in rice, etc. The smelled insect information
will alert concerned persons to handle the insect [5]-[8].
2.2. Acoustic-Based Technique
Sometimes it is very difficult to see the body of pest insects, because they live inside our food product.
One applicable technique is to record pest-insect-movement sound and use acoustic signal processing to
identify insects. An acoustic insect identification system can be divided into three major components. The
first component is to record insect-movement sound. The second component is to extract sound features from
the sound-recording, and the last component is to recognize insect sound. The acoustic-based technique is
not applicable to identify dead insects, which cause contamination inside the food product [9]-[11].
2.3. Image Processing Technique
An image processing method is applied by using a standard camera or video recorder, a personal
computer and some image processing techniques to detect the insect pests. All hardware devices and
software parts are reliable and affordable for most people. The weak point of this technique is that it can
detect pest insects only on an external surface of the food product. It cannot detect the insect pests inside the
food product because it cannot get the image of an insect that moves inside the food product [12]-[15].
Based on the green technology presented above, this research applies the image processing method to
detect and chase the houseflies because this technique is easy and inexpensive for most people. All the
methods applied in this system will be presented in the next section. Finally, the experimental results will be
explained and conclusion made.
3. Methodology
In this section, the system conceptual diagram is presented in the first part. After that, the system
structure chart is presented in details. Finally, the graphic user interface (GUI) of the system is illustrated.
3.1. System Conceptual Diagram
The system starts with using a webcam to record housefly video stream. After that, a user can capture a
housefly video frame from a taken video stream. Then the Anti-housefly system applies the image
processing technique to detect houseflies. Finally, the anti-housefly system sends the signal to the highpower speaker, which produces both the sound and wind to chase the houseflies, as shown in Fig 1.
Fig. 1. System conceptual diagram.
Fig. 2. System structure chart.
3.2. System Structure Chart
Based on the previous section, the system structure chart converted from the system conceptual diagram
is shown in Fig 2. The system structure chart consists of four main components, namely: 1) image
acquisition, 2) image preprocessing, 3) housefly detection, and 4) housefly chasing. Each component has the
following details.
103
3.2.1 Image Acquisition
A user puts fresh squids to lure houseflies. After that, the user uses a webcam to take the squids and
houseflies video stream. Then the user transforms a video stream into a video frame image. Finally, the user
sends a housefly video frame to be processed in the image preprocessing component.
3.2.2 Image Preprocessing
The image preprocessing component consists of five subcomponents, namely: 1) gray-scale conversion,
2) binarization, 3) image differentiation, 4) image cropping, and 5) image resizing. Each subcomponent has
the following details.
•
Gray-Scale Conversion
This subcomponent changes the squids and houseflies RGB image to a gray-scale level image by
applying equation 1. The RGB color picture is converted to a gray-scale picture, as shown in Fig 3(a)-(b).
G = 0.299*R + 0.587*G + 0.114*B
Where G = gray-scale, R = red, G = green and B= blue.
Fig. 3. Image preprocessing sample pictures.
(1)
Fig. 4. Cropping housefly image and its five features.
•
Binarization
This subcomponent defines the threshold value first. After that the threshold value is used to convert a
gray-scale image into a binary image. The method to convert a grayscale image to a binary image is to
compare every pixel’s color value with the threshold value. If the color value of a pixel is less than the
threshold value, then convert that pixel to 0 or white color, otherwise convert that pixel to 1 or black color.
Fig 3 (b) and (c) show the grayscale and black-and-white picture, respectively.
•
Image Differentiation
This subcomponent stores a beginning image, which consists of the fresh squids without any housefly.
After that, the anti-housefly system compares beginning image and a considered image, which consists of the
fresh squids and some houseflies. The different between the beginning image and the considered image
shows the position of the houseflies in the considered image.
•
Image Cropping
Based on the position of the houseflies in a considered image in the previous section, this subcomponent
draws a rectangle around the housefly body. This process is called “image cropping”. This subcomponent
crops a rectangle round the white pixel area of, which the size is around 150 – 1200 square pixels. The
housefly body size is around 150 – 1200 square-pixels based on the system experiment observation. The
housefly cropping image is shown in Fig 3(d).
•
Image Resizing
Normally, the housefly input images have a variety of sizes, which can affect the housefly detection
result. The anti-housefly system adjusts a housefly image with the width x height equal to 50 X 50 pixels.
3.2.3 Housefly Detection
The housefly detection component applies a feature extraction technique to extract housefly features from a
housefly image. Then the system uses a pattern matching technique to detect a housefly. The feature
extraction and pattern matching have the following details.
104
•
Feature Extraction
The feature extraction subcomponent divides a cropping housefly image into five areas, namely: 1) area
of black pixel in the top-left corner, 2) area of black pixel in the top-right corner, 3) area of black pixel in the
bottom-left corner, 4) area of black pixel in the bottom-right corner, and 5) area of white pixel in the center.
All five features are shown in Fig 4.
•
Pattern Matching
The pattern matching subcomponent applies the Euclidean distance method to compare five-feature
value between unknown cropping image and the housefly image in the anti-housefly system database. If the
Euclidean distance value is less than the threshold value, an unknown cropping image is considered a
housefly. The Euclidean distance value is calculated by using the equation 2.
ED =
n
2
∑ (X - Y )
i i
i =1
(2)
Where ED is the Euclidean distance value, n is the number of features, Xi is a value of feature i in the
system database, Yi is a value of feature i of an unknown image.
3.2.4 Housefly Chasing
After the system detects some houseflies in the considered image, the system will send the signal to a
high-power speaker for chasing the houseflies. The high-power speaker can generate both the sound and
wind to scare the houseflies and chase them away, as shown in Fig 5(a)-(b).
Fig. 5. (a) houseflies on squids image, (b) chasing houseflies image. Fig. 6. System graphic user interface.
3.3. System Graphic User Interface
The anti-housefly system is implemented by using MATLAB to develop a computer program based on
the Windows operating system. The system graphic user interface consists of the following components: 1)
two image boxes, 2) two text boxes, and 3) five command buttons, as shown in Fig 6.
two image boxes have the following details:
• Video display box – to play squids with houseflies video stream (label number 1).
• Preprocessing image box - to show preprocessing image (label number 2).
• The two text boxes have the following details:
• Setup fly text box – for setting the number of houseflies in the video frame, which allows the antihousefly system to chase them (label number 3).
• Counting fly text box – for displaying number of counting houseflies in the video frame (label
number 4).
• The five command buttons have the following details.
• Start button – to start a webcam to capture a video stream (label number 5).
• Stop button – to capture a video stream and transform to a considered image (label number 6).
• Original button – to show a fresh-squid image without any housefly on the preprocessing image box
(label number 7).
• Count Button – to display number of counting houseflies in a considered image (label number 8).
• Capture button – to show the houseflies cropping image on the preprocessing image box (label
number 9).
105
4. Testing and Evaluation
In this part, the system has various conditions in various cases to measure its efficiency and effectiveness.
Therefore the experiment is set up to evaluate the system so that it can be used in the real world.
This part presents experimentation on the anti-housefly system, which is developed and based on the
concept and the design mentioned in the previous section. The experiments were focused on the system’s
usability and effectiveness.
Usability testing was to prove whether the system was capable of performing the proposed functions as
mentioned earlier. The effectiveness test determined the correctness of the system and whether the system
results could be used in real life.
4.1. Usability Testing
The usability testing was conducted through the following steps. The first thing was to use the webcam
to capture a housefly video stream. Then the system captured some considered images from a video stream
and detected the houseflies. Finally, the system chased the detected houseflies away by using both the sound
and wind from a high-power speaker. The system could chase the housefly without any toxic chemical
substance.
4.2. Effectiveness Testing
To measure how well the anti-housefly system could detect and chase the houseflies in every step. The
system was tested by using fresh squids to lure the houseflies. Then the system used a webcam to record
housefly video. After that, the system applied the image processing technique to detect the houseflies.
Finally, the anti-housefly system emitted both the sound and wind to chase the fly.
The experiment was conducted on 100 video frames and the system can detect and chase the housefly in
every video frame. There are 954 houseflies in 100 video frames. The system can detect 794 houseflies and
chase 660 houseflies. The system precision rates for detecting and chasing were 83.23 and 69.18 percent,
respectively. The anti-housefly system database contains more than 1,000 housefly images.
5. Conclusion
The Anti-housefly system has been proved to be usable and effective as described in the testing and
evaluation section. The system has also fulfilled the research objective, which is to develop a computer
software for detecting and chasing a housefly without using any toxic chemical substance.
The anti-housefly system still has various limitations as the following.
•
•
A housefly is a very fast and small insect, so it is very difficult to take a housefly picture.
The objects to lure the houseflies should be clear enough in order to find the difference between the
houseflies and the objects.
• The system cannot detect the group of houseflies, which swarm the food very closely to one another.
• The system cannot chase some houseflies which swarm inside the food or far away from the highpower speaker.
Due to, the anti-housefly system limitations mentioned above, the system needs more time and
manpower to improve the system performance.
6. References
[1] Banjo, A.D., Lawal, O.A. and Adeduji, O.O., Bacteria and fungi isolated from housefly (Musca domestica L.)
larvae, African Journal of Biotechnology, Vol. 4(8), pp. 780-784, August 2005.
[2] M.E. Hanley, D.W. Dunn, S.R. Abolins and D. Goulson, Evaluation of (Z)-9-tricosene baited targets for control of
the housefly (Musca domestica) in outdorr situations, Journal of Applied Entomology, Vol. 128, pp. 478-482,
August 2004.
[3] R.L. Ewing, H.R. Abdel-Aty-Zohdy and J.R.Morrison, Polymorphic Architecture for an Electronic Nose (eNose),
in Proceeding of International Midwest Symposium on Circuits and Systems, San Juan, Puerto Rico, 6-9 August
2006, pp. 551-554.
106
[4] R.L. Ewing, H.R. Abdel-Aty-Zohdy and J.S. Moncrief, Polymorphic Computing Applied to Electronic Nose
Architectures, in Proceeding of International Midwest Symposium on Circuits and Systems, Oklahoma, USA, 4-7
August 2002, pp. II-525-II528.
[5] W.G. Henderson, Ahmad K., Young J.H., Jeremy K.G. and Davud C.D., Detecting stink bugs/damage in cotton
utilizing a portable electronic nose, Journal of Computers and Electronics in Agriculture, Vol. 70, pp. 157-162,
January 2010.
[6] Y.B. Lan, Xian Z.Z., John K.W., Juan L, Ron L. and W.C. Hoffmann, Identification of Stink Bugs Using an
Electronic Nose, Journal of Bionic Engineering Supplement. Vol. 5, pp. 172-180, September 2008.
[7] J. Hu, Application of PCA Method on Pest Information Detection of Electronic Nose, in Proceeding of
International Conference on Information Acquisition, Veihai, China, 20-23 August 2006, pp. 1465-1468.
[8] S.Ye and J. Hu, Insect Herbivory Information Detection by Pricipal Component Analysis on Electronic Nose
System, in Proceeding of International Conference on Neural Networks and Brain, Beijing, China, 13-15 October,
2005, pp. 401-404.
[9] R.W. Mankin, M.T. Smith, J.M. Tropp, E.B. Atkinson and D.Y. Jong, Detection of Anoplophora glabripennis
(Coleoptera: Cerambycidae) Larvae in Different Host Trees and Tissues by Automated Analyses of Sound-Impulse
Frequency and Temporal Patterns, Journal of Economic Entomology, Vol. 101, pp. 838-849, June 2008.
[10] Z.Leqing and Z. Zhen, Insect sound recognition based on SBC and HMM, in Proceeding of International
Conference on Intelligent Computation Technology and Automation, Shangsha, China, 11-12 May 2010, pp. 544548.
[11] N. Zhang and M. Guo, Recognition of Fruit Fly Wings Vibration Sound Based on HMM, in Proceeding of
International Conference on Information Engineering and Computer Science, Wuhan, China, 25-26 December
2010, pp. 1-4.
[12] Y. Liu, J. Zhang, M. Richards, B. Pham, P. Roe, and A. Clarke, Towards Continuous Surveillance of Fruit Flies
Using Sensor Networks and Machine Vision, in Proceeding of International Conference on Wireless
Communications, Networking and Mobile Computing, Beijing, China, 24-26 September 2009, pp. 1-5.
[13] Chomtip P, Sopit S, Paradorn K, and Tanapol S, Ant Detection and Counting From a Video Frame, in Proceeding
of National Computer Science and Engineering Conference, Bangkok, Thailand, 4-6 November 2009, pp. 293-296.
[14] R. Jianqiang, Algorithm for 3D Reconstruction of Agriculture Field Pests Based on Binocular Stereo Vision, in
Proceeding of World Automation Congress, Kobe, Japan, 19-23 September 2010, pp. 101-105.
[15] L. Zhou, X.Z. Wang, M. Yi, and Z.W. Yu, Application of gray relation analysis in image’s edge detection of pests
in stored grain, in Proceeding of International Symposium on Intelligent Information Application, Shanghai,
China, 21-22 December 2008, pp. 405-407.
107
Download