Coder Social home page Coder Social logo

brain-tumor-detection's Introduction

CS615: Final Project - Brain Tumor Detection with Multi-Class MLPs and CNNs

Kenneth Pan [email protected]
Amira Bendjama [email protected]
Ramona Rubalcava: [email protected]
Hung Do [email protected]


Code Usage:

This code was created to satisfy the work necessary for CS615 Final Project

Data:

The data used in this project was retrieved from Kaggle at this link:
https://www.kaggle.com/datasets/masoudnickparvar/brain-tumor-mri-dataset

Due to the size of the dataset, the dataset was unable to be attached to this submission. To recreate the folder structure of the dataset used for training and testing:

  1. Download the data from Kaggle
  2. Unzip from the archive folder
  3. Place the unzipped folders Training and Testing in a new folder named full
  4. Place this folder in the same directory as the Preprocessing.py script
  5. Run the Preprocessing.py script
  6. Verify that the dataset results in trainingfull.csv, trainingfull_labels.csv, testingfull.csv, testingfull_labels.csv

Folder structure:

The file strucutre is as follows:

Final_submission
├── Preprocessing.py - the script used to resize the images in the brain tumor MRI dataset
├── layers.py - the layers file used for construction of the MLP and CNN architectures
├── MLP.ipynb - the noteboook used to run the MLP network and generate graphs
├── CNN.py - the script used to train and validate the CNN architecture
└── CNN-2.py - the script used to train and validate the CNN architecture with 2 convolutional layers

Folder also includes images of the loss function and confusion matrix for both MLP and CNN

Running the code:

The only packages necessary for running the scripts are below:

pip install pandas
pip install numpy
pip install matplotlib
pip install cv2
pip install imutils
pip install tqdm

To recreate the results of MLP, make sure the notebook is in the same file location as the pre-processed data files. Then run all the cells of the notebook.

To recreate the results of the CNN, make sure the cnnp.py is in the same file lcoation as the pre-processed data files. Then run the .py file.


brain-tumor-detection's People

Contributors

donguyenhung avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.