# Genetic Algorithms Applications For Medical Edge Biology Essay

Abstract:Applying new technologies in medicine is very important as this way the quality of medical services is improved. One area of applying new technologies in medicine is the use of Genetical Algorithms.

Medical Image Processing and Medical Image Enhancement is the art of examining images of part of the human body and evaluate their health status. The concept of Genetic Algorithms was proved to be the most powerful unbiased optimization technique for sampling a large amount of data from the solution space. They can be applied for the medical image enhancement, segmentation, feature extraction, classification and image generation. In this paper, we deal with medical image enhancement using Genetic Algorithm (GA) and the Morphological filter to sharpen the detected edges thus improving the contrast of the image. This article gives a brief overview of the canonical genetic algorithm and it also it reviews the tasks of image pre-processing. The constant improvement of genetic algorithms will definitely help us to solve a lot of complex image processing duties/tasks in the future.

The use of GA as an optimization tool is not a new phenomenon; GA has been used by scientific research community for sometime. This paper is an effort to shed light into the use of GA in new and older approaches.

## Introduction.

Genetic algorithms (GA) are adjusted helpful search algorithms which are based on the evolutionary ideas of natural selection and genetic. GAs are a relatively new paradigm for a search, based on principles of natural selection. They were proven to be the most powerful optimization technique in a large solution space .

From the other side, Medical image processing is a hard task in hand. Most of the medical images (X-Ray, CT, and MRI) have very low contrast and the challenge is to sharpen them.

With Edges we can define the representations of the discountiniuties of the image intensity functions.

But how can we define "Edge Enhancement"? Edge Enhancement is a digital image processing filter that is used to make pictures

look artificially sharper than they really are.

For processing these discontinuities in an image a good edge enhancemen technique is very impotant reduces complexity and makes the images look sharper than they really are. Here we developed a new filter known as Enhanced filter.This Enhanced filter is implemented using genetic algorithm. In this paper we also compare the performance of the proposed filter are compared to linear filters and nonlinear filters theoretically and experimentally. The purpose of this article is to inspect GA applications for fundamental image processing, image enhancement and image segmentation. Brief Descriptions of problems are given below.

## 1. Genetic algorithm

Genetic algorithms are based on natural selection. In computer world, genetic material is replaced by strings of bits and natural selection replaced by fitness function.

## A simple GA (Figure 1) consists of five steps :

1. First we start with a generated population which is random of N chromosomes, where N-the size of population ; l-length of chromosome x.

2. In the second step of the flowchart bwe calculate the fitness value of function which is expresed with (x) of each chromosome x in the population.

3. Repeat until N offsprings are created:

3.1.Select a pair of chromosomes from current population.

3.2. Produce an offspring yi using crossover and mutation operators, where i = 1, 2, …, N.

