COMPARATIVE ASSESSMENT OF THE OPTICAL-ELECTRONIC IMAGES SEGMENTATION QUALITY BY THE ANT COLONY OPTIMIZATION AND THE ARTIFICIAL BEE COLONY

The article discusses the methods of swarm intelligence, namely, an improved method based on the ant colony optimization and the method of an artificial bee colony. The goal of the work is to carry out a comparative assessment of the optical-electronic images segmentation quality by the ant colony optimization and the artificial bee colony. Segmentation of tonal optical-electronic images was carried out using the proposed methods of swarm intelligence. The results of the segmentation of optical-electronic images obtained from the spacecraft are presented. A visual assessment of the quality of segmentation results was carried out using improved methods. The classical errors of the first and second kind of segmentation of optoelectronic images are calculated for the proposed methods of swarm intelligence and for known segmentation methods. The features of using each of the proposed methods of swarm intelligence are determined. The tasks for which it is better to use each of the proposed methods of swarm intelligence are determined.


Introduction
Today, data of the remote sensing of the Earth have become available to a wide range of users.They are actively used for many purposes in the fields of life.Scientific and technical achievements in the field of creation and development of space remote sensing systems, technologies for obtaining, processing and thematic interpretation of data have many times expanded the list of tasks that are solved with their help [1].
Currently, most data of the remote sensing of the Earth is obtained from space.Large one-time coverage of the captured territory of the Earth's surface, high temporal, spatial and spectral resolution of satellite images allow to receive large amounts of data on the territory of interest in an on-line mode [2].Data of the remote sensing of the Earth are raster optical-electronic images presented in digital form.Therefore, their processing and interpretation is closely related to digital image processing.
Today, a fairly large number of different methods of digital processing of space images are known [2][3][4][5].The well-known methods of digital image processing were analyzed: Otsu, Canny, Random forest, k-means [6][7][8].Their advantages and disadvantages in the processing of optical-electronic images have been determined.The processing of the considered methods of optoelectronic images was carried out.An assessment of the quality of processing results by known methods has been carried out.
Specialized software for digital image processing, which are designed to process data from remote sensing of the Earth, are considered.The analysis showed that the software uses known image processing techniques.
The analysis of the methods of swarm intelligence, which work well in the processing of medical images, has been carried out [14].Their features are considered.
In works [15][16] it is proposed to use the methods of swarm intelligence for the segmentation of opticalelectronic images, namely the ant colony optimization and the artificial bee colony.
The goal of this work is carrying out comparative assessment of the optical-electronic images segmentation quality by the ant colony optimization and the artificial bee colony.Determination of tasks for which it is better to use one of the proposed methods of swarm intelligence.

