From 6c972c6a1f769f8e2f9d89e7e9021a27dc8cb912 Mon Sep 17 00:00:00 2001 From: Filip Haltmayer Date: Thu, 27 Jan 2022 15:31:31 -0800 Subject: [PATCH] readme --- README.md | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 57 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 240335e..7f60c06 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,58 @@ -# style-transfer-animegan +# Pipeline: Style Transfer using AnimeGanV2 +Authors: filip + +## Overview + +The pipeline is used to **animate images**. It uses the AnimeGanV2 to cartoonize the images. + +## Interface + +**Input Arguments:** + +- img_path: + - the input image path + - supported types: `str` + +**Pipeline Output:** + +The pipeline returns a tuple `Tuple[('styled_image', numpy.ndarray)]` containing following fields: + +- styled_image: + - styled photo + - data type: `numpy.ndarray` + - shape: (3, x, x) + - format: RGB + - values: [0,1] + +## How to use + +1. Install [Towhee](https://github.com/towhee-io/towhee) + +```bash +$ pip3 install towhee +``` + +> You can refer to [Getting Started with Towhee](https://towhee.io/) for more details. If you have any questions, you can [submit an issue to the towhee repository](https://github.com/towhee-io/towhee/issues). + +2. Run it with Towhee + +```python +>>> from towhee import pipeline + +>>> img_path = 'path/to/your/image' +>>> embedding_pipeline = pipeline('filip-halt/style-transfer-animegan') +>>> embedding = embedding_pipeline(img_path) +``` + +## How it works + +This pipeline includes one operator: [filip-halt/animegan-style-transfer](https://hub.towhee.io/filip-halt/animegan-style-transfer). This operator stylizes the image. + +> Refer [Towhee architecture](https://github.com/towhee-io/towhee#towhee-architecture) for basic concepts in Towhee: pipeline, operator, dataframe. + + +## References +Jie Chen, Gang Liu, Xin Chen +"AnimeGAN: A Novel Lightweight GAN for Photo Animation." +ISICA 2019: Artificial Intelligence Algorithms and Applications pp 242-256, 2019.