A comparative study of ﬁne-tuning deep learning models for MRI Images

. A brain tumor is an abnormal development of cells that reproduce uncontrollably and without any external stimulation. If tumors are not found early enough, brain tumors can be fatal to one’s health. Specialists and neurosurgeons employ magnetic resonance imaging (MRI) scans to diagnose brain tumors. Several deep learning methods for detecting the existence of brain tumors have been developed to overcome these constraints. The accurate detection of the size and location of a brain tumor is crucial in the diagnosis of the tumor. Medical image processing is a highly complex and tough discipline in which image processing and its methods are an active research topic. There are various technical deep learning and machine learning algorithms which are used to detect brain tumor. We used CNN architecture, ResNet, VGG16 and inception network in this paper and did a comparative study to ﬁnd out the maximum accuracy for detecting brain tumor. When these algorithms are imposed to MRI images, the prediction of brain tumours is done quickly, and the higher accuracy aids in the treatment of patients. In this paper, after complete procedure and analysis of four di ↵ erent algorithms, we found out that CNN architecture is the most suitable with highest accuracy.


Introduction
The brain is the most sensitive organ of our body, controlling the core functions and characteristics of the human body. According to the National Brain Tumor Society, around 700,000 persons in the United States have been diagnosed with a brain tumor, with that number predicted to climb to 787,000 by 2020 [1]. The brain is one of the most complex organs in the human body, involving a high number of cells that work continuously. Brain tumors grow when cells divide uncontrollably, resulting in an irregular pattern of cells. The grouping of a cell will have an e↵ect on the normal functionality of brain activity and will harm the healthy cell and cause fatal e↵ects to human life [2] . In MRI image processing, digital image processing is critical. In the restorative profession, X-ray pictures are routinely utilized to evaluate and recognize tumor progression in the body. Brain tumor a↵ect both children and adults. Tumors cause severe brain pressure that spreads throughout the entire brain region. Tumor growth occurs inside the skull, interfering with normal brain function. There could be a tumor that leads to cancer, which is a major ⇤ e-mail: vrushabhcr7@gmail.com ⇤⇤ e-mail: vaibhavkharaje1212@gmail.com ⇤⇤⇤ e-mail: shreyashborole18@gmail.com cause of death and accounts for approximately 13 percent of all deaths worldwide. The global cancer incidence rate is increasing at an alarming rate.
The key to e↵ective treatment is early diagnosis of tumors. Previously, brain tumors were discovered manually by professional viewing of images, which took time and often resulted in inaccurate conclusions. Detection consists of determining the presence of a brain tumor; segmentation consists determining the size and location of the tumor; and classification consists of determining the stage of brain tumor detection. Many computers now have features that are commonly used in the medical industry. On known MRI images of tumors, image processing processes such as histogram equalisation and sharpening filters are applied. Computer-assisted technology is quite important Role , because the medical sector demands quick and dependable procedures to diagnose life-threatening disorders such as cancer, the world's leading cause of mortality for patients. So, in our study, we used methodologies and a convolutional neural network model to categorize brain tumors as cancerous or non-cancerous using brain MRI scans.

