Report With Pg
Report With Pg
CHAPTER 1
INTRODUCTION
Brain tumors are a significant health concern worldwide, often requiring timely diagnosis and
intervention to improve patient outcomes. The accurate and early detection of brain tumors is
crucial for effective treatment planning and prognosis. In recent years, deep learning techniques
have emerged as powerful tools for automated medical image analysis, offering the potential to
enhance the efficiency and accuracy of brain tumor detection.
Among various deep learning architectures, MobileNet has gained prominence due to its
efficiency in resource-constrained environments. Making it suitable for real-time analysis of
medical images using readily available hardware, such as smartphones and tablets. Leveraging
the capabilities of Mobile Net for brain tumor detection can potentially enable prompt and
accessible diagnoses, particularly in remote or low-resource healthcare settings.
In this Report, we present a comprehensive study on brain tumor detection using the Mobile Net
model. Our objective is to develop a system that combines the computational efficiency of
Mobile Net with the accuracy required for effective brain tumor identification. By employing
deep learning techniques, our research aims to address the challenges associated with manual
interpretation and the potential for human error in brain tumor detection.
1.1 HISTORY
Brain tumors are abnormal growths of cells in the brain that can cause various neurological
symptoms and potentially life-threatening conditions. Early detection and accurate diagnosis of
brain tumors are crucial for effective treatment planning and improving patient outcomes.
Traditional methods of brain tumor detection involve manual examination of MRI scans by
radiologists, which can be time-consuming and subject to human error.
In recent years, deep learning techniques have revolutionized the field of medical
imaging analysis, offering promising solutions for automated tumor detection and classification.
Convolutional Neural Networks (CNNs), a type of deep learning model, have shown remarkable
performance in various image classification tasks, including medical image analysis.
1.3 OBJECTIVES
The objectives of this study on brain tumor detection using the MobileNet architecture are as
follows:
• Develop an automated system: Design and implement a web application that utilizes deep
learning techniques and the MobileNet architecture for automated brain tumor detection in MRI
scans. The application should be capable of accurately analyzing the scans and providing reliable
tumor detection results.
• Improve diagnostic accuracy: Enhance the accuracy of brain tumor detection by leveraging
the power of deep learning algorithms. Train the MobileNet model on a large dataset of MRI
scans to learn and recognize the specific features and patterns associated with brain tumors.
• Reduce analysis time: Reduce the time required for brain tumor analysis by automating the
detection process. The developed system should efficiently analyze MRI scans and provide
timely results, enabling medical professionals to make faster and more informed diagnostic
decisions.
CHAPTER 2
LITERATURE SURVEY
Dr. Chinta Someswararao [1], paper titled “Brain Tumor Detection Model from MR
Images using Convolutional Neural Network“was a combination of CNN model classification
problem for predicting whether the subject has brain tumor or not & Computer Vision problem
for automate the process of brain cropping from MRI scans. The final accuracy achieved by him
is much higher than 50% baseline (random guess). However, it could further be increased by
larger number of train images or through different models and techniques.
Masoumeh Siar and Mohammad Teshnehlab [2], paper titled “Brain Tumor
Detection Using Deep Neural Network and Machine Learning Algorithm” used the
combination of feature extraction algorithm and the CNN for tumor detection from brain images
is presented. The CNN is capable of detecting a tumor. The CNN is very useful for selecting an
auto-feature in medical images. Images collected at the centers were labeled by clinicians, then,
tumor screenings were categorized into two normal and patient classes.
Devkota et al. [3] established the whole segmentation process based on Mathematical
Morphological Operations and spatial FCM algorithm which improves the computation
time, but the proposed solution has not been tested up to the evaluation stage and outcomes as-
Detects cancer with 92% and classifier has an accuracy of 86.6%.
Khurram Shahzad and Imran Siddique [4], paper titled “Efficient Brain Tumor
Detection Using Image Processing Techniques “focused on an easy, fully automatic and
efficient algorithm for extraction of brain tumor has been introduced. Morphological operation
like erosion and dilation along with morphological gradient and threshold are used.
Morphological gradient is used for calculating threshold. Threshold is used to binarize the image
which results an image having tumor and some noise with it. Erosion is used for thinning the
image as it shrinks the image and helps to reduce noise or unwanted small objects. Dilation is
being used after erosion so that to get removed tumor portion back which was being removed by
erosion.
Badran et al. [5] adopted the canny edge detection model accumulated with Adaptive
thresholding to extract the ROI. The dataset contained 102 images. Images were first
preprocessed, then for two sets of a neural network, for the first set canny edge detection was
applied, and for the second set, adaptive thresholding was applied.
Pei et al. [6] proposed a technique which utilizes tumor growth patterns as novel
features to improve texture based tumor segmentation in longitudinal MRI. Label maps are
being used to obtain tumor growth modeling and predict cell density after extracting textures
(e.g., fractal, and mm) and intensity features.
CHAPTER 3
SYSTEM REQUIREMENT SPECIFICATION
Software requirements for the implementation and testing of this project are mentioned as below.
• Visual Studio Code: For this project, Visual Studio Code is a lightweight but powerful source
code editor which runs on your desktop and is available for Windows, macOS and Linux. It
comes with built-in support for JavaScript, Typescript and Node.js and has a rich ecosystem of
extensions for other languages and runtimes (such as C++, C#, Java, Python, PHP, Go, .NET).
• TensorFlow: The brain tumor detection use TensorFlow for model training and inference with
the MobileNet architecture. These frameworks offer a wide range of tools and utilities for
building, training, and deploying deep learning models efficiently.
• Keras: Keras is a high-level deep learning library that provides a user-friendly interface for
building and training neural networks. It can be used in conjunction with TensorFlow or other
backend frameworks to facilitate the implementation of the MobileNet architecture and
streamline the training process.
CHAPTER 4
SYSTEM DESIGN
Transfer learning is a machine learning method that uses previously trained model. So, we have
used a pre-trained CNN architecture called mobile net which is open sourced by google. Mobile
Net uses depth wise separable convolutions to build a light weight deep neural networks and
provides an efficient model. This architecture allows the mobile net to detect and classify brain
tumor efficiently while maintaining a high-level accuracy. Here is an explanation of the key
components and features of MobileNetV2:
• Depth wise Separable Convolution: MobileNetV2 extensively employs depth wise separable
convolutions. In a traditional convolutional layer, the convolution operation is applied to all
input channels, resulting in a high computational cost. In depth wise separable convolutions, the
operation is split into two separate steps: depth wise convolution and point wise convolution.
Depth wise convolution applies a single filter to each input channel independently, reducing the
number of parameters and computation. Point wise convolution then applies a 1x1 convolution
to combine the outputs of the depth wise convolution. This factorization significantly reduces
model size and computational complexity.
• Inverted Residuals: MobileNetV2 introduces a new building block called the inverted residual
block, which aims to capture both low-level and high-level features efficiently. The inverted
residual block consists of three main components: a 1x1 pointwise convolution to expand the
number of channels, a depth wise separable convolution to capture spatial information, and
another 1x1 pointwise convolution to reduce the number of channels back to the desired output
size.
• Inverted Residual with Expansion Layer: MobileNetV2 introduces an expansion layer in the
inverted residual block to increase the capacity of the network without significantly increasing
the number of parameters. The expansion layer applies a 1x1 point wise convolution to expand
the number of channels before the subsequent depth wise separable convolution. This expansion
layer allows the network to learn more complex representations while maintaining efficiency.
4.2 METHODOLOGY
The methodology outlined below provides a general framework for conducting the study on
brain tumor detection using the MobileNet architecture.
Data Collection: The dataset used for training and validation was collected from the Kaggle. It
contains brain MRI Image’s in which some of them containing tumor (with tumor) and some are
normal (without tumor). In which tumor images are segregated in the folder name “Brain tumor”
with 1500 images and normal images are kept in “healthy” with 1500 images . In this study thus
we have used 3000 Images out of these images 1500 images are with tumor and 1500 images
are without tumors. For testing we have used 256 Images. Fig 3(a) and Fig 3(b) illustrate the
sample brain MRI images with and without brain tumors respectively .
• Model Architecture: Implement the MobileNet architecture using a deep learning framework
such as TensorFlow. Customized the output layer(s) of the MobileNet model to correspond to
the brain tumor detection task.
• Training Setup: Split the preprocessed dataset into training and validation sets using a
predefined split ratio. Set up the training parameters, such as batch size "32" number of epochs
"10", and optimizer "Adam", to train the MobileNet model.
• Model Training: Trained the MobileNet model using the training set. During training, feed
batches of preprocessed images through the model, compute the loss using an appropriate loss
function "binary cross-entropy" and backpropagate the gradients to update the model's weights.
• Model Evaluation: Evaluate the trained MobileNet model on the validation set. To Compute
evaluation metrics such as accuracy to assess the model's performance in detecting brain tumors.
CHAPTER 5
SYSTEM IMPLEMENTATION
5.3 PRE-PROCESSING:
Preprocessing steps are applied to the MRI images before feeding them into the
model. These steps may include resizing the images to a consistent resolution, normalization,
and converting the images into the appropriate format compatible with the chosen deep learning
framework. The image size is set to 224X224.
5.5 FINE-TUNING:
In addition to transfer learning, fine-tuning can be performed by freezing some
initial layers of the MobileNet model while allowing the subsequent layers to be fine-tuned using
the brain tumor dataset. This approach enables the model to adapt to the specific characteristics
of brain tumor images while leveraging the learned features from the pre-trained model.
Step 1: Start
Step 2: Prepare Dataset (Healthy / Unhealthy)
Step 3: Preprocessing
Target Size (224,224)
Step 4: Train MobileNet Model
Step 5: Input image from PC
Step 6: Preprocessing
Target Size (224,224)
Step 7: Test model
Step 8: If result <= 0.5:
Result = “the person has no brain tumor”
Else:
Result = “the person has brain tumor”
CHAPTER6
RESULTS AND DISCUSSIONS
The result forms the most important part of the project. This section provides the outcomes of
the project.
6.1 TRAINING & VALIDATION ACCURACY AND LOSS
Table 2 shows the comparison on training and validation accuracy from 0.1 to 0.3 based on
Validation split.
• Accuracy:
The accuracy of the brain tumor detection system was found to be 94.86%. This indicates
the overall percentage of correctly classified tumor and non-tumor regions. A high accuracy
suggests that the model is effectively identifying the presence or absence of tumors.
Accuracy is calculated by:
Accuracy = (True positive + True Negative) / Total no of images
Accuracy = (97+144) / 253
Accuracy = 241/ 253 = 95.25 %.
• Precision:
The precision of the system was calculated as 95.25%. This metric measures the
Proportion of correctly predicted tumor regions out of all predicted tumor regions. A high
precision indicates a low number of false positives, meaning the system is correctly identifying
tumor regions and minimizing the risk of misdiagnosis.
• Recall:
The recall, also known as sensitivity or true positive rate, was determined to be 94.86%.
This metric measures the proportion of correctly predicted tumor regions out of all actual tumor
regions. A high recall indicates that the system is effectively detecting true positive tumor
regions and minimizing false negatives.
• F1 Score:
The F1 score, which is the harmonic mean of precision and recall, was calculated as 94%.
This metric provides a balanced measure of the model's accuracy, taking into account both false
positives and false negatives. A high F1 score indicates a well-performing system with a good
balance between precision and recall.
Overall, the results from the confusion matrix analysis support the effectiveness of
the brain tumor detection system using MobileNet. The system demonstrates promising
performance metrics, but further research and improvements may be necessary to enhance its
robustness and generalizability to real-world scenarios.
Table 3 shows the comparison of Performance metrics for various split ratios ranging from 0.1
to 0.3.Split ratio is nothing but number of images used for validation to total images used for
both training and validation .
6.3 SNAPSHOTS
CHAPTER 7
CONCLUSION
In this project work, we presented a comprehensive study on brain tumor detection using the
Mobile Net model. It is aimed to develop an efficient and accurate solution for detecting brain
tumors. Through dataset acquisition, preprocessing, model training, and evaluation, the
effectiveness of the Mobile Net model is accurately demonstrated by identifying brain tumors
from medical images( MRI).
Expanding the dataset with a larger and more diverse sample can enhance the generalizability of
the Mobile Net model. Additionally, exploring transfer learning techniques, incorporating
clinical data, and investigating multi-modal fusion could further enhance the model's
performance and contribute to personalized medicine in brain tumor diagnosis and treatment.
CHAPTER 8
FUTURE SCOPE
The project aimed to develop an efficient and accurate solution for detecting brain tumors.
Through dataset acquisition, preprocessing, model training, and evaluation, we demonstrated the
effectiveness of the Mobile Net model in accurately identifying brain tumors from medical
images.
Integrating the brain tumor detection system with decision support systems can assist healthcare
professionals by providing additional information and recommendations. For example, the
system can provide information on tumor characteristics, growth patterns, and treatment options,
aiding in the decision-making process.
CHAPTER 9
REFERENCES
[1] Dr. Chinta Someswara rao “Brain Tumor Detection Model from MR Images using
Convolutional Neural Network” IEE May [June 2020]
[2] Masoumeh Siar “Brain Tumor Detection Using Deep Neural Network and Machine Learning
Algorithm” International Conference on Computer and Knowledge Engineering [October 2019]
[3] B. Devkota, Abeer Alsa doon, P.W.C. Prasad, A. K. Singh, A. Elchouemi, “Image
Segmentation for Early-Stage Brain Tumor Detection using Mathematical Morphological
Reconstruction,” 6th International Conference on Smart Computing and Communications,
ICSCC 2019, 7-8 December 2019, Kurukshetra, India.
[4] Khurram Shahzad and Imran Siddique “Efficient Brain Tumor Detection Using Image
Processing Techniques “International Journal of Scientific & Engineering Research [December
2019]
[5] Ehab F. Badran, Esraa Galal Mahmoud, Nadder Hamdy, “An Algorithm for Detecting Brain
Tumors in MRI Images”, 7th International Conference on Cloud Computing, Data Science &
Engineering - Confluence, 2020.
[6]Pei L, Reza SMS, Li W, Davit zikrs C, Iftekhar Uddin KM. “Improved brain tumor
segmentation by utilizing tumor growth model in longitudinal brain MRI”. Proc SPIE Int Soc
Opt Eng. 2021.
[7] A. Rajendran, R. Dhanasekaran, “Fuzzy Clustering and Deformable Model for Tumor
Segmentation on MRI Brain Image: A Combined Approach,” International Conference on
Communication Technology and System Design 2020.
[8]Aryan Sagar Methyl “Brain Tumor Detection using Deep Learning and Image Processing
“IEEE [June 2021]