Code Monkey home page Code Monkey logo

dalle-models's Introduction

Trained Dall-E models

This repository is a collection of checkpoints for DALLE-pytorch models, from where you can keep on training or start generating images.

The idea of this repository is to make shared and continued training feasible and in the long run determine the best model and hyperparameters.

The models are trained with lucidrains' DALLE-pytorch (https://github.com/lucidrains/DALLE-pytorch) code.

Naming convention and metadata

1. Foldernames

1.1 Stem

The folders are named after the transformer used for training (either taming or open-ai transformer for now):

Models with 12 layers (=depth), 8 heads, 64 head dimensions, 128 text dimensions, 512 image dimensions which are trained with the taming-transformer:

taming/12L_64HD_8H_512I_128T_cc12m_1E

The Filenames and folders contain all necessary information for "continuing" training (even though the train_dalle.py script extracts those parameters from the provided model anyway). The batch size is not included in the filename, as you can continue training on the models with a higher batch size if you have a better GPU for example. The same rule applies for the other hyperparameters listed below, which are not part of the filename.

So if another person trains with the same dataset for an additional epoch, he can upload the new model into the taming folder and name the subfolder as follows:

12L_64HD_8H_512I_128T_cc12m_2E.pt

1.2 Epochs

The last part of the filename/folder is the number of epochs trained and the used dataset - it is the total count of epochs trained on given dataset, so you you train for 2 epochs on a model that was already trained for 3x2 epochs, the last part of the filename is 8E = 8 total number of epochs trained. If you train on a different dataset, just add the name of the dataset and the number of epochs trained. The following model was trained 2 epochs on the conceptual images dataset and one epoch on the wit dataset:

12L_64HD_8H_512I_128T_cc12m-2E_wit-1E.pt

2. Hyperparameters

Provide a short description of your other training parameters used and the quality of image generation (e.g. with RM-Scores and examples of the generations) like this:

BATCH_SIZE = 20
LEARNING_RATE = 3e-4
GRAD_CLIP_NORM = 0.9

MODEL_DIM = 512                   # image dimensions,           "512I"
TEXT_SEQ_LEN = 256                # text dimensions,            "128T"
DEPTH = 12                        # number of layers,            "12L"
HEADS = 8                         # number of heads,              "8H"
DIM_HEAD = 64                     # number of head dimensions,  "64HD"
REVERSIBLE = True
LOSS_IMG_WEIGHT = 7
LR_DECAY = False
ATTN_TYPES = ('full', 'sparse')

3. Generation capabilities and quality

Optionally, you may provide examples of generated images and quantitative metrics of your uploaded model.

3.1 general model (e.g. cc12m, yfcc100m, wit or alike used for training):

  • "An armchair in the shape of an avocado. An armchair imitating an avocado."
  • "A red tshirt with a black circle drawn on it."
  • "People playing soccer on a field."

3.2 specific model (e.g. CUB200 birds or a fashion dataset used for training)

  • depending on your domain, generate a few examples with a text input which is not part of your training dataset

4. Datasets

If you want to train on your own and do not want to make a big fuss about downloading and preparing the datasets, you can use helper scripts which automate a large part of the dataset-generations:

https://github.com/robvanvolt/DALLE-datasets

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.