Deep Learning-Driven MRI Image Segmentation and Classification for Brain Tumors Using RF, SVM, YOLOv5, and U-Net Architectures
Deep Learning-Driven MRI Image Segmentation and Classification for Brain Tumors Using RF, SVM, YOLOv5, and U-Net Architectures
Abstract: This work uses deep learning and machine learning approaches to identify and categorize brain cancers from
MRI scans. U-Net is utilized for precise tumor segmentation, YOLOv5 is employed for real-time detection, and Random
Forest (RF) and Support Vector Machines (SVM) are employed for tumor type classification. In order to assist doctors, in
diagnosing brain tumors more rapidly, the system aims to automate segmentation, detection, and classification, improve
diagnosis accuracy, and reduce analysis time. By developing early intervention strategies for brain tumor treatment, this
study enhances patient care.
Keywords: Brain Tumor Detection, MRI Image Segmentation, U-Net Architecture,YOLOv5,Random Forest (RF), Support Vector
Machine (SVM),Deep Learning, Tumor Classification, Medical Imaging, Real-Time Detection, Image Preprocessing, Artificial
Intelligence in Healthcare, Neural Networks, Oncology Diagnostics, Machine Learning
How to Cite: Uppalapati Harshitha; Vallamkondu Bhuvitha; Dr. Poornima (2025) Deep Learning-Driven MRI Image
Segmentation and Classification for Brain Tumors Using RF, SVM, YOLOv5, and U-Net Architectures. International Journal of
Innovative Science and Research Technology, 10(2), 1478-1483. https://doi.org/10.5281/zenodo.14964479
The project's integration of these cutting-edge combines segmentation, detection, and classification into a
technology improves diagnostic precision while unified framework, as most current systems only
streamlining medical procedures and facilitating quicker concentrate on one or two areas (such as segmentation or
decision-making in urgent situations. The technology is classification).
made to give medical professionals an easy-to-use,
interactive platform where they can upload, analyze, and III. EXISTING SYSTEM
interpret MRI pictures and receive comprehensive results.
By promoting early diagnosis and accurate classification of Current methods for diagnosing brain tumors mostly
brain tumors, this method not only lessens the workload for depend on radiologists manually interpreting MRI data. This
radiologists but also improves patient care and results. procedure takes a long time and is prone to human mistake
and differences in competence. Although CAD systems
II. RELATED WORK have been created to help radiologists, many of them rely on
antiquated image processing methods that aren't as flexible
Significant progress has been made in recent years in and adaptable as contemporary machine learning and deep
the application of machine learning and deep learning learning techniques. In complex or noisy datasets, these
techniques in medical imaging, Because U-Net topologies systems frequently have trouble correctly segmenting
can effectively capture spatial and contextual information, tumors, which can result in inaccurate diagnosis and
studies have demonstrated its efficacy for medical picture postpone treatment planning.
segmentation. Even with little training data, U-Net has been
utilized extensively for tumor segmentation in MRI scans, Even though models for tumor segmentation, detection,
yielding incredibly precise results. Its effectiveness in and classification have been presented by machine learning
defining tumor boundaries has been shown in a number of advances, the majority of current systems tend to
research studies, which is crucial for subsequent processes concentrate on discrete tasks rather than offering a
including categorization and treatment planning. Real-time comprehensive solution. Segmentation models such as U-
segmentation and managing intricate tumor forms in various Net, for instance, may function well but are not connected to
datasets are still difficult tasks, nevertheless classification systems, necessitating extra manual
preprocessing procedures. Similar to this, object detection
In medical imaging, object detection frameworks like frameworks such as YOLO have just lately been
YOLO (You Only Look Once) have become effective tools investigated, there is still little use of them in brain MRI
for real-time tumor detection. YOLOv5, in particular, is studies. Therefore, inefficiencies result from the absence of
perfect for identifying anomalies in MRI scans because it a single system that combines segmentation, detection, and
has shown notable gains in speed and accuracy over its classification in a seamless manner, impeding the possibility
predecessors. Studies incorporating YOLO-based of real-time diagnostics and thorough analysis.
frameworks have demonstrated encouraging outcomes in
terms of quickly locating tumors, cutting down on IV. PROPOSED METHODOLOGY
diagnostic time in clinical settings. Despite its benefits,
YOLO is still a relatively new use in medical imaging, and By combining cutting-edge machine learning and deep
efforts are still being made to maximize its performance for learning models, the suggested approach develops a single
medical use cases. system for MRI-based brain tumor diagnostics. For accurate
tumor segmentation and exact tumor region detection, U-
Apart from segmentation and detection, one crucial Net will be utilized. To ensure effective processing and
activity that has benefited from machine learning techniques display of the MRI data, YOLOv5 will be utilized for real-
like (RF) and (SVM) is tumor classification. The capacity time tumor location detection. Using (RF) and (SVM), the
of these algorithms to categorize tumors using tumors will be categorized as either benign or malignant
characteristics taken from segmented pictures has been based on attributes that were taken from the segmented
thoroughly investigated. In clinical applications, RF and pictures. Pre-processing methods intensity normalization,
SVM are especially prized for their interpretability and and data augmentation will be used by the system to
robustness. Recent studies demonstrate how these improve model performance. By integrating segmentation,
conventional machine learning models can be combined detection, and classification into a single pipeline, the
with deep learning frameworks to provide a comprehensive suggested methodology seeks to produce an output that is
diagnostic system. The goal of an integrated strategy that accurate, dependable, and quick.
V. ARCHITECTURE DIAGRAM
using U-Net, a deep learning network designed specifically tumor type categorization are all made possible by the
for picture segmentation challenges. The (CNN) model U- system.
Net is particularly for biological image segmentation due to
its pulls hierarchical information from the context of the Assessment and Performance Indicators
image, whereas the decoder allows for the precise To guarantee the system's efficacy, a thorough
localization of features, such as tumor boundaries. After performance evaluation is conducted at the end. To evaluate
being trained on preprocessed MRI images, the U-Net the accuracy of the tumor segmentation process, one of the
model learns to properly split the tumor areas and generate most important metrics Coefficient (DSC), which calculates
binary masks that identify the exact location of the tumor in the degree of similarity between the and the YOLOv5's
the scan. Because it forms the foundation for subsequent object recognition performance is assessed using (IoU),
processing and analysis, this segmentation is crucial. which compares bounding boxes. among the performance
measures used in classification to assess the system's ability
Finding Tumors with YOLOv5 to distinguish between benign and malignant tumors. Cross-
YOLOv5 (You Only Look Once, version 5), a well- validation methods such as are make sure the models are
known real-time object identification system, is used to reliable and generalizable across a range of datasets.
detect tumors after the segmentation stage. YOLOv5 is well-
known for its speedy and precise object detection in pictures, VII. TOOLS AND TECHNOLOGIES
which makes it perfect for locating malignancies in MRI
scans. The YOLOv5 model is fed the segmented tumor Languages Used in Programming
regions that were extracted using U-Net. The bounding Python: This project's core programming language,
boxes surrounding the tumors are then predicted by Python, forms the basis for practically all development
YOLOv5, which also provides the prediction's confidence activities, from data processing to the application of
level and the tumor location coordinates. For medical machine learning methods. Python is preferred for data
applications where speed is crucial for prompt diagnosis and science, machine learning, and image processing jobs
treatment, this real-time detection capacity is indispensable. because to its ease of use and abundance of libraries and
frameworks. The success of this project depends on Python's
Tumor Classification and Feature Extraction capacity to handle big datasets, carry out intricate
Once the tumor has been identified, it is classified as mathematical operations, and interface with deep learning
either benign or malignant. To do this, feature extraction is models with ease. Python is the foundation of libraries like
used to the segmented tumor regions. Numerous TensorFlow, PyTorch, scikit-learn, OpenCV, and
characteristics, such as the tumor's size, shape, texture, and SimpleITK. Python is a popular language in the field of
intensity, are extracted from the MRI scans. These qualities artificial intelligence, especially in medical image analysis,
are crucial in distinguishing between benign and malignant due to its adaptability and simplicity of integration.
tumors since different tumor characteristics may indicate
different forms of growth and aggressiveness. For the Frameworks for Deep Learning
categorization challenge, conventional machine learning One of the most popular deep learning frameworks is
models are employed, specifically Random Forest (RF) and TensorFlow, which was created by Google. Deep learning
Support Vector Machine (SVM). Random Forest is an models like U-Net, which is especially made for medical
ensemble learning technique that generates several decision picture segmentation tasks, are created and trained in this
trees and combines their output to obtain a final project using TensorFlow. Large datasets and sophisticated
classification result, offering high accuracy and resilience models may be handled with TensorFlow's robust GPU
against overfitting. SVM, on the other hand, is a supervised support and scalability, which is crucial when working with
learning method. that builds the optimal hyperplane for high-resolution MRI images. Rapid model testing,
dividing different tumor types using the data that was debugging, and prototyping are made possible by the
recovered. framework's versatility and extensive toolkit, which includes
its Keras API. TensorFlow is essential to the project's
Combination and Production of Output success because it can be used for segmentation tasks as
Integrating the various elements—segmentation, well as model optimization, deployment, and the
detection, and classification—into a coherent pipeline forms development of effective inference pipelines. Another
the basis of this methodology. Through this integration, an popular deep learning framework used in this project is
end-to-end system is made possible that uses raw MRI PyTorch, which is praised for its user-friendliness and
images as input, processes them using the U-Net dynamic computational graph. Because of its versatility and
segmentation model, uses YOLOv5 to locate tumors, and user-friendly architecture, PyTorch is particularly useful for
then uses RF or SVM models to classify the type of tumor. research and experimentation, facilitating faster model
A binary mask representing the segmented tumor, bounding building and iteration. In this project, YOLOv5, a cutting-
boxes showing the tumor sites, and a classification label edge model for real-time object identification, is developed
(Benign or Malignant) are among the pipeline's main using PyTorch. Tumor detection speed and accuracy are
outputs. Following that, the findings are shown on an increased by PyTorch's support for efficient GPU use, and
interactive dashboard that gives medical experts a thorough the YOLOv5 model is particularly well-suited for MRI scan
overview of the investigation. Easy MRI picture uploading, tumor detection. PyTorch is perfect for tasks needing
segmented tumor region viewing, tumor detection, and
dynamic modifications to the model architecture or hyper Utilizing GPUs and Cloud Computing
parameters due to its versatility. Google Colab is a cloud-based online environment that
offers free GPU and TPU (Tensor Processing Unit) access
Libraries for Image Processing for deep learning applications. Colab's GPU support is
OpenCV: An indispensable tool for image processing essential for speeding up the training process because deep
tasks is OpenCV (Open Source Computer Vision Library). It learning model training, particularly for convolutional
is frequently used for tasks like picture processing, feature networks like U-Net and YOLOv5, needs a large amount of
extraction, and enhancement. The preprocessing of MRI processing power. Colab is user-friendly, effortlessly
pictures in this research, which includes filtering, scaling, connects with Google Drive for file storage, and enables
and converting the images into formats appropriate for deep remote project execution, offering flexibility for model
learning models, is largely handled by OpenCV. Because building and experimentation. It is an excellent tool for
MRI pictures frequently contain noise and irregularities, rapidly prototyping models and training them without
preprocessing is an essential step in medical image analysis. requiring a powerful local computer because of its
In order to make the images more uniform and clear for simplicity of use and capacity to leverage sophisticated
model input, OpenCV assists in using techniques like hardware.
histogram equalization for contrast improvement and
Gaussian blur for noise reduction. Tools for Collaboration and Version Control
GitHub and Git: Git is a version control system for
For managing medical image formats such as DICOM handling modifications to the documentation and source
(Digital Imaging and Communications in Medicine) and code of a project. Git keeps track of code changes, making it
NIfTI (Neuroimaging Informatics Technology Initiative), possible to access earlier iterations of the code as needed.
SimpleITK is an additional essential library. MRI data is The project's code repository is hosted on GitHub, which
frequently stored in several formats, and SimpleITK offers a offers a centralized area for team members to work together,
smooth method for loading, processing, and modifying these exchange code, and add to the project. GitHub is a great
pictures. In order to improve picture features for platform for team coordination because of its collaborative
segmentation and classification applications, SimpleITK capabilities, which let several developers work on the
offers a variety of filters and transformations, including project at once without interfering with one another. These
morphological transformations and intensity rescaling. features include branching, pull requests, and issue tracking.
Additionally, it guarantees thorough documentation of the
Libraries for Machine Learning entire development process, which enhances the project's
In order to create common machine learning models scalability and maintainability.
like Support Vector Machine (SVM) and Random Forest
(RF), this project uses scikit-learn, a robust and flexible Web-Based Deployment Framework
Python machine learning toolbox. These models use Flask: The project's backend API is created using Flask,
information taken from the segmented tumor sections to a lightweight Python web framework. It provides the
classify MRI scans into groups like benign or malignant framework for creating the web application that enables
tumors. Scikit-learn offers an extensive collection of tools interaction between the deep learning models and medical
for training models, cross-validation, and performance practitioners. Users can inspect the segmented tumor regions,
evaluation. The use of traditional machine learning upload MRI scans, and get real-time categorization results.
techniques for tumor classification is made easier by Scikit- Flask's simplicity, adaptability, and ease of integration with
learn's intuitive interface and effective machine learning Python-based machine learning models make it the perfect
algorithm implementation. choice for this project. While the framework's versatility
guarantees that further features and functionalities.
Tools for Regularization and Data Augmentation
The high-performance data augmentation package VIII. RESULTS
Albumentations is essential for boosting the resilience of
deep learning models, particularly when dealing with sparse The Deep Learning-Driven MRI Image Segmentation
medical image datasets. Rotations, flipping, scaling, and and Classification for Brain cancers research showed how to
cropping are just a few of the many transformations that are automate the analysis of brain cancers from MRI images by
applied to the MRI pictures in this project using utilizing sophisticated deep learning algorithms. The U-Net
Albumentations. By artificially expanding the dataset, these segmentation design successfully separated various brain
augmentations help the models avoid overfitting and tumor forms, including gliomas and meningiomas, with a
improve generalization. By adding a variety of variations to high Dice Similarity Coefficient (DSC), typically exceeding
the input data, the model can adapt better to new, unseen 85%. With a mean average precision (mAP) of 90%, the
images and become more resilient to changes. YOLOv5 model demonstrated remarkable performance in
tumor detection, allowing for quick tumor localization with
an average inference time of only 1-2 seconds per image.
SVM and Random Forest (RF) were used to classify tumors,
with 92% and 89% accuracy rates, respectively.