Professional Documents
Culture Documents
Algorithm
Abstract. Fish detection and identi cation are important steps towards
monitoring sh behavior. The importance of such monitoring step comes
from the need for better understanding of the sh ecology and issuing
conservative actions for keeping the safety of this vital food resource.
The recent advances in machine learning approaches allow many appli-
cations to easily analyze and detect a number of sh species. The main
competence between these approaches is based on two main detection
parameters: the time and the accuracy measurements. Therefore, this
paper proposes a sh detection approach based on BAT optimization
algorithm (BA). This approach aims to reduce the classi cation time
within the sh detection process. The performance of this system was
evaluated by a number of well-known machine learning classi ers, KNN,
ANN, and SVM. The approach was tested with 151 images to detect the
Nile Tilapia sh species and the results showed that k-NN can achieve
high accuracy 90%, with feature reduction ratio close to 61% along with
a noticeable decrease in the classi cation time.
1 Introduction
A great number of sh species over the world su ers from pollution and over-shing
practices. Moreover, the human construction through rivers such as dams that
negatively a ects the number of shes and their diet sources. Monitoring of any
diversity change in the quantities of any sh species is important to ensure the
sustainability of one of the protein sources for the world populations. Usu-ally the
common methods used by marine biologists are human observations,
II
caught and counted using casting nets, or using sonars [1]. Recently, computer
vision [13, 15, 17, 18], relying on the application of machine learning techniques
[2] [3], are used to detect, count, classify and study sh behavior of di erent sh
species.
Several studies have considered the sh detection and species recognition in
water, such as the work in [2] where the authors used an underwater camera to
detect swimming sh in an open sea. The proposed model is based on inter-class
similarities to construct a hierarchical tree classi cation. The trajectory voting is
used as a second phase to eliminate the unknown classes or less con dent
decisions. Although the model can classify 15 species of sh with a hight accuracy
that reached 97.5% using the at Support Vector Machine (SVM) classi er, but the
model may reject new sh species which are not been sampled within the model.
These rejected classes may require further analysis.
Since the shape extraction is important for species recognition, a number
of approaches use it as reference for sh classi cation. Examples include using
the Principal Component Analysis (PCA) to detect sh through the shape
knowl-edge [3]. The Haar-classi er is trained to locating snout and tail of sh in
the underwater image sequences. The detection of both snout and tail points
are used as references for constructing the shape model of the sh. to e ciently
cap-ture the main variations of a training set, the PCA statistical procedure is
used to remove poor contrast boundaries, background clutter and occlusions
caused by overlapping with neighboring sh.
Accurate extraction of the shape is important for sh classi cation. However,
the shape extraction may fail if it relies on outer boundary (edge) detection [4]
as shape cannot be detected correctly if the scene is unclear or contains a
large swarm of sh [5]. One of the solution is to use color information along
with the shape as the work reported in [6]. This work used the neural networks
to detect stationary species in deep sea.
To evaluate which feature extraction technique could be e cient for the clas-si
cation accuracy, a comparison in [7] was conducted between a Scale Invariant
Feature Transform (SIFT), a Speed Up Robust Features (SURF) algorithms. The
evaluation results showed the superiority of the Support Vector Machine (SVM)
over Arti cial Neural Networks (ANN) and k-Nearest Neighbor (k-NN) algorithms
when they applied to the SURF-based and SIFT-based features. The a SVM
classi er using the the linear function achieved at 94.44% using the SURF-based
features and 69.57% using the SIFT-based features.
The rest of this paper is organized as follows: Section (2) gives an
overview about the BAT algorithm and Section (3) presents the proposed
system. The results and the discussion are reported in Section (4). The paper
is concluded in Section (5).
The bat bird has a distinguish strategy for tracking its preys and avoiding ob-
stacles. This aying animal uses the echolocation process for navigation and it
III
has the ability to di erentiate between the sending signals and their re ections.
The re ected signals is used for measuring the distance between the bat and
the prey. Yang [8] has studied the bat behavior and proposed a new meta-
heuristic optimization algorithm known as The Bat Algorithm. This algorithm
can be modeled using the following three general rules [9]:
{ The bats use echolocation sensing to measure the distance and they can
easily distinguish between the prey and obstacles.
{ Each bat x minimum frequency, varying wavelength, and loudness through
their random searching for a prey. Based on the proximity of the prey,
each bat can adjust its frequency of their emitted pulses.
{ The variation of loudness should be limited through a constant range of
values
1. Initialize the bat positions Xi and Velocity Vi and de ne the pulse frequency Fi, the
pulse emission rate ri and the loudness Ai per bat.
2. While stopping criteria are not met
a For every bat
i Generate a new solution by calculating the updated frequency, velocity and
position.
ii If rand > ri then
{ Select a solution among the best solutions set and perform a random
local search around it.
iii End If
iv Generate a new random solution
v If rand < Ai and F (Xi) < F (X )
{ Accept the new solution
{ Increase ri and decrease Ai
vi End If
vii Reselect the best solution X
b End For
3. End While
end
Algorithm 1: Bat Algorithm (BAT)
IV
The proposed approach can be divided into two main procedures: the training
procedure and the testing procedure. Each of these procedures consists from
a number of phases as illustrated in Figure 1. A description of these phases
are give below.
where Ixx is the second order Gaussian smoothed image derivatives which
detects signal changes in two orthogonal directions.
The SURF algorithm determines for each feature a 44 sub-window to give
a description for each feature as weighted wavelet coe cients after calculating
the Haar wavelet response in horizontal and vertical directions. As a result,
V
n
V = fxI ; yI gI =1 (2)
where xi represents the features of interest and y i describes the class label
(Tilapia, or Non-Tilapia Class).
The produced features vector was then given as an input to the optimiza-
tion phase at which the BA was applied to reduce the number of features.
Such process aims to minimize the classi cation time while keep the classi
cation accuracy at high rate. Table 1 shows the values adjust for the BA within
the optimization phase. The output of the optimization phase, i.e. the reduced
fea-ture vector, was then given to a number of machine learning classi ers to
test the classi cation accuracy and to be build the model.
Parameter Value(s)
No. of Bats 5
Num. of Itterations 100
Loudness (A) 0.5
Pulse rate (r) 0.5
Frequency minimum (Qmin) 0
Frequency maximum (Qmax) 2
Problem Dimension SURF features vector = 64 dimensions
Search Domain [0, 1]
0
In the testing procedure, a set of unlabeled images n was used. This set
went through the same pre-processing and feature extraction phases which
were done in the training procedure. As illustrated in Figure (1), before the
classi cation phase of the testing procedure, the produced features vector was
passed to a logical gate function so this vector is ltered by the reduced vector
obtained in the optimization phase done in the training procedure. This
process will avoid running the BAT algorithm again in the testing procedure.
It is worth noting that, the BAT algorithm used for feature selection was
considered the following points: (1) The solution space here represents all possi-
ble solutions of features and hence the bat positions represent a binary selection
of feature sets, (2) Each feature is considered as an individual dimension with
uniform distribution in range of [0; 1]. To decide if a feature will be selected or not,
its position value will be threshold with a constant threshold ("). (3) The selection
parameter (") is very e ective in the performance of the bat algorithm as it controls
the diversity of the solution obtained at a given iteration. So, in this work we made
adaptive tuning for the selection parameter (") through-out iteration numbers. In
the beginning of the iterations, there was a need for
VI
large diversity, hence a large value of (") was adjusted for more exploration and
discovering through the search space for an optimal solution. At the end of op-
timization approach, the bats should reach near the optimal solution, therefore, a
less diversity is required (intensi cation the search near this solution), so a
minimum value for (") was set. The initial value for the (") was set as half of the
search range, to be inside the search space and it is only an initial value. The
parameter (") is calculated in each iteration using equation (3).
where "0 is the initial value for ", t is the iteration number, and N gen is the
maximum number of iterations for the BAT optimization.
The proposed sh classi cation approach was implemented using the MATLAB
simulation tool. A self-collected database for sh was used. This is because
there is no well-known data set for Nile Tilapia sh. The database was
collected through capturing a number of sh photos with di erent
transformations (scale change, rotation, illumination, image blur, viewpoint
change, and compression). The dataset consists of 96 images of Tilapia sh
and 55 images of Non-Tilapia sh, Figure 2 shows samples of these images.
To evaluate that the aim of our proposed system, achieving high accuracy
rate using the least features optimized by the BAT algorithm, two scenarios
were designed. The rst scenario was to the classi cation rate before and after
applying the BA to the feature extracted by the SURF algorithm. Table 2 sum-
marizes the reduction ratio obtained by running di erent experiments using BA
and without using BA. So, in the second scenarios, we will see if a small set
(op-timal feature set) of these features may be enough to indicate the classi
cation results within shorten time.
The secondly scenario was to test the compatibility of the approach with a
number of classi ers such as the Arti cial Neural Network (ANN), the k-Nearest
Neighbors(k-NN), and the Support Vector Machine that based on the radial basis
function kernel (SVM-rbf). The ratio between the number of correct and false
0
matches among the reference images and the set of n has been used
VII
times than the others, this time is usually consumed through the
establishment procedure of the neural network structure. Another important
nding is that both the ANN and SVM reached quickly to a hyperplane decision
for some experiments.
The current paper introduced an approach for sh detection and identi cation.
The approach made use of the BAT algorithm to reduce the number of
features extracted using the SURF algorithm. These features were used to
classify the Nile Tilapia species (the used data set). The experimental results
showed when the BAT algorithm has improved the classi cation rate (K-NN,
ANN, and SVM were used) while at the same time classi cation time was
minimized. It was proved that the k-NN is the best one among (ANN, and
SVM) in terms of classi cation time and accuracy. The other classi ers (ANN,
and SVM) may need more modi cations for more enhancements for the
detection accuracy and lowering the classi cation time. Further researches
may provide these required enhancements.
6 Acknowledgment
This paper has been elaborated in the framework of the project New creative teams
in priorities of scienti c research, reg. no. CZ.1.07/2.3.00/30.0055, sup-ported by
Operational Programme Education for Competitiveness and co- nanced by the
European Social Fund and the state budget of the Czech Republic and supported by
the IT4Innovations Centre of Excellence project (CZ.1.05/1.1.00/02.0070), funded by
the European Regional Development Fund and the national budget
of the Czech Republic via the Research and Development for Innovations
Oper-ational Programme.
This work was partially supported by the IPROCOM Marie Curie initial
training network, funded through the People Programme (Marie Curie Actions)
of the European Union’s Seventh Framework Programme FP7/2007-2013/
under REA grant agreement No. 316555. This fund only apply for one author
(Hossam M. Zawbaa).
References
2. Huang, Phoenix X., Bastiaan J. Boom, and Robert B. Fisher. "Hierarchical classi - cation
with reject option for live sh recognition." Machine Vision and Applications 26, no. 1, pp.
89-102, 2014.
3.Ravanbakhsh, Mehdi, Mark R. Shortis, Faisal Shafait, Ajmal Mian, Euan S. Har-vey, and James
W. Seager. "Automated Fish Detection in Underwater Images Using ShapeBased Level Sets."
The Photogrammetric Record 30, no. 149, pp. 46-62, 2015.
4. Ravanbakhsh, Mehdi, M. Shortis, F. Shafait, Ajmal Mian, Euan Harvey, and J. Sea-ger.
"An application of shape-based level sets to sh detection in underwater images." In
Geospatial Science Research 3 Symposium (GSR 3), Rheinisch-Westfaelische Tech-
nische Hochschule Aachen Lehrstuhl Informatik V, vol. 1307, pp. 1-9, 2014.
5. Shortis, Mark R., Mehdi Ravanbakskh, Faisal Shaifat, Euan S. Harvey, Ajmal Mian,
James W. Seager, Philip F. Culverhouse, Danelle E. Cline, and Duane R. Edgington. "A
review of techniques for the identi cation and measurement of sh in underwater stereo-
video image sequences." In SPIE Optical Metrology, International Society for Optics and
Photonics, pp. 87910G-87910G, 2013.