Project Final Report
Project Final Report
Project Final Report
PROJECT REPORT
ON
BACHELOR OF ENGINEERING
IN
COMPUTER SCIENCE & ENGINEERING
Submitted By
New Delhi)
2021-22
CERTIFICATE
Guide: H.O.D:
a
Dr. Shantale C P Ph.D. Dr. Shantala C P Ph.D
Prof& Head, Dept. of CSE, Prof &Head, Dept. of CSE,
CIT, Gubbi, Tumakuru. CIT, Gubbi, Tumakuru.
Principal: Examiners:
areb 1.
Dr. Suresh D S Ph.D..
CIT, Gubbi, Tumakuru. 2.
Channabasaveshwara Institute of Technology
(NAAC Accredited & ISO 9001:2015 Certified Institution)
NH 206 (B.H. Road), Gubbi, Tumakuru – 572 216. Karnataka.
(Affiliated to Visvesvaraya Technological University, Belagavi & Recognized by AICTE
New Delhi)
2021-22
CERTIFICATE
Guide: H.O.D:
Principal: Examiners:
1.
Dr. Suresh D S Ph.D.,
CIT, Gubbi, Tumakuru. 2.
Channabasaveshwara Institute of Technology
(NAAC Accredited & ISO 9001:2015 Certified Institution)
NH 206 (B.H. Road), Gubbi, Tumakuru – 572 216. Karnataka.
UNDERTAKING
2. HIMAGIRISHA N D 4. DARSHAN G A
[1CG18CS033] [1CG18CS025]
Channabasaveshwara Institute of Technology
C.I.T (NAAC Aceredited & ISO 9001:2015 Certified Institution)
N H 206 (B.H. Road), Gubbi, Tumakuru- 572 216. Karnataka.
BONAFIDE CERTIFICATE
Guide:
a
Df. Shantala C PraD.,
Prof &Head, Dept. of CSE,
CIT, Gubbi, Tumakuru.
Channabasaveshwara Institute of Technology
(NAAC Accredited & ISO 9001:2015 Certified Institution)
NH 206 (B.H. Road), Gubbi, Tumakuru – 572 216. Karnataka.
BONAFIDE CERTIFICATE
Guide:
Several special people have contributed significantly to this effort. First of all, we
are grateful to our institution Channabasaveshwara Institute of Technology, Gubbi
which provided us an opportunity in fulfilling our most cherished desire of reaching the
goal.
We acknowledge and express our sincere thanks to Dr. Suresh D S, Director and
Principal, for his many valuable suggestions and continued encouragement and support in
the academic endeavors.
We wish to express our deep sense of gratitude to Dr. Shantala C P, Head of the
Department of Computer Science and Engineering for all the guidance and who still
remains a constant driving force and motivated through innovative ideas with tireless
support and advice during the project to examine and helpful suggestions offered.
We wish to express our deep sense of gratitude to our project guide Dr. Shantala C
P, Head of the Department of Computer Science and Engineering, CIT, Gubbi for her
meticulous attention to details, which has contributed immeasurably to the quality of the
project report.
We would express our gratitude towards our parents and friends for their kind
cooperation and encouragement which helped us in completion of this project.
Finally, we would like to thank all the teaching and non-teaching staff of Dept. of
CSE, for their cooperation.
Thanking everyone……
DARSHAN G A [1CG18CS025]
MAHADEV [1CG18CS048]
HIMAGIRISH N D [1CG18CS033]
i
ABSTRACT
Brain Tumor segmentation is one of the most crucial and arduous tasks in the
terrain of medical image processing as a human-assisted manual classification can
result in inaccurate prediction and diagnosis. Moreover, it is an aggravating task when
there is a large amount of data present to be assisted. Brain tumors have high diversity
in appearance and there is a similarity between tumors and normal tissues thus the
extraction of tumor regions from images becomes unyielding
ii
TABLE OF CONTENTS
ACKNOWLEDGEMENT i
ABSTRACT ii
LIST OF FIGURES v
LIST OF TABLES v
1.1.Problem Statement 2
1.2.Objectives 2
3.1.Existing System 10
3.2.Proposed System 11
4.1.System Architecture 12
4.2.Flowchart 13
4.4.Sequence Diagram 15
5. IMPLEMENTATION 16-25
5.1.Importing libraries 16
5.2.Image Dataset 17
5.3.Image Pre-processing 19
5.4.Building of Model 22
6. MODEL TESTING 26
7. RESULTS 27-29
8. CONCLUSION 30
REFERENCES
iv
LIST OF FIGURES
Figure Name Page No.
Figure 4.1: Architecture of the proposed system 12
Figure 7.1: Loss and Accuracy plot over the training period 27
LIST OF TABLES
Table Name Page No.
Table 6.1: Model Testing Prediction Results 28
v
Brain Tumor Detection using CNN 2021 - 2022
CHAPTER 1
INTRODUCTION
the interior of a body for clinical analysis and medical intervention, as well as visual
representation of the function of some organs or tissues. Medical imaging seeks to reveal
internal structures hidden by the skin and bones, as well as to diagnose and treat disease.
Medical imaging also establishes a database of normal anatomy and physiology to make
it possible to identify abnormalities. Medical imaging processing refers to handling
images by using a computer. This processing includes many types of techniques and
operations such as image gaining, storage, presentation, and communication.
The brain tumor is one all the foremost common and, therefore, the deadliest brain
diseases that have affected and ruined several lives in the world. Cancer is a disease in
the brain in which cancer cells ascend in brain tissues. Conferring to a new study on
cancer, more than one lakh people are diagnosed with brain tumors every year around the
globe. Regardless of stable efforts to overcome the complications of brain tumors,
figures show unpleasing results for tumor patients. To contest this, scholars are working
on computer vision for a better understanding of the early stages of tumors and how to
overcome them using advanced treatment options.
Magnetic resonance (MR) imaging and computed tomography (CT) scans of the
brain are the two most general tests to check the existence of a tumor and recognize its
position for progressive treatment decisions. These two scans are still used extensively
for their handiness, and the capability to yield high-definition images of pathological
tissues is more.
The focus of this project is MR brain image tumor extraction and its representation
in a simpler form such that it is understandable by everyone. The objective of this work
is to bring some useful information in simpler form in front of the users, especially for
the medical staff treating the patient. This work aims to define an algorithm or a system
that will result in an extracted image of the tumor from the MR brain image. The
resultant image will be able to provide information like the size, dimension, and position
Department of CSE, CIT, GUBBI Page 1
Brain Tumor Detection using CNN 2021 - 2022
of the tumor, and its boundary provides us with information related to the tumor that can
prove useful for various cases, which will provide a better base for the staff to decide the
curing procedure. Finally, we detect whether the given MR brain image has a tumor or
not using Convolution Neural Network and classify the tumor if present.
Based on our study on automated brain tumor detection and classification, normally
the anatomy of the brain is analyzed by MRI scans or CT scans. Histological grading,
based on a stereotactic biopsy test, is the gold standard and the convention for detecting
the grade of a brain tumor. The biopsy procedure requires the neurosurgeon to drill a
small hole into the skull from which the tissue is collected. There are many risk factors
involving the biopsy test, including bleeding from the tumor and brain causing infection,
seizures, severe migraine, stroke, coma, and even death. But the main concern with the
stereotactic biopsy is that it is not 100% accurate which may result in a serious diagnostic
error followed by wrong clinical management of the disease. Tumor biopsy is
challenging for brain tumor patients, non-invasive imaging techniques like Magnetic
Resonance Imaging (MRI) have been extensively employed in diagnosing brain tumors.
Therefore, the development of systems for the detection and prediction of the grade of
tumors based on MRI data has become necessary.
1.2 OBJECTIVES
• We aim to develop an automated system for the enhancement and classification of
brain tumors that can be used by neurosurgeons and healthcare specialists.
The project is mainly useful and focused on the medical field where several users
can make use of it. This benefits many patients in identifying their Brain tumor results
based on the MRI images that they have; from this, they will get to know whether they
have a tumor or not, if present our system can go one step further and classify the type of
tumor that the patient has (i.e. Meningioma Tumor, Pituitary Tumor, Glioma Tumor). It
also benefits the doctors in determining the tumor and treating their patients well to
minimize its effects which may sometime save many lives.
CHAPTER 2
LITERATURE SURVEY
RELATED WORK
In Medical diagnosis, robustness and accuracy of the prediction algorithms are very
important, because the result is crucial for the treatment of patients. There are many
popular classification and clustering algorithms used for prediction. The goal of
clustering a medical image is to simplify the representation of an image into a
meaningful image and make it easier to analyze. Several Clustering and Classification
algorithms are aimed at enhancing the prediction accuracy of the diagnosis process in
detecting abnormalities.
In the literature survey, we provide a summary of the different methods that have
been proposed for clustering over from 2018. We have been through 15 papers each of
which has a unique approach toward segmentation in some parameter or the other. The
summaries of each of the papers are provided below.
• Asra Aslam, Ekram Khan, M.M. Sufyan Beg, Improved Edge Detection
Algorithm for Brain Tumor Segmentation, Procedia Computer Science, Volume
58,2015, Pp 430-437, ISSN 1877-0509.
M. M. Sufyan et al. [2] hahaveresented a detection using Earn advanced edge technique
for brain-tumor segmentation that mainly relied on Sobel feature detection. Their
presented work associates the binary thresholding operation with the Sobel approach and
excavates diverse extents using a secure contour process. After the completion of that
process, cancer cells are extracted from the obtained picture using intensity values.
• Devkota, B. & Alsadoon, Abeer & Prasad, P.W.C. & Singh, A.K. & Elchouemi, A.
(2018). Image Segmentation for Early Stage Brain Tumor Detection using
Mathematical Morphological Reconstruction. Procedia Computer Science. 125.
115-123. 10.1016/j.procs.2017.12.017.
B. Devkota et al. [4] have proposed that a computer-aided detection (CAD) approach is
used to spot abnormal tissues via Morphological operations. Amongst all different
segmentation approaches existing, the morphological opening and closing operations are
preferred since it takes less processing time with the utmost efficiency in withdrawing
tumor areas with the least faults.
• Kaur, Jaskirat & Agrawal, Sunil & Renu, Vig. (2012). A Comparative Analysis
of Thresholding and Edge Detection Segmentation Techniques. International
Journal of Computer Applications. vol. 39 .pp. 29-34. 10.5120/4898-7432.
Jaskirat Kaur et al. (2012) [6] defined a few clustering procedures for the segmentation
process and executed an assessment of distinctive styles for those techniques. Kaur
represented a scheme to measure selected clustering techniques based on their steadiness
in exceptional tenders. They also defined the diverse performance metric tests, such as
sensitivity, specificity, and accuracy.
• Li, Shutao, JT-Y. Kwok, IW-H. Tsang and Yaonan Wang. "Fusing images with
different focuses using support vector machines." IEEE Transactions on neural
networks 15, no. 6 (2004): 1555-1561.
J.T. Kwok et al. [7] delivered wavelet-based photograph fusion to easily cognizance of
the object with all focal lengths as several vision-related processing tasks can be carried
out more effortlessly when wholly substances within the images are bright. In their work,
Kwok et al. investigated different datasets, and the results in ts show that the presented
work is extra correct as it does not get suffering from evenness at different activity stages
computations.
• M. Kumar and K. K. Mehta, "A Texture based Tumor detection and automatic
Segmentation using Seeded Region Growing Method," International Journal of
Computer Technology and Applications, ISSN: 2229-6093, Vol. 2, Issue 4, PP.
855-859 August 2011.
Kumar and Mehta [8] proposed the texture-based technique in this paper. They
highlighted the effects of segmentation if the tumor tissue edges aren't shrill. The
performance of the proposed technology may get unwilling results due to those edges.
The texture evaluation and seeded region approach turned into executed inside the
MATLAB environment.
• Mahmoud, Dalia & Mohamed, Eltaher. (2012). Brain Tumor Detection Using
Artificial Neural Networks. Journal of Science and Technology. 13. 31-39.
Dalia Mahmoud et al. [9] presented a model using Artificial Neural Networks for tumor
detection in rain images. They implemented a computerized recognition system for MR
images withing the use of Artificial Neural Networks. That was observed that after the
Elman community was used during the recognition system, the period time and the
accuracy level were high, in comparison with other ANNs systems. This neural
community has a sigmoid characteristic which elevated the extent of accuracy of the
tumor segmentation.
• Marroquin J.L., Vemuri B.C., Botello S., Calderon F. (2002) An Accurate and
Efficient Bayesian Method for Automatic Segmentation of Brain MRI. In:
Heyden A., Sparr G., Nielsen M., Johansen P. (eds) Computer Vision — ECCV
2002. ECCV 2002. Lecture Notes in Computer Science, vol 2353. Springer,
Berlin, Heidelberg.
L. Marroquin et al. [10] presented the automated 3d segmentation for brain MRI scans.
Using a separate parametric model in preference to a single multiplicative magnificence
will lessen the impact on the intensities of a GA brain. A brain atlas is hired to find non-
rigid conversion normal to the usual brain. This transformation is further used to segment
the brain from non-brain tissues, computing prior probabilities and finding automatic
initialization,n, and finally applying the MPM-MAP algorithm to find out optimal
segmentation. Major findings from the study show that the MPM-MAP algorithm is
comparatively more y robust than EM in terms of errors while estimating the posterior
marginal. For optimal segmentation, the MPM-MAP algorithm involves only the solution
of linear systems and is therefore computationally efficient.
Astina minz et al. [11] implemented an operative automatic classification approach for
images image that projected the usage of the AdaBoost gadget mastering algorithm. The
proposed system includes three main segments. Pre-processing has eradicated noises in
the datasets and converted images into grayscale. Median filtering and thresholding
segmentation are implemented in the pre-processed image.
Monica Subashini and Sarat Kumar Sahhave[12] have suggested a technique for
detecting the tumor commencing the brain MR images. They also worked on different
techniques, which include pulse-coupled network networks and noise removal strategies
for reinforcing the mind MRI in mages and backpropagation network for classifying the
brain MRI images from tumor cells. They observed image enhancement and
segmentation of the usage of their proposed technique, and the backpropagation network
helps in the identification of a tumor in a brain MR image.
• S. Li, J.T. Kwok, I.W Tsang, and Y. Wang, ―Fusing Images with Different
Focuses using Support Vector Machines, Proceedings of the IEEE transaction on
Neural Networks, China, November 2007.
Li et al. [13] report that edge detection, image segmentation, and matching are not easy
to achieve in optical lenses that have long focal lengths. Previously, researchers have
proposed many techniques for this mechanism, one of which is wavelet-based image
fusion. The wavelet function can be improved by applying a discrete wavelet frame
transform (DWFT) and a support vector machine (SVM). In this paper, the authors
experimented with five sets of 256-level images. Experimental results show that this
technique is efficient and more accurate as it does not get affected by consistency
verification and activity level measurements. However, the paper is limited to only one
task related to fusion, and dynamic ranges are not considered during the calculation.
H. Yu et al. [14] state that image segmentation is used for extracting meaningful objects
from an image. They propose segmenting an image into three parts, dark, grey, and
white, Z-function and s-function are used for the fuzzy division of the 2D histogram.
Afterward, QGA is used for finding a combination of 12 membership parameters, which
have a maximum value. This technique is used to enhance image segmentation and the
significance of their work is that three-level image segmentation is used by following the
maximum fuzzy partition of 2D Histograms. QGA is selected for the optimal
combination of parameters with the fuzzy partition entropy. The proposed method of
Mukambika et al. [15] propose a sed methodology for the subsequent stage’s
classification of the tumor, whether it is present or not. Their proposed work represents
the comparative study of strategies used for tumor identification from MR images,
namely the Level set approach, discrete wavelength transforms, (DWT), and K-method
segmentation algorithms. After that phase, feature extraction is done by allowed SVM
classification.
CHAPTER 3
SYSTEM ANALYSIS
Brain tumor detection is one of the most difficult tasks in the analysis of medical
images. Globally brain tumors become a very big reason for human death. By using
image processing early the detection of tumors is possible. MR images are considered
because it gives a clear structure of the tumor. In these, they have proposed systems with
a novel mechanism for detecting tumors from MR images by applying machine learning
and deep learning algorithm, ms, especially with the CNN model anime of image
processing techniques.
After the literature survey, it has been observed that most of the authors have used the
most common algorithms and techniques like KNN-technique, Edge detection, and
segmentation techniques, support vector machine, Artificial Neural Network (KNN), Ada
Boost algorithm, and Quantum genetical, algorithms and many more.
Drawbacks of these existing systems:
• Hardware Dependency of Artificial Neural requires requires processors with parallel
processing power, by their structure.
• Since KNN is a distance-based algorithm, the e cost of calculating the distance
between a new point and each existing point is very high which in turn degrades the
performance of the algorithm.
• The structure of Convent aims to mitigate over-fitting, you generally need a large
amount of data for a convolutional neural network to work effectively.
• Some of these systems have lower layer counts which makes them less accurate
while detecting tumors from high-resolution MRIs.
• Many of these systems concentrate only on the binary classification of the MRIs, i.e.
they will just detect the brain tumor.
• The lack of systems that classify the detected brain tumor into its respective type is
more useful and needed.
• Classification of the tumor is equally important with its detection because detection
alone will not be of any help. The tumor severity and its treatment are explicitly
dependent on the type of tumor that a person has.
The proposed system uses the deep learning technique CNN to effectively identify
and classify the tumor based on the MRI images. We chose a deep learning technique
like CNN because of its superior performance when it comes to image processing and
classification. Convolution Neural Networks are well reputed in image classification on
different datasets over time thus proving their superiority compared to other techniques.
This system has three phases, Data pre-processing, Model selection and training g the
selected model, and last the testing of the model and its accuracy evaluation. During the
first phases, data is preprocessed to extract the MRIs to continue the further processes.
This dataset is stored in our local machine, these images are accessed through their paths
and these images are augmented. In augmentation, more images are produced using
existing images by rotating their angles, changing brightness, zooming, etc. so that we
have enough data to train the model. This data is split into training data and testing data
which will be used to train our model and test its accuracy respectively. The model that
we have used is EfficientNet-B3 which is based on a convolution neural network and
with minimal layers and parameters, it is proven to be efficient thus giving its name.
After training the model, it is tested on the test data to evaluate its efficiency and
performance. Finally y, the MRI image is fed into the trained model to predict its result
which is either tumor detected or not, if detected our system will classify the detected
tumor into one of its types i.e., either Meningioma Tumor or Pituitary Tumor or Glioma
Tumor.
CHAPTER 4
SYSTEM DESIGN
The design of the system deals with how the system is developed. It explains the flow
functionalities in brief. The section contains system data flow diagram. The flowchart
and Sequence Diagram are described below.
4.2 Flowchart:
FEATURE
EXTRACTION
TRAINING/ FEATURE
TESTING REDUCTION
CLASSIFICATION
Use cases are used during the analysis phase of a project to identify system functionality.
They separate the system into actors and use cases. Actors represent roles that are played
by users of the system. Users may be humans, other computers, or even other software
systems.
Use case diagrams are used to gather the requirements of a system including internal and
external influences. These requirements are mostly design requirements. Hence, when a
system is analyzed to gather its functionalities, use cases are prepared and actors are
identified.
Preprocessing
Feature Extraction
for TestImage
Classification
A sequence diagram shows object interactions arranged in a time sequence. It depicts the
objects and classes involved in the scenario and the sequence of messages exchanged
between the objects needed to carry out the functionality of the scenario. Sequence
diagrams are typically associated with use case realizations in the Logical View of the
system under development. Sequence diagrams are sometimes called event diagrams or
event scenarios. A sequence diagram shows, as parallel vertical lines (lifelines), different
processes or objects that live simultaneously, and, as horizontal arrows, the messages
exchanged between them, in the order in which they occur
Classified Result
Image
Image
Image
Train Features
Image
Test Features
True Label
CHAPTER 5
IMPLEMENTATION
Fig 5.3 Meningioma Tumor MRIs. Fig 5.4 Pituitary Tumor MRIs
The Brain MRI image dataset has been downloaded from Kaggle. The MRI dataset
consists of around 1900 MRI images, including normal, benign, and malignant. These
MRI images are taken as input to the primary step. Pre-processing is an essential and
initial step in improving the quality of the brain MRI Image. The critical steps in pre-
processing are the reduction of impulsive noises and image resizing. In the initial phase,
we convert the brain MRI image into its corresponding gray-scale image. The removal of
unwanted noise is done using the adaptive bilateral filtering technique to remove the
distorted noises that are present in the brain picture. This improves the diagnosis and also
increases the classification accuracy rate
There are more than 150 color-space conversion methods available in OpenCV. For
color conversion, we use the function cv2.cvtColor(input_image, flag) where flag
determines the type of conversion. In our work, we convert the input image into a gray-
scale image.
FILTERS:
In image processing, filters are mainly used to suppress the high frequencies in the
image. Median
Filter:
Bilateral filter:
IMAGE ENHANCEMENT:
Edge detection is a segmentation technique that uses border recognition of strictly linked
objects or regions. This technique identifies the discontinuity of the objects. This
technique is used mainly in image study and to recognize the parts of the image where a
huge variation in intensity arises.
SOBEL FILTER:
The Sobel filter is used for edge detection. It works by calculating the gradient of image
intensity at each pixel within the image. It is widely used in image analysis to help locate
edges in images. The Sobel operator is used for segment purposes. This technique can be
dependent on the central difference which tends toward the central pixels on average.
This technique can be expressed as 3 × 3 matrices to the first derivative of the Gaussian
kernel. It combines smoothing and differentiation. For Sobel edge detection the gradient
of the image is calculated for each pixel position in the image
Gx = [[-1 0 +1]
[-2 0 +2]
[-1 0 +1]]
Gy = [[-1 -2 -1]
[ 0 0 0]
[+1 +2 +1]]
2. At each point of the image we calculate an approximation of the gradient in that point
by combining both results above:
G=|Gx|+|Gy|
Department of CSE, CIT, GUBBI Page 21
Brain Tumor Detection using CNN 2021 - 2022
After the completion of the pre-processing, the image will be free from the noises, but we
still need to enhance the image since the obtained image is smoothened, edges may not
be preserved, and the image will be dull. To overcome all these, we used edge detection
called the Sobel filtering technique. The whole thing is done by calculating the gradient
of image intensities at each pixel within the image. It is widely used in image analysis to
help locate edges in images. It will also enhance the darker areas of the image, slightly
increase cont, fast, and as sharp as possible.
MORPHOLOGICAL OPERATIONS:
The Morphological techniques are also used with segmentation techniques. The
morphological action is normally performed on binary images. It processes the
operations based on shape and it has wide use in the image processing operation. Erosion
and Dilation are two methods of morphological operations used in this proposed work.
We perform both Erosion and dilation operations used together.
Two main steps of the erosion and dilation morphological operation are opening and
closing. The first step is the opening of the MRI binary image. The main work of the
opening operation is to open up that which is present in between objects and connect that
to a small collection of pixels. After the sett of the bridge, the erosion was again restored
to actual size using dilation. If the binary image has been opened then the subsequent
opened same structured elements have not affected that image. After completing the
opening operations next step is the closing operation. Based on the closing operation
while keeping the original region sizes, the erosion and dilation can handle different
holes in the image region. Dilation and Erosion are the basic morphological operations.
Dilation adds pixels to the boundaries of objects in an image, while erosion removes
pixels on object boundaries.
Classification is the best approach for the identification of images like any
kind of medical imaging. All classification algorithms are based on the prediction of the
image, where one or more features and that each of these features belongs to one of
several classes.
For this step, we need to import Keras and other packages that we’re going to
use in building the CNN. Import the following packages:
• Convolution2D is used to make the convolutional network that deals with the images.
• Flatten is the function that converts the pooled feature map to a single column that is
passed to the fully connected layer.
Department of CSE, CIT, GUBBI Page 23
Brain Tumor Detection using CNN 2021 - 2022
• Dense adds the fully connected layer to the neural network.
SEQUENTIAL:
CONVOLUTION:
• To add the convolution layer, we call the add function with the classifier object and
pass in Convolution2D with parameters. The first argument is feature_detectors which is
the number of feature detectors that we want to create. The second and third parameters
are dimensions of the feature detector matrix.
• We used 256 feature detectors for CNNs. The next parameter the is input shape which
is the shape of the input image. The images will be converted into this shape during pre-
processing. If the image is black and white it will be converted into a 2D array and if it is
colored it will be converted into a 3D array.
• In this case, we’ll assume that we are working colored images. Input_shape is passed
in a tuple with the number of channels, which is 3 for a colored image, and the
dimensions of the 2D array in each channel. If you are not using a GPU it’s advisable to
use lower dimensions to reduce the computation time. The final parameter is the
activation function. Classifying images is a nonlinear problem. So, we use the rectifier
function to ensure that we don’t have negative pixel values during computation. That’s
how we achieve non-linearity.
POOLING:
• The Pooling layer is responsible for reducing the spatial size of the convolved feature.
This is to decrease the computational power required to process the data through
dimensionality reduction. Furthermore, it is useful for extracting dominant features
which are rotational and positional invariant, thus maintaining the process of effectively
training the model.
• In this step we reduce the size of the feature map. Generally, we create a pool size of
2x2 for max pooling. This enables us to reduce the size of the feature map while not
losing important image information.
FLATTENING:
• In this step, all the pooled feature maps are taken and put into a single vector for
inputting the in-text layer.
• The Flatten function flattens all the feature maps into a single long column.
FULLY CONNECTION:
• The next step is to use the vector we obtained above as the input for the neural network
by using the Dense function in Keras. The first parameter is output which is the number
of nodes in the hidden layer. You can determine the most appropriate number through
experimentation. The higher the number of dimensions the more computing resources
you will need to fit the model. A common practice is to pick the number of nodes in
powers of two.
• The next layer we have to add is the output layer. In this case, we’ll use the sigmoid
activation function since we expect a binary outcome. If we expected more than two
outcomes, we would use the SoftMax function.
• The output here is 1 since we just expect the predicted probabilities of the classes.
Efficient Net-B3:
CHAPTER 6
MODEL TESTING
Testing of the model is conducted with the test data images to evaluate the trained
model's performance. Some of the test images and their prediction results are
demonstrated in the given table.
Table 6.1 Table comparing test results and the predicted result by our model.
CHAPTER 7
RESULTS
The model is trained for around 40 epochs during which the loss of the model
gradually decreases to a point where for any further epochs there won’t be any change in
the loss value. Likewise, the accuracy of the model, the accuracy the model increases
with the increasing number of epochs. The plot of this same is represented in figure 7.1
where the number of epochs is along the x-axis and the values of these accuracies and
losses over the corresponding epochs are along the y-axis.
Fig 7.1 Loss and Accuracy plot over the training period.
After training, the model is tested with the test images for which the classes are
predicted. Based on these predicted classes and the actual classes a confusion matrix is
drawn. From the above matrix, out of 139 Glioma tumor images 5, 1, and 1 were
incorrectly classified as Meningioma, Non-tumorous, and Pituitary tumor respectively.
Out of 141 Meningioma tumor images 4 and 2 images were incorrectly classified as
Glioma tumor and Pituitary tumor respectively. Out of 75 Non-tumor images 1 was
incorrectly classified as a Pituitary tumor and lastly out of 135 Pituitary images 1 was
misclassified as a Meningioma tumor. The remaining images in each of these classes
were correctly classified which can be seen diagonally with a dark blue shade in the
above figure.
CHAPTER 8
CONCLUSION
It is observed on extermination that the proposed approach needs a vast training set
for better accurate results, in the field of medical image processing, the gathering of
medical data is a tedious job, and, in a few cases, the datasets might not be available. In
all such cases, the proposed algorithm must be robust enough for accurate recognition of
tumor regions from MR Images. The proposed approach can be further improvised
through cooperating weakly trained algorithms that can identify the abnormalities with
minimum training data and also self-learning algorithms would aid in enhancing the
accuracy of the algorithm and reduce the computational time.
REFERENCES
[2] Asra Aslam, Ekram Khan, M.M. Sufyan Beg, Improved Edge Detection Algorithm
for Brain Tumor Segmentation, Procedia Computer Science, Volume 58,2015, Pp
430-437, ISSN 1877-0509.
[4] Devkota, B. & Alsadoon, Abeer & Prasad, P.W.C. & Singh, A.K. & Elchouemi, A..
(2018). Image Segmentation for Early Stage Brain Tumor Detection using Mathematical
Morphological Reconstruction. Procedia Computer Science. 125. 115- 123. 10.1016/
j.procs.2017.12.017.
[5] K. Sudharani, T. C. Sarma and K. Satya Rasad, "Intelligent Brain Tumor lesion
classification and identification from MRI images using the k-NN technique," 2015
International Conference on Control, Instrumentation, Communication and
Computational Technologies (ICCICCT), Kumaracoil, 2015, pp. 777-780. DOI: 10.1109/
ICCICCT.2015.7475384
[6] Kaur, Jaskirat & Agrawal, Sunil & Renu, Vig. (2012). A Comparative Analysis of
Thresholding and Edge Detection Segmentation Techniques. International Journal of
Computer Applications. vol. 39. pp. 29-34. 10.5120/4898-7432.
[7] Li, Shutao, JT-Y. Kwok, IW-H. Tsang and Yaonan Wang. "Fusing images with
different focuses using support vector machines." IEEE Transactions on neural networks
15, no. 6 (2004): 1555-1561.
[9] Mahmoud, Dalia & Mohamed, Eltaher. (2012). Brain Tumor Detection Using
Artificial Neural Networks. Journal of Science and Technology. 13. 31-39.
[10] Marroquin J.L., Vemuri B.C., Botello S., Calderon F. (2002) An Accurate and
Efficient Bayesian Method for Automatic Segmentation of Brain MRI. In: Heyden A.,
Sparr G., Nielsen M., Johansen P. (eds) Computer Vision — ECCV 2002. ECCV 2002.
Lecture Notes in Computer Science, vol 2353. Springer, Berlin, Heidelberg.
[11] Minz, Astina, and Chandrakant Mahobiya. “MR Image Classification Using
Adaboost for Brain Tumor Type.” 2017 IEEE 7th International Advance Computing
Conference (IACC) (2017): 701-705.
[12] Monica Subashini.M, Sarat Kumar Sahoo, “Brain MR Image Segmentation for
TumorDetection using Artificial Neural Networks,” International Journal of Engineering
and Technology (IJET), Vol.5, No 2, Apr-May 2013.
[13] S. Li, J.T. Kwok, I.W Tsang, and Y. Wang, ―Fusing Images with Different Focuses
using Support Vector Machines, Proceedings of the IEEE transaction on Neural
Networks, China, November 2007.
[14] H. Yu and J.L. Fan, ―Three-level Image Segmentation Based on Maximum Fuzzy
Partition Entropy of 2-D Histogram and Quantum Genetic Algorithm, Advanced
Intelligent Computing Theories, and Applications. With Aspects of Artificial Intelligence.
Lecture Notes in Computer Science, Berlin, Heidelberg 2008.
[15] P.S. Mukambika, K Uma Rani, “Segmentation and Classification of MRI Brain
Tumor,” International Research Journal of Engineering and Technology (IRJET), Vol.4,
Issue 7, 2017, pp. 683 – 688, ISSN: 2395-0056