Skip to content

Latest commit

 

History

History
33 lines (25 loc) · 1.15 KB

README.md

File metadata and controls

33 lines (25 loc) · 1.15 KB

Image Generation

The code for image generation using C3 is minimally adapted from Lafite. Wandb was integrated for logging.

Preparing Datasets

Please refer to the instructions to prepare MSCOCO from the Lafite official repo. We directly use their preprocessed training and validation sets.

Pre-Trained Model

For all our experiments, we finetune Lafite pre-trained on Google CC3M.

Getting Started

Prepare Environment

Create conda environment

conda env create -f environment.yml

Prepare Embeddings

Compute embedding means

python3 compute_embed_mean.py

Training

Scripts for C1, C21, C22, C3 and Lafite (baseline) have been provided in scripts.

To run C3,

bash ./scripts/train_c3.sh

Generation

Images can be generated using the notebook generate.ipynb.