Literature Survey
A brief explanation of the literature review done by various scientists and researchers have been discussed below. Researchers has used many algorithms in order to attain the accurate detection of brain tumors. We studied the various methodologies and procedures followed by the experts. Ahuja et al., [3] employed a technique known as transfer learning to detect brain tumors and segment the brain. The VGG transfer learning model was utilized to train the dataset for detection in this model, which came from the BRATS 2019 brain tumor segmentation challenge. Using the Super-Pixel approach, the tumor was separated into LGG and HGG pictures.
Cherguif et al., [4] Medical photos were semantically segmented using U-Net. The U-Net design was used to produce a convoluted 2D segmentation network. The BRATS 2017 dataset was used to test and evaluate the suggested model. With 27 convolutional layers, 4 deconvolutional layers, and a Dice coef of 0.81, the suggested U-Net architecture was created.
Choudhury et al., [5] In this article, deep learning approaches using deep neural networks, as well as merging it with a Convolutional Neural Network model, were employed to produce correct MRI scan findings. The researchers suggested a three-layer CNN design that was subsequently joined to a fully connected neural network by the researchers. The accuracy was 96.05 percent, and the F-score was 97.33.
Habbie et al., [6] Semi-automated segmentation was employed on MRI T1-weighted images to examine the probability of a brain tumor using an active contour model. It looked examined morphological active contours with and without edges and morphological geodesic active contours to see how they performed. MGAC outperformed the other two, according to the data.
In this paper, Neelum et al. [7] A concatenation strategy was used to build the deep learning model, and the likelihood of having a brain tumor was studied. To detect and categorize brain cancers, researchers employed the pre-trained deep learning models Inception -v3 and DenseNet201. The Inception -v3 model was pre-trained to extract features and then concatenate them to classify tumors. After that, a softmax classifier was used to classify the data.
In this paper Nalbalwar [8] An integrated Brain Cancer Detection and Classification System was developed using ANN. Histogram equalisation, picture segmentation, image enhancement, and feature extraction were among the image processing techniques used. When compared to other classifiers, the suggested approach for classifying brain pictures utilizing ANN as a classifier has a high classification efficiency. Additionally, sensitivity, specificity, and accuracy are improved. The proposed method is efficient in terms of computation and yields decent results.
Ahmed [9] presented a research in which a Convolutional Neural Network (CNN) was used to diagnose meningioma, glioma, and pituitary tumor with an overall accuracy of 91.3 percent and recall rates of 88 percent, 81 percent, and 99 percent, respectively. To classify distinct forms of brain tumors from MRI image slices, researchers employed a deep learning architecture based on 2D convolutional neural networks. This work employs techniques such as data collection, data pre-processing, pre-modeling, model optimization, and hyper parameter tweaking. In addition, the model's generalizability was tested using 10fold cross-validation on the complete dataset.
Fatih [10] The method used in this paper is based on Hough voting, which is a strategy for fully automatic localization and segmentation of anatomical regions of interest. It also used a robust, multi-regional, versatile, and adaptable to diverse modalities segmentation method based on learning techniques. Di↵erent amounts of training data and data dimensionality (2D, 2.5D, and 3D) are utilized to predict the final outcomes. Convolutional neural networks, Hough voting with CNN, voxel-wise classification, and Efficient patch-wise evaluation using CNN are used to analyze the image.
Kulkarni [11] Brain tumor detection was demonstrated using thresholding algorithms, and a comparative study on tumor detection was described. The obtained results show that the Sobel edge detection operator is e↵ective for tumor detection and tumor boundary extraction. The size and stage of the tumor are determined. For detecting brain tumors, MRI images are the most e↵ective. In this study, digital imaging techniques are critical for detecting a brain tumor in MR images.
Afshar et al., [12] In this they used capsule networks to classify brain tumors using a Bayesian approach. To improve tumor detection results, a capsule network was used instead of CNN because CNN can lose important spatial information. The Bayes Cap framework was proposed by the team. They used a benchmark brain tumor dataset to test the proposed model.
Arya, et al. [18] presented a review of several image preprocessing and segmentation techniques such as image filtration, denoising, histogram-based segmentation, watershed segmentation, SVM-based segmentation, and MRF-based segmentation that can be used as a module to improve accuracy and reduce error rates.
Baljinder Singh et.al, [19]has previously proposed a pre-processing method for removing noise from pictures using a fuzzy filter and a new mean shift based fuzzy cmeans algorithm that consumes less computing time and provides better segmentation output than standard techniques. In the classic fuzzy c-means objective function, the following segmentation approaches have a mean field phrase. Because mean shifts can quickly and readily find cluster centers, all techniques may perform an e↵ective diagnosis of the picture area.
Garima Singh et.al, [20] presents a method for classifying and analyzing image de-noising filters such as the Adaptive filter, Median filter, Un-sharp masking filter, Averaging filter, and Gaussian filter, which are used to remove additive noises such as speckle noise, Gaussian noise, and Salt and pepper noise from MRI images. For comparing the de-noising performance of all the techniques considered, PSNR and MSE are used. A fresh idea is to employ a normalised histogram and segmentation via the K-means clustering method for successful brain tumour identification. For e↵ectively classifying the MRIs, the Nave Bayes Classifier and SVM are used, resulting in precise prediction and classification.
Seetha et al in [21] A CNN system, was presented for the detection and categorization of brain tumours The system uses Fuzzy C-Means (FCM) for brain segmentation, and texture and form features were retrieved from these segmented regions, which were then fed into the SVM and DNN classifiers. The accuracy of the system was determined to be 97.4 percent.
Segmentation of images: The segmentation stage is the most important for properly analyzing images because it a↵ects the accuracy of the subsequent steps. However, e↵ective segmentation is difficult due to the wide range of lesion shapes, sizes, and colours, as well as skin types and textures. Several algorithms have been proposed to address this pervasive issue. [13] Thresholding, edgebased or region-based classification approaches, supervised and unsupervised classification techniques are some of the most common. The following are some examples of common segmentation techniques: Threshold-based segmentation-It either blackens or whitens the pixels in photographs. The pixel value is compared to a threshold value in this procedure. If the pixel value is less than the threshold value, it is replaced with black; otherwise, it is replaced with white. The threshold value can be adjusted to meet the needs of the situation. It's frequently used to distinguish between foreground and background; however it's always divided into only two classes, which is a drawback .This procedure may be effective if the objects in question have a higher intensity than the background or undesired regions of the image.
Clustering based segmentation-in this method uses a crude initial pixel clustering to produce segmented images. Gradient ascent algorithms are used to refine these clusters, the image until it is segmented .These approaches aim to close the gap between pixels and generated clusters [14,15]. Techniques such as K-means, SLIC, and watershed clustering are widely used.
Edge-based segmentation-This method identifies image edges and uses them to identify individual items. Sobel and Canny edge algorithms are two popular edge segmentation techniques.
Graph based segmentation-Individual pixels are used as nodes in a graph in network-based segmentation. The degree of similarity between adjacent pixels is determined by the weights of the links connecting these graph nodes. Pixels are grouped into super pixels or various segments using a collection of nodes and edges. Graph cut and Normal cut are two graph-based segmentation techniques that are widely utilized.

