"CCC" is a Deep Learning project that recognizes the different icons on the Danish Quick Christmas Calder game. The model is trained using transfer learning and annotated images gathered during the Christmas season. The Model is accessed through a python flash API which allows a user to query an image; to receive a result in JSON format.
A video demo of the project can be viewed here
- Python - Programmingh Langauge
- Pytorch - Machine Learning framework
- Albumentation - Libary for image augmentation
- Flask - Backend
The models are trained using annotated images of calenders. To reduce the number of training images needed transfer learning and image augmentation was utilized. The base point of the model is the resnet50 Object detection model provided by Pytorch.
More information about the can be seen in the Jypyter notebook qkt.ipynb which was utilized for the training.
The complete model is too large to store on GitHub, But a new model can be trained with the qkt.ipynb notebook or access can be granted upon request to the author.
The server is hosted using a flask API. The API accepts POST request at the route /predict. The Post request must include an image with the file tag. A helper script can be found in sender.py which sends a file to the server.
Once a request has been received the request is validated. The image is then fed through the model and the predicted results are returns in JSON format.
To initialize the server out-of-the-box the host system MUST be CODA enabled.
All the dependencies needed to run the server on a Ubnunuto Cuda enabled machine can be found in the requirments.txt. To Install all dependencies run
pip3 install -r requirements.txtTo initialize the server mount the server folder and run:
FLASK_ENV=development FLASK_APP=index.py flask runThe server is by default hosted on port 5000 on the system. This can be changed in the index.py script
- Anders Wiggers - Initial work - GitHub
See also the list of contributors who participated in this project.
This project is licensed under the MIT License - see the LICENSE.md file for details
A Point for future work of the project is enabling docker instances which would make the process of deployment tremendously easier. The current process of deploying the server on a system is time-consuming and dependency management is not trivial. This is a point that will be addressed in a future release.