Mixed-precision quantization has been widely applied on deep neural networks (DNNs) as it leads to significantly better efficiency-accuracy tradeoffs compared to uniform quantization. Meanwhile, determining the exact precision of each layer remains challenging. Previous attempts on bit-level regularization and pruning-based dynamic precision adjustment during training suffer from noisy gradients and unstable convergence. In this work, we propose Continuous Sparsification Quantization (CSQ), a bit-level training method to search for mixed-precision quantization schemes with improved stability. CSQ stabilizes the bit-level mixed-precision training process with a bi-level gradual continuous sparsification on both the bit values of the quantized weights and the bit selection in determining the quantization precision of each layer. The continuous sparsification scheme enables fully-differentiable training without gradient approximation while achieving an exact quantized model in the end.A budget-aware regularization of total model size enables the dynamic growth and pruning of each layer's precision towards a mixed-precision quantization scheme of the desired size. Extensive experiments show CSQ achieves better efficiency-accuracy tradeoff than previous methods on multiple models and datasets.
translated by 谷歌翻译
The complicated architecture and high training cost of vision transformers urge the exploration of post-training quantization. However, the heavy-tailed distribution of vision transformer activations hinders the effectiveness of previous post-training quantization methods, even with advanced quantizer designs. Instead of tuning the quantizer to better fit the complicated activation distribution, this paper proposes NoisyQuant, a quantizer-agnostic enhancement for the post-training activation quantization performance of vision transformers. We make a surprising theoretical discovery that for a given quantizer, adding a fixed Uniform noisy bias to the values being quantized can significantly reduce the quantization error under provable conditions. Building on the theoretical insight, NoisyQuant achieves the first success on actively altering the heavy-tailed activation distribution with additive noisy bias to fit a given quantizer. Extensive experiments show NoisyQuant largely improves the post-training quantization performance of vision transformer with minimal computation overhead. For instance, on linear uniform 6-bit activation quantization, NoisyQuant improves SOTA top-1 accuracy on ImageNet by up to 1.7%, 1.1% and 0.5% for ViT, DeiT, and Swin Transformer respectively, achieving on-par or even higher performance than previous nonlinear, mixed-precision quantization.
translated by 谷歌翻译
Prompt Tuning, conditioning on task-specific learned prompt vectors, has emerged as a data-efficient and parameter-efficient method for adapting large pretrained vision-language models to multiple downstream tasks. However, existing approaches usually consider learning prompt vectors for each task independently from scratch, thereby failing to exploit the rich shareable knowledge across different vision-language tasks. In this paper, we propose multitask vision-language prompt tuning (MVLPT), which incorporates cross-task knowledge into prompt tuning for vision-language models. Specifically, (i) we demonstrate the effectiveness of learning a single transferable prompt from multiple source tasks to initialize the prompt for each target task; (ii) we show many target tasks can benefit each other from sharing prompt vectors and thus can be jointly learned via multitask prompt tuning. We benchmark the proposed MVLPT using three representative prompt tuning methods, namely text prompt tuning, visual prompt tuning, and the unified vision-language prompt tuning. Results in 20 vision tasks demonstrate that the proposed approach outperforms all single-task baseline prompt tuning methods, setting the new state-of-the-art on the few-shot ELEVATER benchmarks and cross-task generalization benchmarks. To understand where the cross-task knowledge is most effective, we also conduct a large-scale study on task transferability with 20 vision tasks in 400 combinations for each prompt tuning method. It shows that the most performant MVLPT for each prompt tuning method prefers different task combinations and many tasks can benefit each other, depending on their visual similarity and label similarity. Code is available at https://github.com/sIncerass/MVLPT.
translated by 谷歌翻译
量化被疯狂地作为模型压缩技术,该技术通过将神经网络中的浮点重量和激活转换为低位整数来获得有效的模型。量化已被证明可以很好地在卷积神经网络和基于变压器的模型上运行。尽管这些模型具有符合性的典型性,但最近的工作表明,基于MLP的模型能够在从计算机视觉,NLP到3D点云等各种任务上取得可比的结果,同时由于并行性和网络简单性,可以实现更高的吞吐量。但是,正如我们在论文中所显示的那样,将量化直接应用于基于MLP的模型将导致明显的准确性降解。基于我们的分析,两个主要问题说明了准确性差距:1)基于MLP的模型中的激活范围可能太大而无法量化,而2)基于MLP的模型中的特定组件对量化很敏感。因此,我们建议1)应用分层以控制激活的量化范围,2)使用有界的激活功能,3)在激活上应用百分位量化,4)使用我们的改进的模块,称为多个令牌混合MLP,5)应用线性态度敏感操作的不对称量化器。我们的Q-MLP模型配备了上述技术,可以使用8位均匀量化(型号30 MB)和78.47%的Imagenet获得79.68%的精度,而4位量化(15 MB)。
translated by 谷歌翻译
自我监督的表示学习的最新趋势集中在消除训练管道中的归纳偏见。但是,当可用数据有限时,归纳偏差在设置中可能很有用,或者提供对基础数据分布的更多见解。我们提出了空间注意(SPAN),该框架利用未标记的图像数据集中使用一致的空间和语义结构来指导视觉变压器的注意。 SPAN通过将注意力面罩从单独的变压器头正规化,以跟随语义区域的各个先验。这些先验可以从数据统计数据或域专家提供的单个标记样本中得出。我们研究了几种详细的现实情况,包括医学图像分析和视觉质量保证。我们发现,所产生的注意力面膜比从域 - 不合义预审进的掩码更容易解​​释。 SPAN可为肺和心脏分割产生58.7的地图改进。我们还发现,与结构域 - 不合稳定的预处理相比,我们的方法在将验证的模型转移到下游胸部疾病分类任务时会产生2.2个MAUC的改善。最后,我们表明,与域 - 不可屈服的预处理相比,跨越预处理会导致低数据表格中的下游分类性能更高。
translated by 谷歌翻译
当前的点云检测方法由于其有限的概括能力而难以检测现实世界中的开放式摄制对象。此外,收集和注释带有许多类别的对象的点云检测数据集和完全注释点云检测数据集非常艰辛,而且昂贵 - 云检测。据我们所知,我们是第一个研究开放式3D点云检测问题的问题。我们没有寻求带有完整标签的点云数据集,而是求助于ImagEnet1k,以扩大点云检测器的词汇。我们建议使用图像级的类监督OV-3DETIC,这是一种开放式摄影3D检测器。具体而言,我们利用了两种模式,即用于识别的图像模态和定位的点云模态,以生成看不见类的伪标签。然后,我们提出了一种新颖的跨模式对比度学习方法,将知识从图像模态转移到训练过程中的点云模态。 OV-3Detic在不损害推理期间的延迟的情况下使点云检测器能够实现开放式摄影检测。广泛的实验表明,所提出的OV-3DETIC分别在Sun-RGBD数据集和Scannet数据集上分别在SUN-RGBD数据集和扫描仪数据集上分别实现了至少10.77%的地图改进(绝对值)和9.56%的地图改进(绝对值)。此外,我们进行了足够的实验,以阐明为什么提出的OV-3Detic作品。
translated by 谷歌翻译
我们介绍Artbench-10,这是一流的平衡,高质量的,清洁的注释和标准化数据集,用于基准艺术品生成。它包括60,000幅艺术品图像,来自10种独特的艺术风格,每种样式的训练图像和1,000张测试图像。 Artbench-10比以前的艺术品数据集具有多个优势。首先,它是平衡的,而大多数以前的艺术品数据集都遭受了长时间的分布。其次,这些图像具有高质量,并带有干净的注释。第三,ArtBench-10是由标准化数据收集,注释,过滤和预处理程序创建的。我们提供三个版本的数据集,具有不同的分辨率($ 32 \ times32 $,$ 256 \ times256 $和原始图像尺寸),并以一种易于通过流行的机器学习框架来合并的方式。我们还使用具有ArtBench-10的代表性图像合成模型进行了广泛的基准测试实验,并进行了深入分析。该数据集可从https://github.com/liaopeiyuan/artbench获得公平使用许可证。
translated by 谷歌翻译
域自适应文本分类对于大规模预处理的语言模型来说是一个具有挑战性的问题,因为它们通常需要昂贵的额外标记数据来适应新域。现有作品通常无法利用跨域单词之间的隐式关系。在本文中,我们提出了一种新的方法,称为结构化知识(DASK)的域适应性,以通过利用单词级别的语义关系来增强域的适应性。 Dask首先构建知识图,以捕获目标域中的枢轴项(独立域单词)和非居式项之间的关系。然后在训练期间,DASK注入与源域文本的枢轴相关知识图信息。对于下游任务,这些注入知识的文本被馈入能够处理知识注入文本数据的BERT变体。多亏了知识注入,我们的模型根据与枢轴的关系学习了非客者的域不变特征。 DASK通过在使用伪标签训练期间通过候选枢轴的极性得分动态推断出具有域不变行为的枢轴。我们在各种跨域情绪分类任务上验证了DASK,并观察到20种不同领域对的基准的绝对性能提高了2.9%。代码将在https://github.com/hikaru-nara/dask上提供。
translated by 谷歌翻译
最近,检测变压器(DETR)是一种端到端对象检测管道,已达到有希望的性能。但是,它需要大规模标记的数据,并遭受域移位,尤其是当目标域中没有标记的数据时。为了解决这个问题,我们根据平均教师框架MTTRANS提出了一个端到端的跨域检测变压器,该变压器可以通过伪标签充分利用对象检测训练中未标记的目标域数据和在域之间的传输知识中的传输知识。我们进一步提出了综合的多级特征对齐方式,以改善由平均教师框架生成的伪标签,利用跨尺度的自我注意事项机制在可变形的DETR中。图像和对象特征在本地,全局和实例级别与基于域查询的特征对齐(DQFA),基于BI级的基于图形的原型对齐(BGPA)和Wine-Wise图像特征对齐(TIFA)对齐。另一方面,未标记的目标域数据伪标记,可用于平均教师框架的对象检测训练,可以导致更好的特征提取和对齐。因此,可以根据变压器的架构对迭代和相互优化的平均教师框架和全面的多层次特征对齐。广泛的实验表明,我们提出的方法在三个领域适应方案中实现了最先进的性能,尤其是SIM10K到CityScapes方案的结果,从52.6地图提高到57.9地图。代码将发布。
translated by 谷歌翻译
域泛化(DG)的主要挑战是克服多个训练域和看不见的测试域之间的潜在分布偏移。一类流行的DG算法旨在学习在训练域中具有不变因果关系的表示。但是,某些特征,称为\ emph {伪不变特征},可能是培训域中的不变性,但不是测试域,并且可以大大降低现有算法的性能。为了解决这个问题,我们提出了一种新颖的算法,称为不变信息瓶颈(IIB),该算法学习跨越训练和测试域的最小值的最小值。通过最大限度地减少表示和输入之间的相互信息,IIB可以减轻其对伪不变特征的依赖,这对于DG是期望的。为了验证IIB原则的有效性,我们对大型DG基准进行了广泛的实验。结果表明,在两个评估度量标准中,IIB的IIIb平均超过2.8 \%和3.8 \%的准确性。
translated by 谷歌翻译