rosinality/vq-vae-2-pytorch
PyTorch implementation of VQ-VAE-2, a hierarchical vector quantized variational autoencoder for generating high-fidelity images.

This repository provides a PyTorch implementation of the VQ-VAE-2 generative model. VQ-VAE-2 uses vector quantization in a hierarchical setup with top and bottom levels to compress images into discrete latent codes, followed by a PixelSNAIL autoregressive prior for sampling. The implementation supports distributed training across multiple GPUs and includes code for extracting latent codes into LMDB databases for training the prior model.