A project which performs compression and decompression of images from the MNIST dataset using autoencoder and K-Means clustering and deployment of the model using Flask.
- Coded in python 3.8
- Interactive python notebook editor - Google collab
- Notebooks - contains the google collab notebooks
- Flask App - contains the code required for the flask application
- Models - contains the pretrained models in h5 format
- Results - contains screenshots of the project outcome
To run the flask app in a windows environment
- Install python 3.8
- Run
pip install virtualenv
- Run
mkdir project
to create project directory - Run
cd project
to move to the project directory - Run
virtualenv venv
to create a virtual environment - Run
.\Scripts\activate
to activate the virtual environement - Run
pip install tensorflow numpy Flask keras matplotlib pillow opencv-python scikit-image cv2 sklearn
to install the dependencies - Copy the contents of the Flask app folder to your virtual environment and use command
python app.py
to run the app.
The python notebooks can be executed in Google collab by signing up for a Google account. Upload the pre-trained models into the collab runtime and load them to execute the code faster.