Proposed Work
In this research, we applied Image Processing and Data Augmentation techniques on our dataset obtained through kaggle. We evaluated them through a Convolutional Layer CNN model and compared our CNN model architecture accuracy with pre-trained VGG-16, ResNet-50, and Inception networks models. For training, validation, and testing, we separated our dataset into three pieces. The validation data is used to evaluate the model and alter the parameters, while the training data is used to learn the model. Finally, the test data will be used to evaluate our model. Our proposed technique is divided into many steps. Figure 1 depicts a high-level overview of the proposed methodology.
Data loading-We obtained our dataset of MRI images from kaggle and then successfully loaded. The data set is divided into two folders, each labeled Yes or No. Di↵erent MRI pictures of the patients can be found in both folders. Patients with brain tumors are in the Yes category, whereas patients without brain tumors are in the No folder.
Image Acquisition-Consider that a patient's MRI scan images are either Gray-scale or intensity images, which are shown with a default size of 220*220 pixels. A grayscale converted image can be defined if it is a color image, by utilizing a huge matrix whose entries are integer values between 0 and 255, with 0 representing black and 255 representing white.
Image Pre-processing-Before the image is converted, there is a process that takes place. It includes noise filtering as well as a variety of other functions. It could arrive as a result of a thermal e↵ect. To maintain the crucial information in an image, image smoothing involves removing noise and unnecessary elements. Image pre-processing is a step in the converting process that occurs before the image is transformed. Each image was subjected to the following pre-processing steps: Crop the image such that only the brain is visible (the most important part of the image). Because the photos in the collection come in a variety of sizes, resize the image to have a shape of (240, 240, 3). As a result, in order to be provided as input to the neural network, all scans need to have the same structure. To scale pixel values to the 0-1 range, use normalization.
Data Augmentation: Because this is a short dataset, there were insufficient examples to train the neural network in our proposed study. Furthermore, data augmentation proved helpful in resolving the data imbalance problem. The obtained augmentation images are clearly seen in Figure 2.

