Skip to content

Latest commit

 

History

History
48 lines (38 loc) · 3.19 KB

README.md

File metadata and controls

48 lines (38 loc) · 3.19 KB

Selfie2Anime with TensorFlow Lite

This is the GitHub repo for an end-to-end tutorial from TFLite model conversion, to model deployment on an Android App. Links to the three-part tutorial on Medium:

Selfie2Anime with TensorFlow Lite is one of the many End-to-End TensorFlow Lite Tutorials. See the full list of TensorFlow Lite samples and learning resources on awesome-tflite.

Authors: (ML GDEs: Google Developer Experts for Machine Learning) Margaret Maynard-Reid and Sayak Paul
Reviewers: (Google TensorFlow team) Khanh LeViet and Hoi Lam



This repository is structured in the following way:

|--ml  
|  |--add-meta-data-Colab             // How to add metadata via Colab  
|  |--add-meta-data-CLI               // How to add metadata via command line  
|  |--Selfie2Anime_Model_Conversion   // How to convert and save to TFLite model  
|--android  
|  |--selfie2anime                    // TFLite model on Androi app  

The ml folder contains the model files, and the instructions on how to save the model, and convert it to selfe2anime.tflite, and add metadata to it via either command line or a Colab notebook.

The android folder contains the Android source code and the instructions on how to build the Android app.

The Selfie2Anime model

We used a Generative Adversarial Network (GAN) model proposed in this paper Unsupervised Generative Attentional Networks with Adaptive Layer-Instance Normalization for Image-to-Image Translation (also known as U-GAT-IT). The paper provides two generators: one that converts a selfie to anime-style image and the other one from anime to selfie. Here we only implemented the Selfie2Anime model since it better resembles the real-world scenario. The GitHub repository of the paper is available here.

Citation

The original authors of U-GAT-IT: Junho Kim, Minjae Kim, Hyeonwoo Kang, Kwanghee Lee.

@inproceedings{
Kim2020U-GAT-IT:,
title={U-GAT-IT: Unsupervised Generative Attentional Networks with Adaptive Layer-Instance Normalization for Image-to-Image Translation},
author={Junho Kim and Minjae Kim and Hyeonwoo Kang and Kwang Hee Lee},
booktitle={International Conference on Learning Representations},
year={2020},
url={https://openreview.net/forum?id=BJlZ5ySKPH}
} 

Acknowledgement

We would like to thank Khanh LeViet and Lu Wang (TensorFlow Lite team), Hoi Lam (Android ML), and Soonson Kwon (ML GDEs Google Developer Expert Program), for their collaboration and continuous support.