Here we have a condition which say that if is done or not(so if we have the new one population we go down and replace the old one and if not we go back in the selection of the pair of the chromosomes.

4. Replace current population with newly created one(the condition).

5.Go back to step two.

For example, GA is used to enhance image contrast. It is done by mapping Intensity of image values according to the predefined table. Each intensity value I is mapped to a new value B. In this case, each chromosome x is represented by a byte string,where each byte (gene) encodes the difference b(j-1) between values of transformed curve B(j) and B(j-1) (Figure 2), where j is a byte position in chromosome. The value of curve B(j) is represented by (Figure 2), where j is a byte position in chromosome. The value of curve B(j) is represented by

Where I max and I min represent minimum and maximum intensity values.

## 2. Applications for image enhancement

The first duty of machine is to enhance image quality to obtain a required image perception. It is done by removing noise, amplifying image contrast and amplifying the level of a detail. The GAs were used to have better results, faster processing times and more specialized applications. The GAs were used to have better results, faster processing times and more specialized applications. GAs are used to built new filters, to optimize parameters of existing filters, and to look for optimal sequence of existing filters.

For filtering and enhancement of a colour image, there is a useful class of weighted vector directional filters (WVDF) . It was proved that they can’t converge to globally optimal coefficient weight vector .Let us consider a two-dimensional matrix of three component samples (pixels) ponent samples (pixels) xi = (xi1,xi2,xi3) which represents which represents K1 x K2 colour image colour image x(i):Z2Z3; and a sliding window W = {xiZ2;i=1,2,….N} of finite odd sixe N. Window usually affects one image pixel at the centre of the N window. WVDF filters utilize a non-negative real weight coefficients vector w=(w1,w2,….wN) associated with image sample vectors X1,X2,…XN . Each weight vector element corresponds to one image 21 pixel. Weight coefficients’ vector is similar to the feature vector used in . The output of filter y = xi W minimizes the sum of aggregated angular distances to other image samples inside the window W:

min where represents the angle between the two colour vectors xi = (xi1,xi2,xi3) and x j= (xj1,xj2,xj3) .

Each set of weight coefficients represents a different filter. Optimization procedure must be adopted to obtain an optimal filter.In the other hand elitism was used to improve the performance. The elitism parameter re multiplied by N P denotes fraction of the best individuals which will appear un- changed in the next generation. Small groups are selected from population and individuals and they compete only in the scope of the selected group. This helps to eliminate premature convergence and domination of one genotype. Premature convergence can be eliminated by using ranking scheme . In such case every chromosome is ranked according to its fitness value. Filter optimization which uses GA significantly improves colour/structural characteristics of the traditional colour filtering scheme. Optimized filters exhibit acceptable noise attenuation capabilities.

## 5.Applications for image segmentation

Image segmentation can be consider a process by which input image is non-overlapping regions. Each region is homogeneous and connected. Each region in a segmented image has to satisfy properties of homogeneity and connectivity.

The region is considered to be homogeneous if all region pixels satisfy homogeneity conditions defined per one or more pixel attributes, such as intensity, colour, texture, etc. The region is connected if a connected path between any two pixels within the region exist.

We can say that one of the most fundamental segmentation techniques are edge detection. It usually involves two stages:

The first one is edge enhancement process that requires the evaluation of derivatives of the image and usage of gradient or Laplacian operators (Figure 5).

The second stage involves selection and combination of edge map pixels using boundary detection, edge linking and grouping of local edges.This stage can be viewed as a search for optimal configuration of pixels that better approximate edges.

Algorithm estimates each chromosome by using a cost function. The form of the point cost function is a linear combination of five weighted point factors .It includes fragmentation, thickness, local length, region similarity and curvature.

In those steps we say that Segmentation of medical images is difficult because of poor image contrast and artifacts which result in missing or distributed of organ/tissue boundaries.Segmenting curve is represented using a level set function, which use genetic algorithm (GA).

## 6.Methods for Image Edge Enhancement

## A.Image Edge Enhancement

What is edge enhancement?

Edge Enhancement is a digital image processing filter that is used to make pictures look artificially sharper than they really are. The key word here is looking sharper, because the picture isn't really any more detailed than before. The human eye is

simply tricked into thinking the picture is sharper.

Edges are basic features of an image, which carry valuable information, useful in image analysis object classification.Edge enhancement has been topic of fruitful research in recent years. There are various approaches to the problem, based on the different philosophies.

## B.Smoothening FIlters

## 1. Mean Filter

Mean filter is the simplest of all the smoothening operations.The mean filter is used in the elimination of sharp transitions in intensity.

## 2.Median Filter

The median filter replaces the pixel at the center of the mask by the median of all the pixel values in the mask. And the middle value in sorted array is considered as the median. The blurring effect of the median filter is less than the averaging filter as can be clearly observed. Also clearly visible is that median filter preserves edge sharpness. The only disadvantage is that they take significantly more time to apply.

## 3.Mode Filter

The mode filter replaces the pixel at the center of the mask by the mode of all the pixel values in the mask.The mode value is nothing but the maximally repeated value in the mask.

## 4. Circular Filter

In this filter, we will convolute the image the mask provided. This filter is different from the mean filter. The filter is shown below

## 5. Triangular Filter

In the triangular filter the output image is based on a local averaging of the input filter, where the values with in the filter support have different weights. In general, the filter can be seen as the convolution or spiral of two identical uniform filters. If we transfer functions of Tringular filters we see that we will get positive values and so it will not display the phase reversal. There are two filters of this kind, namely Pyramidal filter and Cone filter. The convolution masks for these are shown below.

## C. Implementation of Enhanced Filter using Genetic Algorithm

## 1.Enhanced Filter

Enhanced filter is defined as the filter consists of series of existing filters (smoothening filters) to optimize the existing filters. Enhanced filter is taken as combination of smoothening filters and we can get optimal threshold values using clustering algorithm.

## 2.Genetic Algorithm in Enhanced filter.

The best optimal Enhanced filter is chosen with the help of Genetic Algorithm. Gas are based on natural selection. They employ natural selection of fittest individuals as Optimisation problem solver. Optimisation is performed through natural exchange of genetic material between parents. Offspring’s are formed from parent genes. Fitness of Offspring’s is evaluated. The fittest individuals are allowed to breed only. In computer world selection is done by fitness function. Matching of parents is represented by cross-over and mutation operations .

## A simple GA (fig. 1) consists of five steps:

(i). Start with a randomly generated population of N chromosomes, where, N is the size of population, l - length of chromosome x.

(ii). Calculate the fitness value of function F(x) of each chromosome x in the population.

(iii). Repeat until N Off springs is created:

(a). Probabilistically select a pair of chromosomes from current population using value of fitness function.

(b). Produce off springs using crossover and mutation operators.

(iv). Replace current population with newly created one.

(v). Go to step 2.

## (i). Initialization of Random Population

We represent image as a matrix of pixel values. Here we represent the random population with the set of optimal magnitudes obtained for these Enhanced filter combinations. First optimal magnitudes of the image are obtained by using Adaptive Thresholding With Foreground And Background Clustering algorithm .

## (a) Adaptive Threshold with Foreground and Background Clustering Algorithm

In the Foreground and Background Clustering (FBC) approach to document image binarization, each pixel is assigned to a foreground cluster or a background cluster. Pixel clustering is based on a variant of the K-means algorithm due to McQueen, where the cluster means are updated each time a data point is assigned to a cluster. Since only one background and one foreground are assumed, K=2, i.e. only two clusters are considered, which makes the overall implementation easier.

## 1. Region Selection

Divide the document into all inclusive mutually exclusive sub regions. Select the document sub region for which the threshold will be computed, and a region containing the sub region that will be used to determine the threshold sub region. For example, the region may consist of N contiguous scan lines, where the sub region is the center M scan lines, with M<N.

## 2. Initialization

Initialize the background cluster mean and the foreground cluster mean to be the same as computed for the previous sub region. If there is no previous sub region, set the two initial cluster means with a large separation between them. For each pixel inside the region, iterate between steps 3 and 4:

## 3. Pixel Assignment

Assign each pixel to the nearest group.

## 4. Cluster Mean Update

After each new pixel assignment update the relevant cluster mean.

## 5. Threshold Calculation

After all pixels in the region have been assigned, set the threshold for the sub region equal to the average of the foreground and background cluster means.

After obtaining the optimal magnitude of the image we take the random population with the magnitudes of different combinations which are closer to the obtained optimal magnitude.

## (ii). Evaluation of fitness

An individual fitness is measured by the sum of intensities of edges in an enhanced image, because a gray image with a visual good contrast includes many intensive edges.

## (iii). Rule of Selection, Extinction and Multiplication

Rules of selection, extinction and multiplication of individuals in the genetic algorithm are described in this section. The number of individuals in the population is made G. Only individuals that have higher fitness are selected in the population, and they are survived to the next generation. On the other hand, individuals that have lower fitness are extinguished in the population because they do not have qualifications to survive to the next generation. Child individuals to the same number as the numbers of extinguished individuals are generated using gene information in survived individuals. Therefore, the number of individuals in the population is kept a constant in all generations.

## (iv). Reproduction

The next step is to generate a second generation population of solutions from those selected through operators: crossover (also called recombination), and/or mutation.

## (a). Crossover

A parent-A and a parent-B are selected at random in the group of individuals that survive to the next generation . And a child-individual is generated by the two-point crossover using the chromosomes of the parent-A and the parent-B. The two point crossover is shown below:

## (b). Mutation

The purpose of mutation in GAs is to allow the algorithm to avoid local minima by preventing the population of chromosomes from becoming too similar to each other, thus slowing or even stopping evolution.

## 5. Conclusions

GA can be used as a very promised unbiased optimization method; it constantly gains popularity in image processing. Various tasks from basic image contrast and level of detail enhancement, to complex filters and deformable models parameters are solved using this paradigm. The algorithm allows to perform robust search without trapping in local extremes. The success of optimization strongly depends on the chosen chromosome encoding scheme, crossover and mutation strategies as well as fitness function. As it is shown, one chromosome can contain a whole image or only a small part of it, a whole parameter range or only the most descriptive ones. Crossover can be performed in various manners, for example by exchanging information at one brake point. Different strategies may be used for genetic information transfer and parallel evolution may be adopted.