open-mmlab / mmgeneration

MMGeneration is a powerful toolkit for generative models, based on PyTorch and MMCV.
https://mmgeneration.readthedocs.io/en/latest/
Apache License 2.0
1.88k stars 226 forks source link
diffusion-models gan generative generative-adversarial-network mmcv openmmlab pytorch
 
OpenMMLab website HOT      OpenMMLab platform TRY IT OUT
 

PyPI docs badge codecov license open issues issue resolution

📘Documentation | 🛠️Installation | 👀Model Zoo | 🆕Update News | 🚀Ongoing Projects | 🤔Reporting Issues

English | 简体中文

What's New

MMGeneration has been merged in MMEditing. And we have supported new generation tasks and models. We highlight the following new features:

Introduction

MMGeneration is a powerful toolkit for generative models, especially for GANs now. It is based on PyTorch and MMCV. The master branch works with PyTorch 1.5+.

Major Features

Training Visualization
GAN Interpolation
GAN Projector
GAN Manipulation

Highlight

Changelog

v0.7.3 was released on 14/04/2023. Please refer to changelog.md for details and release history.

Installation

MMGeneration depends on PyTorch and MMCV. Below are quick steps for installation.

Step 1. Install PyTorch following official instructions, e.g.

pip3 install torch torchvision

Step 2. Install MMCV with MIM.

pip3 install openmim
mim install mmcv-full

Step 3. Install MMGeneration from source.

git clone https://github.com/open-mmlab/mmgeneration.git
cd mmgeneration
pip3 install -e .

Please refer to get_started.md for more detailed instruction.

Getting Started

Please see get_started.md for the basic usage of MMGeneration. docs/en/quick_run.md can offer full guidance for quick run. For other details and tutorials, please go to our documentation.

ModelZoo

These methods have been carefully studied and supported in our frameworks:

Unconditional GANs (click to collapse) - ✅ [DCGAN](configs/dcgan/README.md) (ICLR'2016) - ✅ [WGAN-GP](configs/wgan-gp/README.md) (NIPS'2017) - ✅ [LSGAN](configs/lsgan/README.md) (ICCV'2017) - ✅ [GGAN](configs/ggan/README.md) (arXiv'2017) - ✅ [PGGAN](configs/pggan/README.md) (ICLR'2018) - ✅ [StyleGANV1](configs/styleganv1/README.md) (CVPR'2019) - ✅ [StyleGANV2](configs/styleganv2/README.md) (CVPR'2020) - ✅ [StyleGANV3](configs/styleganv3/README.md) (NeurIPS'2021) - ✅ [Positional Encoding in GANs](configs/positional_encoding_in_gans/README.md) (CVPR'2021)
Conditional GANs (click to collapse) - ✅ [SNGAN](configs/sngan_proj/README.md) (ICLR'2018) - ✅ [Projection GAN](configs/sngan_proj/README.md) (ICLR'2018) - ✅ [SAGAN](configs/sagan/README.md) (ICML'2019) - ✅ [BIGGAN/BIGGAN-DEEP](configs/biggan/README.md) (ICLR'2019)
Tricks for GANs (click to collapse) - ✅ [ADA](configs/ada/README.md) (NeurIPS'2020)
Image2Image Translation (click to collapse) - ✅ [Pix2Pix](configs/pix2pix/README.md) (CVPR'2017) - ✅ [CycleGAN](configs/cyclegan/README.md) (ICCV'2017)
Internal Learning (click to collapse) - ✅ [SinGAN](configs/singan/README.md) (ICCV'2019)
Denoising Diffusion Probabilistic Models (click to collapse) - ✅ [Improved DDPM](configs/improved_ddpm/README.md) (arXiv'2021)

Related-Applications

Contributing

We appreciate all contributions to improve MMGeneration. Please refer to CONTRIBUTING.md in MMCV for more details about the contributing guideline.

Citation

If you find this project useful in your research, please consider cite:

@misc{2021mmgeneration,
    title={{MMGeneration}: OpenMMLab Generative Model Toolbox and Benchmark},
    author={MMGeneration Contributors},
    howpublished = {\url{https://github.com/open-mmlab/mmgeneration}},
    year={2021}
}

License

This project is released under the Apache 2.0 license. Some operations in MMGeneration are with other licenses instead of Apache2.0. Please refer to LICENSES.md for the careful check, if you are using our code for commercial matters.

Projects in OpenMMLab