Skip to content

Brain Tumor Detection using CNN: Achieving 96% Accuracy with TensorFlow: Highlights the main focus of your project, which is brain tumor detection using a Convolutional Neural Network (CNN) implemented in TensorFlow. It also emphasizes the impressive achievement of reaching 96% accuracy, which showcases the effectiveness of your model.

Notifications You must be signed in to change notification settings

Vidhi1290/Brain-Tumor-Detection

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

Brain Tumor Detection using CNN: Achieving 96% Accuracy with TensorFlow😎🔐

Experience the power of deep learning with our Kaggle repository! We present a comprehensive implementation of a brain tumor detection model using Convolutional Neural Networks (CNNs) in TensorFlow. Achieving an impressive accuracy of 96%, our code showcases the following steps:🔥🧠

1. Importing Essential Libraries: ✅

Start by importing necessary libraries for data manipulation, visualization, and model construction with TensorFlow.

2. Setting Up Dataset Paths and Directories: ✅

Define the dataset path and training/testing directories, and establish the categories for brain tumor types.

3. Loading and Preprocessing the Dataset: ✅

Read images from each category in the training directory, create a DataFrame to store image data, and visualize the distribution of tumor types.

4. Visualizing Images for Each Tumor Type: ✅

Display sample images for each tumor type in a grid of subplots.

5. Setting Image Size, Batch Size, and Epochs: ✅

Define image dimensions, batch size for training, and the number of training epochs.

6. Data Augmentation and Preprocessing: ✅

Augment the training dataset to improve model generalization using techniques like rotation, shifting, zooming, etc.

7. Building the Model Architecture: ✅

Construct a CNN model with convolutional, max pooling, dense, and dropout layers. Compile the model using the Adam optimizer and categorical cross-entropy loss.

8. Training and Validation: ✅

Train the model using the training generator, tracking accuracy and loss over epochs. Validate on the test generator as well.

9. Visualization Through Graphs: ✅

Plot training and validation accuracy/loss curves over epochs to monitor the model's learning progress.

10. Evaluation: ✅

Evaluate the model's performance on the test dataset, calculating test loss and accuracy.

11. Confusion Matrix and Explanation: ✅

Visualize a confusion matrix to analyze the model's classification performance for each class. Display sample images along with their predicted and true labels.

12. Precision, Recall, and F1-Score Calculation: ✅

Calculate precision, recall, and F1-score for each class from the confusion matrix.

13. Saving the Trained Model: ✅

Save the trained model to a file for future use or deployment.

Unlock the potential of CNNs for brain tumor detection through our meticulous implementation, demonstrating the remarkable capabilities of deep learning in the medical field. Detect with confidence, predict with precision! 🧠🔍🤖

About

Brain Tumor Detection using CNN: Achieving 96% Accuracy with TensorFlow: Highlights the main focus of your project, which is brain tumor detection using a Convolutional Neural Network (CNN) implemented in TensorFlow. It also emphasizes the impressive achievement of reaching 96% accuracy, which showcases the effectiveness of your model.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published