{"id":28272690,"url":"https://github.com/akhdandann/rockpaperscissors-imageclassification","last_synced_at":"2026-04-13T22:31:51.988Z","repository":{"id":293180957,"uuid":"962486935","full_name":"akhdandann/rockPaperScissors-imageClassification","owner":"akhdandann","description":"A Convolutional Neural Network (CNN)-based image classification project that identifies hand gestures from the classic Rock-Paper-Scissors game using TensorFlow and Keras. The model is trained on a labeled dataset and demonstrates image augmentation, model evaluation, and real-time prediction on uploaded images.","archived":false,"fork":false,"pushed_at":"2025-05-14T03:59:13.000Z","size":112,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-17T21:45:38.253Z","etag":null,"topics":["cnn-classification","image-classification","keras","python","tensorflow"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/akhdandann.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-04-08T08:22:29.000Z","updated_at":"2025-05-14T03:59:16.000Z","dependencies_parsed_at":"2025-05-14T05:09:09.936Z","dependency_job_id":null,"html_url":"https://github.com/akhdandann/rockPaperScissors-imageClassification","commit_stats":null,"previous_names":["akhdandann/rockpaperscissors-imageclassification"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/akhdandann/rockPaperScissors-imageClassification","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akhdandann%2FrockPaperScissors-imageClassification","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akhdandann%2FrockPaperScissors-imageClassification/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akhdandann%2FrockPaperScissors-imageClassification/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akhdandann%2FrockPaperScissors-imageClassification/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/akhdandann","download_url":"https://codeload.github.com/akhdandann/rockPaperScissors-imageClassification/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akhdandann%2FrockPaperScissors-imageClassification/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31774017,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-13T20:17:16.280Z","status":"ssl_error","status_checked_at":"2026-04-13T20:17:08.216Z","response_time":93,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cnn-classification","image-classification","keras","python","tensorflow"],"created_at":"2025-05-21T00:16:23.909Z","updated_at":"2026-04-13T22:31:51.976Z","avatar_url":"https://github.com/akhdandann.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Rock-Paper-Scissors Image Classifier using CNN and Data Augmentation\n\nThis repository contains a TensorFlow + Keras implementation of a **Convolutional Neural Network (CNN)** model to classify images of hand gestures representing **Rock**, **Paper**, and **Scissors**.\n\n## 📌 Description\n\nThis project is a practical image classification task where the model learns to distinguish between three categories of hand gestures: rock, paper, and scissors. The dataset is obtained from **Dicoding Academy's Rock-Paper-Scissors image set**, and the model uses **image augmentation** to improve generalization.\n\nThe model is trained on preprocessed images using `ImageDataGenerator` with transformations such as rotation, flipping, and zooming to simulate real-world variance.\n\nThe classification is performed using a **multi-class CNN** with 3 output nodes and `softmax` activation.\n\n## 📁 Dataset\n\nThe dataset used is from Dicoding and publicly available:\n\n- [Rock Paper Scissors Dataset](https://github.com/dicodingacademy/assets/releases/download/release/rockpaperscissors.zip)\n\nIt consists of labeled folders:\n- `rock/`\n- `paper/`\n- `scissors/`\n\nThe code automatically downloads and extracts the dataset for training and validation.\n\n## 🛠 Features\n\n- Automatic dataset download and unzip\n- Data augmentation using `ImageDataGenerator`\n- Training-validation split with shuffling\n- Convolutional Neural Network with 3 Conv layers\n- Accuracy and loss graph visualization\n- Image classification on user-uploaded image\n\n## ⚙️ How It Works\n\n1. **Download \u0026 Extract Data**\n   - Uses `wget` and `zipfile` to fetch and unzip the dataset\n\n2. **Data Exploration**\n   - Verifies and prints folder structure\n\n3. **Data Augmentation**\n   - Applies rotation, zoom, flip, shear, etc. using `ImageDataGenerator`\n\n4. **Model Architecture**\n   - 3 convolutional layers + max pooling\n   - Fully connected layer (512 neurons)\n   - Output layer with 3 neurons + softmax\n\n5. **Training**\n   - Uses RMSprop optimizer and categorical crossentropy\n   - Trains for 50 epochs with validation split\n\n6. **Visualization**\n   - Plots training \u0026 validation accuracy and loss\n\n7. **Image Prediction**\n   - Uploads image using `files.upload()` and classifies using the trained model\n\n## 🚀 How to Run\n\n1. Open the notebook in **Google Colab** or any Jupyter environment  \n2. Install dependencies:\n   ```python\n   !pip install wget keras_preprocessing\n   ```\n3. Run the cells step by step:\n   - Download and extract dataset  \n   - Train the model  \n   - Upload an image to test prediction  \n\n## 📊 Output\n\n- CNN model summary  \n- Accuracy and loss charts  \n- Prediction result of uploaded image (rock, paper, or scissors)  \n\n## 📎 Dependencies\n\n- TensorFlow  \n- Keras Preprocessing  \n- Numpy  \n- Pandas  \n- Matplotlib  \n- wget  \n- Google Colab (for `files.upload()`)\n\n## 🧾 Note\n\nThis project was originally created as part of a **Dicoding certification test** around 5 years ago.  \nWhile it may be slightly dated, the structure and techniques are still **very useful for those preparing for upcoming certification exams or learning basic CNNs with image data**.\n\nFeel free to explore, learn, or build upon it!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fakhdandann%2Frockpaperscissors-imageclassification","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fakhdandann%2Frockpaperscissors-imageclassification","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fakhdandann%2Frockpaperscissors-imageclassification/lists"}