Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/arezyhs/dicoding-machinelearning-finalproject-rockpaperscissor
This is my final project for the Machine Learning course at DICODING. This project detects your hand sign and returns the output, indicating whether it's a rock, paper, or scissors
https://github.com/arezyhs/dicoding-machinelearning-finalproject-rockpaperscissor
machine-learning python
Last synced: about 1 month ago
JSON representation
This is my final project for the Machine Learning course at DICODING. This project detects your hand sign and returns the output, indicating whether it's a rock, paper, or scissors
- Host: GitHub
- URL: https://github.com/arezyhs/dicoding-machinelearning-finalproject-rockpaperscissor
- Owner: arezyhs
- Created: 2023-06-04T11:03:45.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-12-31T11:50:01.000Z (about 1 year ago)
- Last Synced: 2023-12-31T12:29:16.868Z (about 1 year ago)
- Topics: machine-learning, python
- Language: Jupyter Notebook
- Homepage:
- Size: 218 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Rock, Paper, Scissors Classifier
Overview
This repository contains a program for training a Rock, Paper, Scissors image classifier using TensorFlow and Keras. The program utilizes a convolutional neural network (CNN) to classify images of rock, paper, and scissors gestures. The dataset used for training is obtained from the Dicoding Academy's Rock, Paper, Scissors dataset.
Prerequisites
Before running the program, ensure that you have the following dependencies installed:
- TensorFlow
- Keras
- Matplotlib
- Numpy
- Google Colab (if running on Google Colab)
Install the dependencies using the following command:
pip install tensorflow keras matplotlib numpy
Dataset
The dataset used in this project is available from the Dicoding Academy. It consists of images of rock, paper, and scissors gestures. The dataset is automatically downloaded and extracted during the execution of the program.
Data Augmentation
Data augmentation is applied during the training process to enhance the model's performance. Augmentation techniques include rotation, brightness adjustment, shear, zoom, and horizontal flip.
Model Architecture
The neural network model is built using the Sequential API of Keras. It consists of convolutional layers, max-pooling layers, a flattening layer, dropout for regularization, and fully connected layers. The output layer uses the softmax activation function to predict the class probabilities.
Training
The model is trained using the training dataset, and validation is performed on a subset of the dataset. The training process is monitored using callbacks, including a learning rate scheduler and a custom callback to stop training when both training and validation accuracy exceed a specified threshold.
Visualization
Training and validation accuracy, as well as loss, are visualized using Matplotlib to assess the model's performance over epochs.
Prediction
The trained model can make predictions on new images uploaded by the user. The user can upload an image, and the program will display the predicted class (rock, paper, or scissors) along with the confidence scores.
Usage
To run the program, execute the provided Python script in a compatible environment. If using Google Colab, ensure that the required libraries are installed and execute the script in a Colab notebook.
python rock_paper_scissors_classifier.py
Acknowledgments
- Dicoding Academy for providing the Rock, Paper, Scissors dataset.
- TensorFlow and Keras communities for their powerful tools and resources.
Feel free to contribute, report issues, or suggest improvements to enhance the classifier!