Académique Documents
Professionnel Documents
Culture Documents
Syndicate Members
Ahmed Usman (F-43014)
Muhammad FarhanAmjad (F-43064)
Muhammad ShabanZafar (F-43060)
SUPERVISED BY
Sir Salman Afghani
ARMY PUBLIC COLLEGE OF MANAGEMENT &
SCIENCES
Sick Chicken Behavior Detection System SCBDS
Approval Certificate
It is certified that we have read this report, submitted by the following:
To our judgment the report is well prepared and meets all the standards of
acceptance for the award of Bachelors of Science Degree in Software Engineering
- BS (SE)
Project Supervisor:
Examiner:
Acknowledgement
We are highly grateful to our HOD Dr. Imran Babar, Computer Science Department, for
providing this opportunity to carry out the final year Project at Army public College of
management and sciences (APCOMS), Rawalpindi.
I would like to expresses my gratitude to other faculty members of Computer Science &
Engineering department of APCOMS, Rawalpindi for providing academic inputs, guidance &
encouragement.
I would like to express a deep sense of gratitude and thanks to Dr. Salman Afghani, for wise
counsel and able guidance.
Sick Chicken Behavior Detection System SCBDS
Abstract
Poultry business as we all know is one of the most profitable businesses all over the world. The
reason being, the demand by big concerns such as KFC, McDonalds, Pizza Hut and many other
food chains is extremely high. Secondly, the growth rate of today’s broiler chicken is almost as
high as that of a vegetable such as potatoes (broiling chicken grows very fast). These two factors
contribute heavily to the huge returns and attractive profits. There is always a con to a pro for
any business and thus in this business, the con is the uncertainty factor which contributes
adversely to the perceived profits. Uncertainty in terms of various diseases such as bird flu and
many other viruses are extremely effective in destroying whole poultry farms in a matter of
hours.
In our project we are addressing this very dilemma of uncertainty caused by poultry-related viral
attacks. To achieve this goal we shall IN SHA ALLAH develop a DIP (MV) based Sick Chicken
Behavior Detection System.
Sick Chicken Behavior Detection System SCBDS
Table of Contents
Acknowledgement ........................................................................................................................................ 3
Abstract ......................................................................................................................................................... 4
1. Introduction ......................................................................................................................................... 10
1.1. Problem Statement ...................................................................................................................... 11
1.2. Purpose........................................................................................................................................ 11
1.3. Objectives ................................................................................................................................... 12
2. Literature Review................................................................................................................................ 14
2.1. Previous Systems for Poultry Farms ........................................................................................... 15
2.2. Existing Systems ......................................................................................................................... 15
2.2.1. Canadian Notifiable Avian Influenza Surveillance System (CanNAISS) .......................... 15
2.2.2. Bio Security Plans ............................................................................................................... 16
2.2.3. The Eye NAMIC System .................................................................................................... 17
2.3. Why Not Existing Systems? ....................................................................................................... 18
2.4. Technology Used ........................................................................................................................ 18
2.5. Baseline Technologies ................................................................................................................ 18
2.6. Conclusion .................................................................................................................................. 21
3. System Analysis .................................................................................................................................. 23
3.1. Functional Requirements ............................................................................................................ 23
3.2. Non-Functional Requirements .................................................................................................... 23
3.3. Intended Audience ...................................................................................................................... 24
3.4. Purpose of this Document ........................................................................................................... 25
3.5. Goal of Project ............................................................................................................................ 25
3.6. Stakeholders ................................................................................................................................ 26
4. System Design .................................................................................................................................... 28
4.1. Design Architecture .................................................................................................................... 28
4.2. Project Flow ................................................................................................................................ 29
4.3. Activity Diagram ........................................................................................................................ 30
4.4. Detailed Use Case ....................................................................................................................... 31
Sick Chicken Behavior Detection System SCBDS
Table of Figures
Chapter # 1
Introduction
Sick Chicken Behavior Detection System SCBDS
1. Introduction
Although poultry is one of the highly profitable businesses in the world, yet due to uncertainty
induced by pandemic viral diseases such as bird flu, unpredictable heavy losses can destroy the
business.
In our project we are addressing this very dilemma of uncertainty caused by poultry related virus
attacks. To achieve this goal we will be developing a DIP (MV) based Early Stage Viral Attack
Detection and Warning System.
Poultry is that the biggest revenue generating business round the world however its risky once it
involves the microorganism attack state of affairs. it's not possible for the individual to come to
life nightly to stay an eye fixed on the chickens as we all know that the virus invariably attacks at
night time as a result of the biological resistance system of chickens is all the way down to
minimum throughout sleep time and this is often the purpose wherever things fail.
Early warning and speedy alert for Chicken malady will play a crucial role within the production
of healthy chickens. today Advance Warning System for Poultry Farms
against microorganism attack is an important demand for the poultry farmers in order
that speedy detection and response to a suspicious state of affairs is feasible.
Early detection is principally supported reactive police work. On a national and inter-national
level, many police work systems of chicken diseases square measure operational. All regular
activities with the aim of early detection and management of chicken diseases has importance to
national economies, food security and trade.
All the opposite systems that has been projected or designed square measure for the advance
safety measures in order that a scourge doesn't attack, However what if a chicken gets
infected however will we have a tendency to management the transfer of virus from one chicken
to other? This is often a crucial issue however sadly no such system has been designed that
may determine the infected chicken in order that we are able to inoculate it out from others.
Introduction Page 10
Sick Chicken Behavior Detection System SCBDS
1.2. Purpose
The purpose of this project is to style and develop system which will be watching health and care
section of chickens it'll be capable to spot the infected chicken at the terribly initial stage through
Image process techniques. This method is going to be able to determine the infected chicken at
the terribly initial stage so square measure able to inoculate that chicken and therefore others are
saved from the virus
Introduction Page 11
Sick Chicken Behavior Detection System SCBDS
1.3. Objectives
The system can improve the poultry growth by detective work the infected chicken at
early stage. specifically, our project can focus on: Frame Extraction, distinctive the
Chicken and distinctive the infected chicken.
Most of the chickens die once the illness enters the poultry farms it's transferred from one
chicken to alternative terribly very less time, In chickens, in the dead of night time the
metabolism is at its lowest level which is that the time once virus
is more transferred therefore our system are operating 24/7 in order that it will notice the
infected chicken even in the dead of night.
Sick Chicken Behavior Detection System SCBDS
Chapter # 2
Literature Review
Sick Chicken Behavior Detection System SCBDS
2. Literature Review
Numerous applications have been built in the agriculture sector using technology like
Machine Vision such as land-based and aerial-based remote sensing for various purposes
whether it is precision farming, safety detection or process automation etc. It is due to the
fact that Machine Vision Systems not only take into account the graphical details but also
address the related numerical attributes.
In the poultry farming industry, control of environmental parameters directly affects yield.
The ambient humidity is one factor which requires control
for effective growth. Sensors currently available cannot withstand the harsh environment of
the poultry house. A humidity sensor based on the psychometric effect, temperature sensors
already in use in poultry
houses, and digital processing provide an industry standard output while withstanding harsh
conditions. The sensor successfully automates the psychometric process, measures the
difference between the wet and
dry bulb temperatures and digitizes the difference to produce a voltage output proportional to
percent relative humidity.
The objective of this study work is to develop a low cost semi-automated vaccination
machine based on chick morphology parameters. Chick morphology was carried out on
locally vaccinating centre in Khartoum North. The mean value of chick weight, chick height
and neck height were equal to 22.917 ±2.24g, 11.542 ± 1.248 cm, 4.1208 ± 0.836 cm,
respectively. The
proposed machine has been designed and developed successfully.
The developed machine consists of an injection, stainless steel
base, stainless steel cover, Teflon plate, switch, air compressor, mounted double acting
cylinder, solenoid valve 5/2, Filter Regulator Lubricator (FRL), solenoid limit switch and
connections. The developed machine had overall dimensions of 500 mm length, 164 mm
height, 350 mm and a total weight of 22 kg. Furthermore, the developed machine has been
successfully tested and evaluated. The mean time for vaccinating one chick with the semi-
automated machine and the manual commercial one were equal to 1.8771 ± 0.591 and 3.760
± 1.552 second, respectively. The estimated production of the machine is 2000 chick/hour
that saves approximately half time with no skills to the manual commercial one. The unit
total cost is about 500 US Dollars excluding the air compressor
Early detection in extremely settled region of the globe was done manually (based on visual
cues, Human worker determine sick chickens among an oversized healthy cluster. Globally,
such many police investigation systems of chicken diseases were used and
in several underneath developed countries are operational even these days.
CANNAISS is intended to fulfill craniate respiratory disease tips from the planet Organization
for Animal Health (OIE) and trade needs from the eu Union. it's designed to find the presence
of craniate respiratory disease in live Canadian poultry, and enhances Canada’s police
investigation efforts. CANNAISS provides data regarding craniaterespiratory disease viruses in
Canada’s domestic poultry flocks in order that Canadian poultry producers and
processors will do business internationally.
There are many surveillance activities. Canada currently monitors for avian influenza through:
Isolation.
Traffic Control.
Sanitation.
Eye-NAMIC permits the behavior of a bunch of broilers to be followed from minute to minute.
Clear overviews show the migration and activity of the animals. Abnormal behavior is
visible instantly, enabling to you to retort in time before any abnormalities will have an effect
on the welfare or health of the animals. This info is saved and might be used subsequently for
analysis of the climate state of affairs, as an example. you have got the
knowledge of optimum animal performance and no unpleasant surprises at the top of
a finished cycle.
Digital image processing is the use of computer algorithms to perform image processing on
digital images. As a subcategory or field of digital signal processing, digital image processing
has many advantages over analog image processing. It allows a much wider range of algorithms
to be applied to the input data and can avoid problems such as the build-up of noise and signal
distortion during processing. Since images are defined over two dimensions (perhaps more)
digital image processing may be modeled in the form of multidimensional systems.
Literature Review Page 18
Sick Chicken Behavior Detection System SCBDS
Machine vision:
Machine vision (MV) is that the technology and ways wont to give imaging-based automatic
examination and analysis for such applications as automatic examination, method management,
and golem steering in business. Machine vision uses image capture and analysis to change tasks
like examination, gauging, and enumeration, additionally to reading barcodes and optical
characters (OCR). whereas human examiners will visually inspect elements to evaluate the
standard of acquisition, machine vision systems use advanced hardware and software system
parts to perform these functions at higher speeds, reliably, and with bigger exactitude.
Pattern recognition:
Pattern recognition could be a branch of machine learning that focuses on the popularity of
patterns and regularities in information, though this can be conjointly thought-about to
be terribly near machine learning at several areas. Pattern recognition systems in several cases is
thought as trained systems they're trained to acknowledge the patterns once learning , Algorithms
for pattern recognition rely upon the sort of label output, on whether or not learning
is supervised or unsupervised , and on whether or not the rule is applied math or non-statistical in
nature.
2.6. Conclusion
As poultry sector of our country is within the developing part. we want to figure lots during
this sector because it is one amongst the foremost profitable businesses as way as our
economy worries. several of our poultry farms face a large loss once their chickens area
unit attacked by a deadly virus. This virus is transferred from one to the
opposite and therefore most of the chickens area unit attacked later.
Virus may be transmitted directly from chicken to chicken through secretions and BM, and
indirectly through human movement, contaminated feed, water and instrumentation. In light-
weight of the threat and risks related to viruses, raised attention has been drawn to the
continued ought to defend domestic poultry through the effective use of safety measures. Safety
involves maintaining sensible hygiene practices and limiting exposure to external sources of
contamination.
But when casting off these measures one can't one hundred pc assure that the chickens won’t get
infected by the Virus. There remains an opportunity of chickens being attacked and if this
happens however will we tend to stop the transfer of virus from one to other? this is often the
question that must be answered. we want to develop a system to secure the chickens from the
virus or a minimum of to prevent the transfer of contagious virus from one to the
opposite chicken.
This project, at conclusion, will be able to establish the infected chicken at the terribly initial
stage in order that {we can we will we area unit able to} inoculate that retire of all
and therefore others are saved from the virus.
Chapter # 3
System Analysis
Sick Chicken Behavior Detection System SCBDS
3. System Analysis
Extracting Data
The system should be able to extract data from the Video. This step will involve some complex
image processing methodologies and algorithms which will be useful to get the closest results.
These data will be used to decide the situation.
When any abnormal activity is seen the system should immediately take the specified action.
The system should be able to identify the infected chicken on the basis of some specified rules.
Whether or not infected chicken is identified the system should be able to perform the test of
identifying the infected chicken if any again and again after some intervals.
Performance is a major nonfunctional requirement in this system. As the System requires Virus
detection, it should have a very short response time.
Safety Requirements
System safety is very important in every type of project. Regarding to our project, the system
should be switched off with the Operation Manager’s permission. It should have Electricity
backup so that a system can work even if power is disconnected.
Security Requirement
Correctness
Efficiency
Flexibility
The programming must be easy to modify for the future purpose work.
Portability
A client may need to transfer the system from one area to other so the system should be portable
that it can be transferred easily.
K&N’s
KFC
MCDONALD
Private Poultry Farms
Pakistan Poultry Association
Introduction
Requirements
Objectives
Model based mostly chicken recognition algorithmic program are designed to differentiate the
chicken from background (Floor, Feeding Pan, Waste etc.). To modify the detection of a sick
chicken and infected chicken among sizable amount of chickens could be aintimidating task.
Loss in agility
Due to these two disabling the chicken will always be lagging behind and standing off the crowd
whenever a new feeding point is activated. With that; this project is capable to identify the
infected chicken at the very initial stage so that we can inoculate that chicken out of all and thus
others are saved from the virus.
3.6. Stakeholders
Mr. Salman Afghani is the Project Supervisor and Ahmed Usman, Farhan Amjad and Shaban
Zafar are the Technical Team.
Chapter # 4
System Design
Sick Chicken Behavior Detection System SCBDS
4. System Design
Definition
System style is that the method of art of shaping the design, components, modules, interfaces
and information for a system to satisfy nominative needs. One might see because the application
of systems theory of development.
Thus the computer code design of a program or ADP system could be a depiction of the system
that aids within the understanding of however the system can behave. computer
code design is the blueprint for each the system and also the project developing it, process the
work assignments that has to be administered by the planning and implementation groups.
The design is that the primary carrier of a system quality like performance, modifiability and
security, none of which might be achieved while not a unifying field version. design is Associate
in Nursing unit for early analysis to form positive that a style approach can yield an
appropriate system.
FRAME
CAPTURING
BLOB
DETECTOR
HULL
READER
FALLING EDGES
CALCULATOR
EDGE
ORIENTATION
CHICKEN
IDENTIFICATION
Chapter # 5
System Implementation
Sick Chicken Behavior Detection System SCBDS
5. System Implementation
5.1. Tools
Open CV
Visual Studio includes a code editor supporting IntelliSense (the code completion
component) still as code refactoring. The integrated program works each as a source-
level program and a machine-level program. alternative intrinsic tools embrace a forms designer
for building user interface applications, internet designer, category designer, and info schema
designer. It accepts plug-ins that enhance the practicality at virtually each level—including
adding support for source-control systems (like Subversion) and adding new toolsets like editors
and visual designers for domain-specific languages or toolsets for alternative aspects of
the code development lifecycle (like the Team Foundation Server client: Team Explorer).
Visual Studio supports completely different artificial languages and permits the code editor
and program to support nearly any programming language, provided a language-specific service
exists. intrinsic languages embrace C, C++ and C++/CLI (via Visual C++),VB.NET (via Visual
Basic .NET), C# (via Visual C#), and F# (as of Visual Studio 2010). Support
for alternative languages like M, Python, and Ruby among others is accessible via language
services put in singly. It additionally supports XML/XSLT, HTML/XHTML, JavaScript and
CSS. Java (and J#) was supported within the past
Microsoft provides "Community" editions of its Visual Studio at no cost. Commercial versions
of Visual Studio along with select past versions are available for free to students via
Microsoft's Dream Spark program.
Open CV
OpenCV (Open supply laptop Vision Library) is associate open supply laptop vision and
machine learning package library. OpenCV was engineered to supply a standard infrastructure
for laptop vision applications and to accelerate the employment of machine perception within
the industrial merchandise. Being a BSD-licensed product, OpenCV makes it simple for
businesses to utilize and modify the code.
The library has over 2500 optimized algorithms, which incorporates a comprehensive set
of each classic and progressive laptop vision and machine learning algorithms. These
algorithms may be wont to observe and acknowledge faces, determine objects, classify human
actions in videos, track camera movements, track moving objects, extract 3D models of
objects, turn out 3D purpose clouds from stereo cameras, sew pictures along to provide a high
resolution image of a whole scene, realize similar pictures from a picture information, take
away red eyes from pictures taken victimisation flash, follow eye
movements, acknowledge scenery and establish markers to overlay it with increased reality, etc.
OpenCV has over forty seven thousand individuals of user community and calculable variety of
downloads extraordinary seven million. The library is employed extensively
in corporations, analysis teams and by governmental bodies.
OpenCV Applications
OpenCV is being used for a very wide range of applications which include:
OpenCV Functionality
Methodology
6. Methodology
At the terribly initial stage huge journal detector gets the extracted frame. when obtaining the
frame it starts scanning it, sometimes it takes odd variety of pixels that's ninety nine x ninety
nine Pixels or a hundred and one x a hundred and one Pixels. Reason behind taking
odd variety of pixels is that we want to seek out its center that is
definitely potential in associate odd variety matrix, whereas scanning a frame with a grid of
{101|one hundred associated one|a hundred and one|one zero one} x 101pixels once it
receives space|the world|the realm} of its interest or the purposes that fulfill its
conditions it'll store the middle of that area or point in an array.
Once those centers square measure keep in associate degree array the system can compare the
values of these points with threshold, if a condition gets true for a
1 or quite one purpose it'll store that center points
for additional actions whereas feat all alternative points.
38
Figure 7 Big Blob Detector A
In this massive Blob Detector are able to get any object as our space of interest during
a region that isn't the demanded case as a result of we tend to are wanting forward to seek
out and determine the chicken not different objects. thus to beat this downside eight
neighboring purposes or pixels and one center point are going to be taken and this grid
of nine x nine pixels is additional transferred or forwarded to Hull Reader.
Figure 8
39
Actual Loop for generating points(Formula)
40
16 Points Generation
41
42
6.1.1 Big Blob Position Refiner
43
6.2. Auto Hull Reader
After receiving grids of 9x9 pixels, Hull Reader can develop more sixteen points on these
received points. primarily it'll produce a Hull of sixteen points. currently on of these points Hull
Reader can produce spikes. The length of those spikes depends on the position wherever they lie.
44
Figure 10 Pattern
Once these spikes area unit created all the pixels of those spikes area unit scanned by a jump
of five pixels every. On scanning the points 3 points area unit received that area
unit. it'll calculate the values of those points and understand wherever it gets the sharp falling
edges those which can have the values it'll store them and eliminate all those that have very low
values. during this approach orientations are gathered and a box are placed over these
points which can determine that it's a chicken.
45
Figure 11Measurment in Hull Reader
46
6.3. Falling Edges Calculator
47
6.4. Edge Orientation Detection
Edge orientation detection includes a variety of mathematical methods that aim at identifying
points in a digital image at which the image brightness changes sharply or, more formally, has
discontinuities. The points at which image brightness changes sharply are typically organized
into a set of curved line segments termed edges. The same problem of finding discontinuities in
one-dimensional signals is known as step detection and the problem of finding signal
discontinuities over time is known as change detection. Edge detection is a fundamental tool
in image processing, machine vision and computer vision, particularly in the areas of feature
detection and feature extraction .The diagram we are using is described in following Diagrams :
48
The RGB transition values of Edge Orientation Detector .
49
6.4. Future Work
Once the chicken is known the any work would now not be tough, Hardware is
also refined which can embody Shutter, Buzzers, Feeding Pans, Paint gun and strange
attractors. owing to the shortage of your time we tend to couldn’t manage to utterly deploy the
system otherwise when the identification of a chicken,infected chicken was to be known on the
premise of some biological and scientific rules and principles. Once the camera captures sick
chicken system can drop the shutter, generate the alarm and at identical time with the
assistance of a paint gun it'll shoot the sick chicken to form it simple for the person to
ascertain the sick chick.
50
Chapter # 7
Software Testing
Sick Chicken Behavior Detection System SCBDS
7. Software Testing
Test Steps:
1- Open application
4- Click Open.
Test Steps:
1- Open application.
Expected Result: An interface opens and showing the video processing for live video
scanning.
52
Chapter # 8
Conclusion
Sick Chicken Behavior Detection System SCBDS
8. Conclusion
For years poultry farms are operating to avoid wasting their chickens
from microorganism attacks that they need not achieved nevertheless. Hundred thousands of
chickens have died because of microorganism attacks in past few years. World
is wanting forward to the new technology during this field conjointly.
Increased use of digital video and image process technology within the world
has paved the manner in poultry farming to extend the expansion and save the chickens
from microorganism attacks. is also in coming back future it'll get a lot of economical.
Many countries area unit exploitation totally different systems to safe guard their poultry
growth however {they area unit they're} too expensive to introduce In Asian country as we have
a tendency to area unit underneath developed state and most of the poultry farms are of
poor individuals or socio-economic class that cannot afford these high-priced systems for his or
her poultry farms.
Hence to beat this drawback we have a tendency to area unit developing Machine Vision based
mostly Poultry Farm Automation System (SCBDS) to sight the infected chicken at the earliest
stage in order that transfer of virus from one chicken to alternative is also stopped, this
technique shall be inbuilt a really low price budget in order that it will simply be cheap for
the personal poultry farms, SCBDS are facilitate full within the coming back way forward
for Asian country.
Thus during this manner the human is additionally replaced by the machines and therefore
the possibilities of virus transfer are less.
Conclusion Page 54
Chapter # 9
References
Sick Chicken Behavior Detection System SCBDS
9. References
http://www.oie.int/doc/ged/D6184.PDF’
http://animalscience.ucdavis.edu/avian/pfs26.htm
http://www.nd.gov/ndda/program-info/biosecurity/standard-Poultry -biosecurity-plan
http://poultry-equip.com/wp-content/uploads/2014/07/401697212eyenamic-factsheet_gb.pdf
CANNAISS(SYSTEM)
http://www.inspection.gc.a/animals/terrestrial-animals/diseases/surveillance/avian-influenza-
surveillance/eng/1329693810008/1329694298513
BUIJS, S.; KEELING, L.J.; TUYTTENS, F.A.M. Using motivation to feed as a way to assess
the importance of space for broiler chickens. Animal Behaviour, Amsterdam, v.81, n.1, p.145-
151, 2011.
BUIJS, S.; KEELING, L.J.; VANGESTEL, C.; BAERT, J.; VANGEYTE, J.; TUYTTENS,
F.A.M. Resting or hiding? Why broiler chickens stay near walls and how density affects this.
Applied Animal Behavior Science, Amsterdam, v.124, n.3-4, p.97-103, 2010.
http://www.animalhealthaustralia.com.au/programs/biosecurity/biosecurity-planning/poultry-
industry-biosecurity-plans
https://www.business.qld.gov.au/industry/agriculture/animal-management/poultry/housing-and-
production/starting-meat-chicken-farm/poultry-diseases-farm-biosecurity
http://www.cahln-rctlsa.com/uploads/2/7/7/9/2779116/7-scenario_tree_models_-
canadian_notifiable_avian_influenza_..._j.christensen.pdf
http://www.fancom.com/uk/broilers/biometrics/eyenamic
http://poultry-equip.com/wp-content/uploads/2014/07/1401697212_eyenamic-factsheet_gb.pdf
http://en.wikipedia.org/wiki/Microsoft_Visual_Studio
https://www.visualstudio.com/
http://www.sei.cmu.edu/architecture/
http://en.wikipedia.org/wiki/Systems_design
References Page 56
Sick Chicken Behavior Detection System SCBDS
http://opencv.org/
https://developer.nvidia.com/opencv
https://www.google.com.pk/url?6&cad=rja&uact=8&sqi=2&ved
0CDcQFjAF&url=http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FMachine_vision&ei=dQVtV
ZX_MoboUpv0gPAG&usg=AFQjCNEf0XhAxqe7gssgeQWr5B-
LitQwmg&bvm=bv.94911696,bs.1,d.d2
References Page 57