Statement of basic materials
Formulation of the problem in general.Let's denote the original optical-electronic image -( , ) f x y , the result of segmentation of the original optical-electronic image -( , ) fs x y .
Then the process of segmentation can be represented as an expression (1): ( , ) ( , ) Let us point out some assumptions and limitations that must be taken into account when segmentation of tone optical-electronic images using the proposed methods, namely: -the original image is the image after preprocessing; -the original image is undistorted; -the original image must contain objects, the total area of which should not exceed the total area of the background; -the objects on the image in comparison with the background should be compact and low-contrast.
The generalized description of the methods of the swarm intelligence can be represented in the form (2) [17]: , where -swarm intelligence (method based on the ant colony optimization and the method of an artificial bee colony); , , , , , SI S M A P In Out   SI S -the set of agents (ants or bees); M -an object for the exchange of information between agents (ants or bees); A -the rules of operation of methods of swarm intelligence; P -the set of parameters that are used in ru s le A ; In -input of the method of swarm intelligence; Out -output of the method of swarm intelligence.
Let us give a generalized scheme of communication between agents of t e considered methods of h inte ent (Fig. 1  This generation is performed on the first iteration of th A source: adapted from [17]. on the ant colony optimization and the method of an artificial bee colony for the segmentation of opticalelectronic images.

The method ronic images by the ant colony optimization
The main steps of the method by ant colony o tion are as follows [18]: 1.Generation of the initi riginal image.
e method, i.e. ( 1)  j  (expression (3)): The form of the objective function on th j -th iteration is described by expression ( 4): where -the current number of the ant;   m i P j -the probability of the transition of the -th ant to -th turning point of the route during the -th iteration;   -the length of the route section, taking into account the difference in the brightness of neighboring pixels for -th ant at the -th image point on the -th iteration; where a parameter that sets the weight of the pheromone of ants;   -a parameter that sets the "greed" of the method; R -number of possible turning points on the route; 3. Migration of ants.At each iteration ants search for a solution and update pheromones along the route.m Every -th agent: m -starts his way from the exit point of the route; -sequentially goes through all the selected points that are selected using this method.These are the socalled turning points of the route; -ends the path at one of the end points of the route.
The movement of ants occurs according to the criterion of the minimum fitness function.Fitness function ( 4), taking into account the four-connectedness of the movement of ants ( 8): takes the form (9): The attractiveness of the section of route for -th ant at the i -th image's point on he j -th iteration inversely depends on the length of the section of the route.For example, expressions (10)-( ) ) where -the parameter that takes into account the scale of the image.0

D
At the beginning of the method, the amount of pheromone on the route sections is taken equal to some small number 0 F and is the same.After each iteration of the iterative process, the concentration of pheromones is updated in the areas selected by the ants.The update occurs according to the rule (13): where -the rate of evaporation of pheromone; -the concentration of pheromone on -th section of the route, which is created by passing -th agent.

i m
As a result of carrying out a certain number of iterations, routes are determined that are the most attractive according to the selected criterion.On unattractive routes, the pheromone gradually "evaporates".Thus unattractive routes disappear.eory.s.

For
, the ants move to the nearest turning point of the route at each step.As a result, this method of segmentation of the images by the ant colony optimization turns into a "greedy" method of classical optimization th 0  

For
, only the effect of pheromones is taken into account.And this will quickly lead to a suboptimal solution.
0   4. Checking the fulfillment of the conditions for stopping the method.
Conditions for stopping the method can be -reaching the maximum allowable number of iterations of iterative process; -finding the required solution; -the absence of a significant improvement in the value of the fitness function over a certain number of iterations.
If one of the conditions is met, then the resulting segmented image is displayed.Otherwise, the transition occurs calculation of the fitness function .The original image was processed by the method of segmentation of the optical-electronic images by the ant colony optimization.An optical-electronic image obtained from a spacecraft WorldView-1 was taken as the original image [19].This optical-electronic image is presented in grayscale tones from 0 to 255.Image size is 640640 pixels.
This original image meets all the limitations and assumptions that must be taken into account when segmentation of tonal optical-electronic images by the proposed method Fig. 3 shows the original optical-electronic image.D (j) x (j) y (j) k f(x (j),y (j)) f(x (j),y (j)) Fig. 4 shows the result of the method of segmentation of the optical-electronic image (Fig. 3) by the ant colony optimization.Fig. 4. The result of segmentation of the original image (Fig. 3) by the ant colony optimization A source: received by authors.
Visual assessment of the quality of the resulting image makes it easy to identify objects on the segmented image.This is a damaged sea liner.At the same time, it is seen that this method selected contours of objects оn the image.

The method of segmentation of the opticalelectronic images by the artificial bee colony
The main steps of the method by the artificial bee colony are as follows [20]: 1. Generation of the initial positions of the bees on the original image.This generation is performed for s n scout bees only on the first iteration of the method, i.e.
(expression ( 14)): -the vector of the positions of the bees; x y  X -the vector of the positions of s n scout bees on the first iteration of the method, i.e. ; ( 1) j  ( ( )) rand f X -the random number generation operator; 1,..., s i n  .

Calculation of the fitness function for
each -th bee The positions of all working bees are determined according to expression ( 15) and ( 16): where -the vector of the positions of the best bees on the -th iteration; ( 1) In this case, the scout bees are sent to positions whose coordinates are random values.These positions are distributed evenly over the entire original image, that is, over the entire allowable range of values (expression ( 17)): , (18) where the size of the circle along the x-axis of the best and perspective positions; 6.The output of the method of segmentation of the optical-electronic images by the artificial bee colony is the following: -determination of the coordinates of the optimal position of bees (at which the value of the fitness funct ) ij w ll be maximum or minimum -ion (  X -determination of the optimal value of the segmentation threshol th d ( ). ny.
Fig. 5 shows the algorithm of the method of segmentation of the optical-electronic images by the artificial bee colo The criterion of stop can be: -reaching the maximum allowable number of iterations, .s.
-finding the required solution, -the absence of a significant improvement in the value of the fitness function over a certain number of iterations.
The original image was processed by the method of segmentation of the optical-electronic images by the artificial bee colony.An optical-electronic image obtained from a spacecraft Ikonos was taken as the original image [21].This optical-electronic image is presented in grayscale tones from 0 to 255.Image size is 868847 pixels This original image meets all the limitations and assumptions that must be taken into account when segmentation of tonal optical-electronic images by the proposed method Fig. 6 shows the original optical-electronic image.
Fig. 7 shows the result of the method of segmentation of the optical-electronic image (Fig. 6) by the artificial bee colony.imization.
Visual assessment of the quality of the resulting image makes it easy to identify objects on the segmented image.It is a whole plane, a damaged plane, airfield buildings, airfield fuel tanks.At the same time, it is clearly visible that this method selects areas on the image.
Fig. 8 shows the result of the method of segmentation of the original optical-electronic image (Fig. 6) by the ant colony opt Since the method of segmentation of the opticalelectronic images by the ant colony optimization selects iz the original image .( ) f X Also the values of errors of the first and second kind were calculated according to expressions (19) and (20) for the known methods of segmentation of the image.Namely for the method Otsu, Canny, k-means, Random forest.Fig. 8.The result of segmentation of the original image (Fig. 6) by the ant colony optimization The results of evaluating the errors of the first and second kind of segmentation of the original opticalelectronic image (Fig. 6) by the proposed and known methods are shown in Tabl. 1.A source: received by authors.
Table 1 Evaluating the errors of the first and second kind of segmentation of the original optical-electronic image (Fig. 6) by the proposed and known methods  [15].Analysis of the calculated errors of the first and second kind (Tabl.1) shows an improvement in the quality of the tonal optical-electronic image segmenta-tion using one of the methods of swarm intelligence: the method of segmentation of the optical-electronic image by the ant colony optimization or the method of seg-Системи обробки інформації, 2021, випуск 1 (164) ISSN 1681-7710 mentation of the optical-electronic image by the artificial bee colony.

Conclusions
Thus, an improved method based on ant colony optimization and an artificial bee colony method are discussed.Segmentation of tonal optical-electronic images was carried out using the proposed methods of swarm intelligence.The results of the segmentation of optical-electronic images obtained from the spacecraft are presented.
It is established that to solve the problem of selection of areas on the optical-electronic image it is neces-sary to use the method of segmentation of the original optical-electronic image by the artificial bee colony.A visual assessment of the quality of segmentation results was carried out using improved methods.To select the contours on the optical-electronic image, it is necessary to use the method of segmentation of the original optical-electronic image by the ant colony optimization.
The classical errors of the first and second kind of segmentation of optoelectronic images are calculated for the proposed methods of swarm intelligence and for known segmentation methods.The features of using each of the proposed methods of swarm intelligence are determined.

Fig. 1 .
Fig. 1.A generalized scheme of communication between agents with the external environment of the route section for the -th ant at the i -th image's point on th jthe concentration of the -th ant's pheromone at the i -th image's point on he j movements of the -th ant at the -th image's point on themovements of the -th ant at the -th image's point on the -th iteration along the axis; coefficient that takes into account the difference in scales along the x an y axes, brightness of image pixels, different units of measurement of elementary displacements and brigh d tness.1 k  -provided that the brightness takes a value from the range [0…255]; in brightness of neighboring pixels for the -th ant at the -th image's point on th j -th iteration.This difference is determined according to the expression (

Fig. 2
Fig.2shows the algorithm of the method of segmentation of the optical-electronic images by the ant colony optimization.The original image was processed by the method of segmentation of the optical-electronic images by the ant colony optimization.An optical-electronic image obtained from a spacecraft WorldView-1 was taken as the original image[19].This optical-electronic image is presented in grayscale tones from 0 to 255.Image size is 640640 pixels.This original image meets all the limitations and assumptions that must be taken into account when segmentation of tonal optical-electronic images by the proposed method Fig.3shows the original optical-electronic image.

Fig. 2 .Fig. 3 .
Fig. 2. The algorithm of the method of segmentation of the optical-electronic images by the ant colony optimization A source: received by authors.

4 .
, 2,..., ) i S on the -th iteration.j 3. Determination of the perspective positions p ij N and the best positions of bees , taking into account the value of the fitness function of each -th bee.Migration of bees.After determining the perspective and best positions of the bees, the working bees are sent to the environment of these positions.b c of working bees are sent surrounded by each best position.p c of working bees are sent surrounded by each perspective positi

-
best position of i -th bee on th j number of the best positions on the -th iteration; b c -the number of bees that migrate (change position) to the best positionsRnd -the random number; rad -the coefficient that determines the dispersion of bees when they are sent to the best and the perspective perspective position of i -th bee on the -th iteration; j 1,..., the number of the perspective positions on the -th iteration; p c -the number of bees that migrate (change position) to the perspective positions.

e 5 .
number of the scout bees on th j -th iteration.The coefficients and parameters of the method from expressions (14)-(15) are included to the vector of Системи обробки інформації, 2021, випуск 1 (164) ISSN 1681-7710 109 input parameters of the coefficients of the method (form (18)).
size of the circle along the y-axis of the best and perspective positions.

Fig. 5 .
Fig.5.The algorithm of the method of segmentation of the optical-electronic images by the artificial bee colony A source: received by authors.