Compresses Twemoji emojis down to 64 bytes (16 4-bit floating point numbers).
This repository contains an already pretrained model for web use. You can use it as-is without training by hosting
the www
directory on a web server.
To test the shipped model, just follow this link.
pip3
module.virtualenv
for this project.pip3 install -r requirements.txt
.tensorflow-gpu
package using pip3 install tensorflow-gpu
.src
directory.python3 svg2png.py
to download and convert the images to a usable format.Now we are all set, time to train the network:
src
directory.python3 autoencoder.py
To prepare the trained model for use in the web, use the tensorflowjs_converter
.
If you have used virtualenv
to create a virtual environment on Windows, you can find the tensorflowjs_converter.exe
file in <virtualenv directory>\Scripts\tensorflowjs_converter.exe
.
On other operating systems, the binary should already be in your $PATH and ready to be used.
<tensorflowjs_converter> --input_format keras --output_format tfjs_layers_model logs\<latest directory>\model.h5 www
Due to the use of tfjs
, you have to host the www
directory on a web server.
Just open the index.html
file in your browser and use the model or design your own page for it.