The training data set is the same for every team in this course.
You can download the data in our Canvas page:
- train.ipynb - Jupyter notebook with code including all preprocessing, GridSearch CV, and then training on final model and saving the model as "Final_CNN".
For preprocessing we tried many cv2 functions such as MORPH_OPEN, CLOSE, GRADIENT, Blurs but finally we used only medianblur and Morph_Open.
- Final_CNN - This is our saved CNN model after training on all data_train.npy images with best parameters achieved through GridSearch CV.
After saving the model we can use it in easy_test and hard_test files to test on new data.
- easy_test.ipynb - Jupyter notebook used to classify the images and test the accuracy of Easy Test Dataset.
- Final_Report.docx - Report of our project
- new_labels_train.npy - Corrected labels file of traing data
- data.npy - temporary data of 400 images to test our data, just to check if the code is working fine, any data with proper dimensions mentioned below can be used.
- labels.npy - labels for above data.npy
In this section you should provide instructions on how to use this repository to recreate your project locally.
- You can use 'git clone' to clone this repository (Project link is given below)
- Just change the np.load() and load your own data with dimension(90000,N)
- For training use can use data from the links given above.
- Tensorflow 2.6 (pip install tensorflow==2.6)
- OpenCV 4.5.2 (pip install opencv-python)
- Seaborn (pip install seaborn)
- Sklearn (pip install sklearn)
- sckit-learn (pip install -U scikit-learn)
- keras (pip install keras)
- numpy (pip install numpy)
- matplotlib (pip install matplotlib)
- pandas (pip install pandas)
- All packages mentioned above should be installed before runnning any code file.
- You just have to change np.load() in the first cell and load your own data
- Dimension of data.npy file should be (90000,N), where N is number of images or samples and Labels.npy dimensions should be (N)
- Now, run all the cells in Easy_Test and Hard_Test and you will see that Confusion Matrix and Accuracy in the last 3 cells. For more examples, please refer to the Documentation
Rajat Bishnoi - [email protected] James Overmeyer - [email protected] Cody Hutcheson - [email protected]
Project Link: https://github.com/EEL5840-EEE4773-Spring2022/final-project-code-and-report-machine_learners
- Catia Silva
- GitHub
- Stackoverflow
- Medium.com
- towardsdatascience.com
- tensorflow.org