Proposed Methodology
Di↵erent classification techniques are employed to classify the brain as normal or consisting of a brain tumor. In Figure 3. We can see the online data-set of images consisting of two classes-yes and no. The images undergo thorough process of four algorithms: CNN, ResNet, VGG16 and Inception v3.  [16] These classification techniques are described below: -VGG16-a vast visual database project used in the development of visual object recognition software. The VGG16 Architecture was designed and launched by Karen Simonyan and Andrew Zisserman of the University of Oxford in their 2014 paper "Very Deep Convolutional Networks for Large-Scale Image Recognition". The number '16' signifies the number of layers in this design, and the acronym 'VGG' stands for Visual Geometry Group, a group of University of Oxford scholars who devised it. ResNet-An artificial neural network (ResNet) is a residual neural network (ANN). It skips the connections that residual neural networks employ to hop between layers. ResNet models commonly use double-or triple-layer skips with nonlinearities (ReLU) and convolution. An artificial neural network (ResNet) is a residual neural network that may be used to train skip weights using an additional weight matrix (ANN). Skip connections, sometimes known as shortcuts, are used by residual neural networks to go over some layers. ResNet models include batch normalisation and double-or triple-layer skips with nonlinearities (ReLU). Inception Networks-Inception Networks have been shown to be more computationally efficient than VGG, both in terms of the amount of attributes generated and the cost incurred. When modifying an Inception Network, great care must be taken to ensure that computational advantages are not lost. The data was overfit when numerous deep layers of convolutions were utilized in a model. Advantages of Inception-Convolutional neural networks with high performance gain. For the highperformance output of an Inception network, efficient use of computational resources with little increase in computation load is required. The ability to extract features from input data at di↵erent scales by using di↵erent convolutional filter sizes. Disadvantages-It is very expensive and takes a lot of time to implement. Consider CNN to be a machine learning system that can take an input image and apply various filters and parameters in the image, allowing it to distinguish among them. CNN works by recognizing and extracting features from images. A CNN is made up of the following components: • The grayscale MRI image is used as the initial layer • Multi-class labels make up the output layer.
• It's vital to realise that ANNs (Artificial Neural Networks) are incapable of grasping.
Advantages of CNN: -They provide translation equivariance, which means that shifting the input data linearly shifts the input in the latent space rather than changing the representation of the input. However, it aids in the development of more robust representations. They make themselves more easily parallelizable, which is why there was a GPU revolution in deep learning research. They provided a significant boost to deep learning research. They can be regarded as backbone function approximates that can be implemented as visual/audio feature extractors for downstream applications that require image/audio data reasoning. They are similar to the mammalian visual cortex, and there are neuroscientific links between biological visual cortex and artificial CNNs. Disadvantages of CNN: -They lack a sense of memory state and are rather limited in sequential modelling (such as language models, speech recognition etc.)

Result Analysis
In this study, we used di↵erent algorithms for detecting brain tumor after applying pre-processing, augmentation and splitting of images. For each stage of image processing, numerous algorithms have been proposed in the literature. In this paper, we compared four classification algorithms ResNet, VGG16, Inception and CNN which are amongst the most often utilized techniques. From accuracy graphs of respective models in Figure 5. and Figure  6. Comparison analyzing we can conclude that CNN architecture provide best accuracy. This is the stage where you basically train the algorithms to produce the desired results. The input parameters are available during the learning phase. Basically, you have the model's architecture and the input data. You're actually teaching the algorithm something new. The training parameters are changed by the algorithm during training. It also alters the input data before producing an output. You are assessing once you have received an output. Is that output acceptable, or is it not the expected output? Then you go on to the next step of instruction. When you're pleased with the progress, you'll put the model into execution.
CNN model has the best overall accuracy as well as the best F1 score. CNN is a vital backbone model that is utilized in a wide range of computer vision applications and deep learning models. We compared our CNN model with previous research paper's CNN model and found out that previous model's accuracy was in the range of 72-78 percentage, whereas our accuracy was 82 percentage.To build the model, we divided it into training and test phases, and we trained the model with CNN (Conventional Neural Networks), which increased the accuracy of the model. The model has an 82 percent accuracy, which is better than all other models

Future Work
Currently, the majority of deep learning algorithms follow the section of tumor area categorization, but the present research is unaware of the tumor region's anatomical location. More research in this area could focus on incorporating this information into the neural network, possibly by feeding the network the entire image. However, due to memory and processing power constraints, training the network on brain tumor images is not possible due to their vast size and high resolution (in the gigapixel range). We can utilise U-Net architecture instead of CNN for more complicated datasets because the max pooling levels are simply replaced with up sampling layers. We eventually want to employ very big and deep convolutional nets on video sequences where the temporal structure provides very useful information that is missing or less visible in static images. In the future, unsupervised transfer learning may gain in popularity. Using VolumeNet in conjunction with the LOPO (Leave-One-Patient-Out) strategy has resulted in high training and validation accuracy. Each iteration of the LOPO test scheme uses one patient for testing and the remaining patients for training the ConvNets; this iterates for each patient. Despite the fact that the LOPO test method is computationally expensive, it allows us to collect more training data, which is necessary for Con-vNets training. LOPO testing is reliable and well-suited to our application, which requires us to obtain test results for each individual patient. So, if the classifier incorrectly labels a patient, we can look into it independently.