Designed to learn long-range interactions on sequential data, transformers continue to show state-of-the-art results on a wide variety of tasks. In contrast to CNNs, they contain no inductive bias that prioritizes local interactions. This makes them expressive, but also computationally infeasible for long sequences, such as high-resolution images. We demonstrate how combining the effectiveness of the inductive bias of CNNs with the expressivity of transformers enables them to model and thereby synthesize high-resolution images. We show how to (i) use CNNs to learn a contextrich vocabulary of image constituents, and in turn (ii) utilize transformers to efficiently model their composition within high-resolution images. Our approach is readily applied to conditional synthesis tasks, where both non-spatial information, such as object classes, and spatial information, such as segmentations, can control the generated image. In particular, we present the first results on semanticallyguided synthesis of megapixel images with transformers and obtain the state of the art among autoregressive models on class-conditional ImageNet. Code and pretrained models can be found at https://git.io/JnyvK.
translated by 谷歌翻译
通过将图像形成过程分解成逐个申请的去噪自身额,扩散模型(DMS)实现了最先进的合成导致图像数据和超越。另外,它们的配方允许引导机构来控制图像生成过程而不会再刷新。然而,由于这些模型通常在像素空间中直接操作,因此强大的DMS的优化通常消耗数百个GPU天,并且由于顺序评估,推理是昂贵的。为了在保留其质量和灵活性的同时启用有限计算资源的DM培训,我们将它们应用于强大的佩带自动化器的潜在空间。与以前的工作相比,这种代表上的培训扩散模型允许第一次达到复杂性降低和细节保存之间的近乎最佳点,极大地提高了视觉保真度。通过将跨关注层引入模型架构中,我们将扩散模型转化为强大而柔性的发电机,以进行诸如文本或边界盒和高分辨率合成的通用调节输入,以卷积方式变得可以实现。我们的潜在扩散模型(LDMS)实现了一种新的技术状态,可在各种任务中进行图像修复和高竞争性能,包括无条件图像生成,语义场景合成和超级分辨率,同时与基于像素的DMS相比显着降低计算要求。代码可在https://github.com/compvis/lattent-diffusion获得。
translated by 谷歌翻译
生成建模研究的持续趋势是将样本分辨率推高更高,同时减少培训和采样的计算要求。我们的目标是通过技术的组合进一步推动这一趋势 - 每个组件代表当前效率在各自领域的顶峰。其中包括载体定量的GAN(VQ-GAN),该模型具有高水平的损耗 - 但感知上微不足道的压缩模型;沙漏变形金刚,一个高度可扩展的自我注意力模型;和逐步未胶片的denoising自动编码器(Sundae),一种非自动化(NAR)文本生成模型。出乎意料的是,当应用于多维数据时,我们的方法突出了沙漏变压器的原始公式中的弱点。鉴于此,我们建议对重采样机制进行修改,该机制适用于将分层变压器应用于多维数据的任何任务。此外,我们证明了圣代表到长序列长度的可伸缩性 - 比先前的工作长四倍。我们提出的框架秤达到高分辨率($ 1024 \ times 1024 $),并迅速火车(2-4天)。至关重要的是,训练有素的模型在消费级GPU(GTX 1080TI)上大约2秒内生产多样化和现实的百像样品。通常,该框架是灵活的:支持任意数量的采样步骤,示例自动插入,自我纠正功能,有条件的生成和NAR公式,以允许任意介绍掩护。我们在FFHQ256上获得10.56的FID得分 - 仅在100个采样步骤中以不到一半的采样步骤接近原始VQ -GAN,而FFHQ1024的FFHQ1024和21.85。
translated by 谷歌翻译
虽然扩散概率模型可以产生高质量的图像内容,但仍然存在高分辨率图像的关键限制及其相关的高计算要求。最近的矢量量化图像模型已经克服了图像分辨率的这种限制,而是通过从之前的元素 - 明智的自回归采样生成令牌时,这是对图像分辨率的速度和单向的。相比之下,在本文中,我们提出了一种新的离散扩散概率模型,其通过使用无约束的变压器架构作为骨干来支持矢量量化令牌的并行预测。在培训期间,令牌以订单不可知的方式随机掩盖,变压器学会预测原始令牌。这种矢量量化令牌预测的并行性反过来促进了在计算费用的一小部分下的全球一致的高分辨率和多样性图像的无条件生成。以这种方式,我们可以产生超过原始训练集样本的图像分辨率,而另外提供每个图像似然估计(从生成的对抗方法的差点)。我们的方法在密度方面实现了最先进的结果(Lsun卧室:1.51; Lsun Churches:1.12; FFHQ:1.20)和覆盖范围(Lsun卧室:0.83; Lsun Churches:0.73; FFHQ:0.80),并执行竞争对手(LSUN卧室:3.64; LSUN教堂:4.07; FFHQ:6.11)在计算和减少训练套件要求方面提供优势。
translated by 谷歌翻译
We explore the use of Vector Quantized Variational AutoEncoder (VQ-VAE) models for large scale image generation. To this end, we scale and enhance the autoregressive priors used in VQ-VAE to generate synthetic samples of much higher coherence and fidelity than possible before. We use simple feed-forward encoder and decoder networks, making our model an attractive candidate for applications where the encoding and/or decoding speed is critical. Additionally, VQ-VAE requires sampling an autoregressive model only in the compressed latent space, which is an order of magnitude faster than sampling in the pixel space, especially for large images. We demonstrate that a multi-scale hierarchical organization of VQ-VAE, augmented with powerful priors over the latent codes, is able to generate samples with quality that rivals that of state of the art Generative Adversarial Networks on multifaceted datasets such as ImageNet, while not suffering from GAN's known shortcomings such as mode collapse and lack of diversity.
translated by 谷歌翻译
尽管两阶段矢量量化(VQ)生成模型允许合成高保真性和高分辨率图像,但其量化操作员将图像中的相似贴片编码为相同的索引,从而为相似的相邻区域重复使用现有的解码器体系结构的相似相似区域的重复伪像。为了解决这个问题,我们建议将空间条件的归一化结合起来,以调节量化的向量,以便将空间变体信息插入嵌入式索引图中,从而鼓励解码器生成更真实的图像。此外,我们使用多通道量化来增加离散代码的重组能力,而无需增加模型和代码簿的成本。此外,为了在第二阶段生成离散令牌,我们采用掩盖的生成图像变压器(MaskGit)来学习压缩潜在空间中的基础先验分布,该分布比常规自动回归模型快得多。两个基准数据集的实验表明,我们提出的调制VQGAN能够大大提高重建的图像质量,并提供高保真图像的产生。
translated by 谷歌翻译
Vector-Quantized (VQ-based) generative models usually consist of two basic components, i.e., VQ tokenizers and generative transformers. Prior research focuses on improving the reconstruction fidelity of VQ tokenizers but rarely examines how the improvement in reconstruction affects the generation ability of generative transformers. In this paper, we surprisingly find that improving the reconstruction fidelity of VQ tokenizers does not necessarily improve the generation. Instead, learning to compress semantic features within VQ tokenizers significantly improves generative transformers' ability to capture textures and structures. We thus highlight two competing objectives of VQ tokenizers for image synthesis: semantic compression and details preservation. Different from previous work that only pursues better details preservation, we propose Semantic-Quantized GAN (SeQ-GAN) with two learning phases to balance the two objectives. In the first phase, we propose a semantic-enhanced perceptual loss for better semantic compression. In the second phase, we fix the encoder and codebook, but enhance and finetune the decoder to achieve better details preservation. The proposed SeQ-GAN greatly improves VQ-based generative models and surpasses the GAN and Diffusion Models on both unconditional and conditional image generation. Our SeQ-GAN (364M) achieves Frechet Inception Distance (FID) of 6.25 and Inception Score (IS) of 140.9 on 256x256 ImageNet generation, a remarkable improvement over VIT-VQGAN (714M), which obtains 11.2 FID and 97.2 IS.
translated by 谷歌翻译
基于注意的模型,由变压器举例说明,可以有效地模拟长距离依赖性,而是遭受自我注意操作的二次复杂性,使得基于生成的对抗网络(GAN)的高分辨率图像生成使得它们难以采用。在本文中,我们向变压器推出了两个关键成分来解决这一挑战。首先,在生成过程的低分辨率阶段,用所提出的多轴阻塞自我关注取代了标准的全球自我关注,这允许有效地混合本地和全球关注。其次,在高分辨率阶段,我们降低了自我关注,同时只保持多层的感知让人想起隐含的神经功能。为了进一步提高性能,我们基于横向引入额外的自我调制组件。结果模型表示为命中,具有关于图像尺寸的几乎线性的计算复杂度,从而直接缩放到合成高清晰度图像。我们在实验中展示了所提出的命中,实现最先进的FID得分31.87和2.95在无条件的ImageNet上,分别具有合理的吞吐量的128美元和256美元\ times 256美元。我们认为,拟议的命中是全球发电机的一个重要里程碑,完全没有卷积。
translated by 谷歌翻译
Astounding results from Transformer models on natural language tasks have intrigued the vision community to study their application to computer vision problems. Among their salient benefits, Transformers enable modeling long dependencies between input sequence elements and support parallel processing of sequence as compared to recurrent networks e.g., Long short-term memory (LSTM). Different from convolutional networks, Transformers require minimal inductive biases for their design and are naturally suited as set-functions. Furthermore, the straightforward design of Transformers allows processing multiple modalities (e.g., images, videos, text and speech) using similar processing blocks and demonstrates excellent scalability to very large capacity networks and huge datasets. These strengths have led to exciting progress on a number of vision tasks using Transformer networks. This survey aims to provide a comprehensive overview of the Transformer models in the computer vision discipline. We start with an introduction to fundamental concepts behind the success of Transformers i.e., self-attention, large-scale pre-training, and bidirectional feature encoding. We then cover extensive applications of transformers in vision including popular recognition tasks (e.g., image classification, object detection, action recognition, and segmentation), generative modeling, multi-modal tasks (e.g., visual-question answering, visual reasoning, and visual grounding), video processing (e.g., activity recognition, video forecasting), low-level vision (e.g., image super-resolution, image enhancement, and colorization) and 3D analysis (e.g., point cloud classification and segmentation). We compare the respective advantages and limitations of popular techniques both in terms of architectural design and their experimental value. Finally, we provide an analysis on open research directions and possible future works. We hope this effort will ignite further interest in the community to solve current challenges towards the application of transformer models in computer vision.
translated by 谷歌翻译
创建视频是为了表达情感,交换信息和分享经验。视频合成很长时间以来一直吸引了研究人员。尽管视觉合成的进步驱动了迅速的进展,但大多数现有研究都集中在提高框架的质量和之间的过渡上,而在生成更长的视频方面几乎没有取得进展。在本文中,我们提出了一种基于3D-VQGAN和Transformers的方法,以生成具有数千帧的视频。我们的评估表明,我们的模型在16架视频剪辑中培训了来自UCF-101,Sky TimeLapse和Taichi-HD数据集等标准基准测试片段,可以生成多样化,连贯和高质量的长视频。我们还展示了我们通过将时间信息与文本和音频结合在一起来生成有意义的长视频的方法的条件扩展。可以在https://songweige.github.io/projects/tats/index.html上找到视频和代码。
translated by 谷歌翻译
最近对变形金刚的爆炸利益提出了他们成为计算机视觉任务的强大“通用”模型的潜力,例如分类,检测和分割。虽然这些尝试主要研究歧视模型,但我们探索变压器,更加臭名昭着的难以愿景任务,例如生成的对抗网络(GANS)。我们的目标是通过仅使用纯的变压器的架构,开展一项完全没有卷曲的GAN的试点研究。我们的Vanilla GaN架构被称为Cransgan,包括一个基于内存友好的变换器的发电机,逐渐增加了特征分辨率,并且相应地是多尺度鉴别器来捕获同时语义上下文和低级纹理。在他们之上,我们介绍了新的网格自我关注模块,以便进一步缓解记忆瓶颈,以便扩展到高分辨率的发电。我们还开发了一个独特的培训配方,包括一系列技术,可以减轻转发的培训不稳定问题,例如数据增强,修改的归一化和相对位置编码。与使用卷积骨架的当前最先进的GAN相比,我们最好的建筑达到了竞争力的表现。具体而言,转发在STL-10上设置10.43和18.28的最新的最新成立得分为18.28,表现优于样式。当涉及更高分辨率(例如256 x 256)的生成任务时,例如Celeba-HQ和Lsun-Church,Rancorgan继续生产具有高保真度和令人印象深刻的纹理细节的不同视觉示例。此外,我们通过可视化培训动力学,深入了解基于变压器的生成模型,了解他们的行为如何与卷积的行为。代码可在https://github.com/vita-group/transgan中获得。
translated by 谷歌翻译
变压器在计算机视觉中变得普遍,特别是对于高级视觉任务。然而,采用生成的对抗性网络(GaN)框架中的变压器仍然是一个开放但具有挑战性的问题。本文进行了一项全面的实证研究,探讨了高保真图像合成的GaN中变压器的性能。我们的分析亮点并重申了特征局部度在图像生成中的重要性,尽管局部性的优点在分类任务中是众所周知的。也许更有趣的是,我们发现自我关注层中的残余连接有害,以利用基于变压器的鉴别器和条件发电机。我们仔细检查了影响力,并提出了减轻负面影响的有效方法。我们的研究导致GaN中的变压器的新替代设计,卷积神经网络(CNN) - 免费发电机称为晶体 - G,这在无条件和条件图像代中实现了竞争导致。基于变压器的鉴别器,Strans-D也显着降低了其基于CNN的鉴别器的间隙。
translated by 谷歌翻译
随着信息中的各种方式存在于现实世界中的各种方式,多式联信息之间的有效互动和融合在计算机视觉和深度学习研究中的多模式数据的创造和感知中起着关键作用。通过卓越的功率,在多式联运信息中建模互动,多式联运图像合成和编辑近年来已成为一个热门研究主题。与传统的视觉指导不同,提供明确的线索,多式联路指南在图像合成和编辑方面提供直观和灵活的手段。另一方面,该领域也面临着具有固有的模态差距的特征的几个挑战,高分辨率图像的合成,忠实的评估度量等。在本调查中,我们全面地阐述了最近多式联运图像综合的进展根据数据模型和模型架构编辑和制定分类。我们从图像合成和编辑中的不同类型的引导方式开始介绍。然后,我们描述了多模式图像综合和编辑方法,其具有详细的框架,包括生成的对抗网络(GAN),GaN反转,变压器和其他方法,例如NERF和扩散模型。其次是在多模式图像合成和编辑中广泛采用的基准数据集和相应的评估度量的综合描述,以及分析各个优点和限制的不同合成方法的详细比较。最后,我们为目前的研究挑战和未来的研究方向提供了深入了解。与本调查相关的项目可在HTTPS://github.com/fnzhan/mise上获得
translated by 谷歌翻译
Recent neural compression methods have been based on the popular hyperprior framework. It relies on Scalar Quantization and offers a very strong compression performance. This contrasts from recent advances in image generation and representation learning, where Vector Quantization is more commonly employed. In this work, we attempt to bring these lines of research closer by revisiting vector quantization for image compression. We build upon the VQ-VAE framework and introduce several modifications. First, we replace the vanilla vector quantizer by a product quantizer. This intermediate solution between vector and scalar quantization allows for a much wider set of rate-distortion points: It implicitly defines high-quality quantizers that would otherwise require intractably large codebooks. Second, inspired by the success of Masked Image Modeling (MIM) in the context of self-supervised learning and generative image models, we propose a novel conditional entropy model which improves entropy coding by modelling the co-dependencies of the quantized latent codes. The resulting PQ-MIM model is surprisingly effective: its compression performance on par with recent hyperprior methods. It also outperforms HiFiC in terms of FID and KID metrics when optimized with perceptual losses (e.g. adversarial). Finally, since PQ-MIM is compatible with image generation frameworks, we show qualitatively that it can operate under a hybrid mode between compression and generation, with no further training or finetuning. As a result, we explore the extreme compression regime where an image is compressed into 200 bytes, i.e., less than a tweet.
translated by 谷歌翻译
Adversarially trained generative models (GANs) have recently achieved compelling image synthesis results. But despite early successes in using GANs for unsupervised representation learning, they have since been superseded by approaches based on self-supervision. In this work we show that progress in image generation quality translates to substantially improved representation learning performance. Our approach, BigBiGAN, builds upon the state-of-the-art BigGAN model, extending it to representation learning by adding an encoder and modifying the discriminator. We extensively evaluate the representation learning and generation capabilities of these BigBiGAN models, demonstrating that these generation-based models achieve the state of the art in unsupervised representation learning on ImageNet, as well as in unconditional image generation. Pretrained BigBiGAN models -including image generators and encoders -are available on TensorFlow Hub 1 .
translated by 谷歌翻译
作为生成部件作为自回归模型的向量量化变形式自动化器(VQ-VAE)的集成在图像生成上产生了高质量的结果。但是,自回归模型将严格遵循采样阶段的逐步扫描顺序。这导致现有的VQ系列模型几乎不会逃避缺乏全球信息的陷阱。连续域中的去噪扩散概率模型(DDPM)显示了捕获全局背景的能力,同时产生高质量图像。在离散状态空间中,一些作品已经证明了执行文本生成和低分辨率图像生成的可能性。我们认为,在VQ-VAE的富含内容的离散视觉码本的帮助下,离散扩散模型还可以利用全局上下文产生高保真图像,这补偿了沿像素空间的经典自回归模型的缺陷。同时,离散VAE与扩散模型的集成解决了传统的自回归模型的缺点是超大的,以及在生成图像时需要在采样过程中的过度时间的扩散模型。结果发现所生成的图像的质量严重依赖于离散的视觉码本。广泛的实验表明,所提出的矢量量化离散扩散模型(VQ-DDM)能够实现与低复杂性的顶层方法的相当性能。它还展示了在没有额外培训的图像修复任务方面与自回归模型量化的其他矢量突出的优势。
translated by 谷歌翻译
深层图像介绍取得了令人印象深刻的进步,随着图像产生和处理算法的最新进展。我们声称,可以通过生成的结构和纹理更好地判断介入算法的性能。结构是指孔中生成的对象边界或新的几何结构,而纹理是指高频细节,尤其是在结构区域内填充的人造重复模式。我们认为,更好的结构通常是从基于粗糙的GAN的发电机网络中获得的,而如今重复模式可以通过最新的高频快速快速傅立叶卷积层进行更好的建模。在本文中,我们提出了一个新颖的介绍网络,结合了这两种设计的优势。因此,我们的模型具有出色的视觉质量,可以匹配结构生成和使用单个网络重复纹理合成的最新性能。广泛的实验证明了该方法的有效性,我们的结论进一步突出了图像覆盖质量,结构和纹理的两个关键因素,即未来的设计方向。
translated by 谷歌翻译
Inspired by progress in unsupervised representation learning for natural language, we examine whether similar models can learn useful representations for images. We train a sequence Transformer to auto-regressively predict pixels, without incorporating knowledge of the 2D input structure. Despite training on low-resolution ImageNet without labels, we find that a GPT-2 scale model learns strong image representations as measured by linear probing, fine-tuning, and low-data classification. On CIFAR-10, we achieve 96.3% accuracy with a linear probe, outperforming a supervised Wide ResNet, and 99.0% accuracy with full fine-tuning, matching the top supervised pretrained models. We are also competitive with self-supervised benchmarks on ImageNet when substituting pixels for a VQVAE encoding, achieving 69.0% top-1 accuracy on a linear probe of our features.
translated by 谷歌翻译
现实世界中的数据是高维的:即使在压缩后,书籍,图像或音乐表演也很容易包含数十万个元素。但是,最常用的自回归模型,变压器非常昂贵,以缩放捕获这种远程结构所需的输入和层数。我们开发了感知者AR,这是一种自回归的模态 - 不合骨架构,它使用交叉注意力将远程输入映射到少数潜在的潜在,同时还可以维护端到端的因果关系掩盖。感知器AR可以直接进行十万个令牌,从而实现了实用的长篇小写密度估计,而无需手工制作的稀疏模式或记忆机制。当对图像或音乐进行培训时,感知器AR会生成具有清晰长期连贯性和结构的输出。我们的架构还获得了长期基准测试的最新可能性,包括64 x 64个Imagenet图像和PG-19书籍。
translated by 谷歌翻译
盲面修复是一个高度不良的问题,通常需要辅助指导至1)改进从退化输入到所需输出的映射,或2)补充输入中丢失的高质量细节。在本文中,我们证明了在一个较小的代理空间中的一本学识渊博的代码书在很大程度上降低了恢复映射的不确定性和模棱两可,通过将盲面修复作为代码预测任务,同时为产生高质量的面孔提供丰富的视觉原子。在此范式下,我们提出了一个基于变压器的预测网络,名为CodeFormer,以模拟代码预测的低质量面孔的全局构图和上下文,从而使发现自然面,即使输入严重,也紧密近似目标面退化。为了增强不同降解的适应性,我们还提出了一个可控的特征转换模块,该模块可以在忠诚度和质量之间进行灵活的权衡。得益于表达的代码书的先验和全球建模,CodeFormer的质量和忠诚度都优于艺术状态,从而表现出优势的降级性。关于合成和现实世界数据集的广泛实验结果验证了我们方法的有效性。
translated by 谷歌翻译