Project aimed to create a GAN, that is able to generate art just from text descriptions. The project can be accessed from GitLab or GitHub.
For each style, the first column is where lambda_idt = 0.5 and the second column is where lambda_idt = 5.
For each style, the first column is where lambda_idt = 0.5 and the second column is where lambda_idt = 5.
When given a more abstract word, the results can be quite interesting:
python 3.7
pytorch
numpy
easydict
pyyaml
You can download the model parameters from here.
- Install dependecies
- Clone this repo:
git clone https://gitlab.com/karl-joan/text2art-gan.git
cd text2art-gan
- Download model parameters to the current working directory
- Extract model parameters
7z x parameters.7z
$ python generate.py --help
usage: generate.py [-h] [-d {birds,coco}] [-n NUMBER] [-i] [-c] [-v]
"caption" {abstract_expressionism,impressionism}
Generate art from text
positional arguments:
"caption" text to generate from
{abstract_expressionism,impressionism}
the style of the artwork
optional arguments:
-h, --help show this help message and exit
-d {birds,coco}, --dataset {birds,coco}
dataset to generate from (default birds)
-n NUMBER, --number NUMBER
the number of artworks to generate (default 2)
-i, --identity set lambda_idt = 5 instead of lambda_idt = 0.5
-c, --cpu use cpu
-v, --verbose print more details
$ python generate -d coco "a man is standing infront of a building" abstract_expressionism
If you use the work present in this repository for your project, then please consider citing this work.