Discriminative neural networks offer little or no performance guarantees when deployed on data not generated by the same process as the training distribution. On such out-of-distribution (OOD) inputs, the prediction may not only be erroneous, but confidently so, limiting the safe deployment of classifiers in real-world applications. One such challenging application is bacteria identification based on genomic sequences, which holds the promise of early detection of diseases, but requires a model that can output low confidence predictions on OOD genomic sequences from new bacteria that were not present in the training data. We introduce a genomics dataset for OOD detection that allows other researchers to benchmark progress on this important problem. We investigate deep generative model based approaches for OOD detection and observe that the likelihood score is heavily affected by population level background statistics. We propose a likelihood ratio method for deep generative models which effectively corrects for these confounding background statistics. We benchmark the OOD detection performance of the proposed method against existing approaches on the genomics dataset and show that our method achieves state-of-the-art performance. We demonstrate the generality of the proposed method by showing that it significantly improves OOD detection when applied to deep generative models of images.
translated by 谷歌翻译
Modern machine learning methods including deep learning have achieved great success in predictive accuracy for supervised learning tasks, but may still fall short in giving useful estimates of their predictive uncertainty. Quantifying uncertainty is especially critical in real-world settings, which often involve input distributions that are shifted from the training distribution due to a variety of factors including sample bias and non-stationarity. In such settings, well calibrated uncertainty estimates convey information about when a model's output should (or should not) be trusted. Many probabilistic deep learning methods, including Bayesian-and non-Bayesian methods, have been proposed in the literature for quantifying predictive uncertainty, but to our knowledge there has not previously been a rigorous largescale empirical comparison of these methods under dataset shift. We present a largescale benchmark of existing state-of-the-art methods on classification problems and investigate the effect of dataset shift on accuracy and calibration. We find that traditional post-hoc calibration does indeed fall short, as do several other previous methods. However, some methods that marginalize over models give surprisingly strong results across a broad spectrum of tasks.
translated by 谷歌翻译
Deep neural networks have attained remarkable performance when applied to data that comes from the same distribution as that of the training set, but can significantly degrade otherwise. Therefore, detecting whether an example is out-of-distribution (OoD) is crucial to enable a system that can reject such samples or alert users. Recent works have made significant progress on OoD benchmarks consisting of small image datasets. However, many recent methods based on neural networks rely on training or tuning with both in-distribution and out-of-distribution data. The latter is generally hard to define a-priori, and its selection can easily bias the learning. We base our work on a popular method ODIN 1 [21], proposing two strategies for freeing it from the needs of tuning with OoD data, while improving its OoD detection performance. We specifically propose to decompose confidence scoring as well as a modified input pre-processing method. We show that both of these significantly help in detection performance. Our further analysis on a larger scale image dataset shows that the two types of distribution shifts, specifically semantic shift and non-semantic shift, present a significant difference in the difficulty of the problem, providing an analysis of when ODIN-like strategies do or do not work.
translated by 谷歌翻译
在值得信赖的机器学习中,这是一个重要的问题,可以识别与分配任务无关的输入的分布(OOD)输入。近年来,已经提出了许多分布式检测方法。本文的目的是识别共同的目标以及确定不同OOD检测方法的隐式评分函数。我们专注于在培训期间使用替代OOD数据的方法,以学习在测试时概括为新的未见外部分布的OOD检测分数。我们表明,内部和(不同)外部分布之间的二元歧视等同于OOD检测问题的几种不同的公式。当与标准分类器以共同的方式接受培训时,该二进制判别器达到了类似于离群暴露的OOD检测性能。此外,我们表明,异常暴露所使用的置信损失具有隐式评分函数,在训练和测试外部分配相同的情况下,以非平凡的方式与理论上最佳评分功能有所不同,这又是类似于训练基于能量的OOD检测器或添加背景类时使用的一种。在实践中,当以完全相同的方式培训时,所有这些方法的性能类似。
translated by 谷歌翻译
深度神经网络对各种任务取得了出色的性能,但它们具有重要问题:即使对于完全未知的样本,也有过度自信的预测。已经提出了许多研究来成功过滤出这些未知的样本,但它们仅考虑狭窄和特定的任务,称为错误分类检测,开放式识别或分布外检测。在这项工作中,我们认为这些任务应该被视为根本存在相同的问题,因为理想的模型应该具有所有这些任务的检测能力。因此,我们介绍了未知的检测任务,以先前的单独任务的整合,用于严格检查深度神经网络对广谱的广泛未知样品的检测能力。为此,构建了不同尺度上的统一基准数据集,并且存在现有流行方法的未知检测能力进行比较。我们发现深度集合始终如一地优于检测未知的其他方法;但是,所有方法只针对特定类型的未知方式成功。可重复的代码和基准数据集可在https://github.com/daintlab/unknown-detection-benchmarks上获得。
translated by 谷歌翻译
变形自身偏移(VAES)是具有来自深神经网络架构和贝叶斯方法的丰富代表功能的有影响力的生成模型。然而,VAE模型具有比分布(ID)输入的分配方式分配更高的可能性较高的可能性。为了解决这个问题,认为可靠的不确定性估计是对对OOC投入的深入了解至关重要。在这项研究中,我们提出了一种改进的噪声对比之前(INCP),以便能够集成到VAE的编码器中,称为INCPVAE。INCP是可扩展,可培训和与VAE兼容的,它还采用了来自INCP的优点进行不确定性估计。各种数据集的实验表明,与标准VAE相比,我们的模型在OOD数据的不确定性估计方面是优越的,并且在异常检测任务中是强大的。INCPVAE模型获得了可靠的输入不确定性估算,并解决了VAE模型中的ood问题。
translated by 谷歌翻译
现代的深层生成模型可以为从训练分布外部提取的输入分配很高的可能性,从而对开放世界部署中的模型构成威胁。尽管已经对定义新的OOD不确定性测试时间度量的研究进行了很多关注,但这些方法并没有从根本上改变生成模型在训练中的正则和优化。特别是,生成模型被证明过于依赖背景信息来估计可能性。为了解决这个问题,我们提出了一个新颖的OOD检测频率调查学习FRL框架,该框架将高频信息纳入培训中,并指导模型专注于语义相关的功能。 FRL有效地提高了广泛的生成架构的性能,包括变异自动编码器,Glow和PixelCNN ++。在一项新的大规模评估任务中,FRL实现了最先进的表现,表现优于强大的基线可能性遗憾,同时达到了147 $ \ times $ $ $ $ $ \ times $ a的推理速度。广泛的消融表明,FRL在保留图像生成质量的同时改善了OOD检测性能。代码可在https://github.com/mu-cai/frl上找到。
translated by 谷歌翻译
Determining whether inputs are out-of-distribution (OOD) is an essential building block for safely deploying machine learning models in the open world. However, previous methods relying on the softmax confidence score suffer from overconfident posterior distributions for OOD data. We propose a unified framework for OOD detection that uses an energy score. We show that energy scores better distinguish in-and out-of-distribution samples than the traditional approach using the softmax scores. Unlike softmax confidence scores, energy scores are theoretically aligned with the probability density of the inputs and are less susceptible to the overconfidence issue. Within this framework, energy can be flexibly used as a scoring function for any pre-trained neural classifier as well as a trainable cost function to shape the energy surface explicitly for OOD detection. On a CIFAR-10 pre-trained WideResNet, using the energy score reduces the average FPR (at TPR 95%) by 18.03% compared to the softmax confidence score. With energy-based training, our method outperforms the state-of-the-art on common benchmarks.
translated by 谷歌翻译
基于密度的分布(OOD)检测最近显示了检测OOD图像的任务不可靠。基于各种密度比的方法实现了良好的经验性能,但是方法通常缺乏原则性的概率建模解释。在这项工作中,我们建议在建立基于能量的模型并采用不同基础分布的新框架下统一基于密度比的方法。在我们的框架下,密度比可以看作是隐式语义分布的非均衡密度。此外,我们建议通过类比率估计直接估计数据样本的密度比。与最近的工作相比,我们报告了有关OOD图像问题的竞争结果,这些工作需要对任务进行深层生成模型的培训。我们的方法使一个简单而有效的途径可以解决OOD检测问题。
translated by 谷歌翻译
由于其实际重要性,在提高神经网络安全部署方面的实际重要性,最近经济分配(OOD)检测最近受到了很大的关注。其中一个主要挑战是模型往往会对OOD数据产生高度自信的预测,这在ood检测中破坏了驾驶原理,即该模型应该仅对分布式样品充满信心。在这项工作中,我们提出了反应 - 一种简单有效的技术,用于减少对数据数据的模型过度限制。我们的方法是通过关于神经网络内部激活的新型分析,其为OOD分布显示出高度独特的签名模式。我们的方法可以有效地拓展到不同的网络架构和不同的OOD检测分数。我们经验证明,反应在全面的基准数据集套件上实现了竞争检测性能,并为我们的方法进行了理论解释。与以前的最佳方法相比,在ImageNet基准测试中,反应将假阳性率(FPR95)降低25.05%。
translated by 谷歌翻译
It is important to detect anomalous inputs when deploying machine learning systems. The use of larger and more complex inputs in deep learning magnifies the difficulty of distinguishing between anomalous and in-distribution examples. At the same time, diverse image and text data are available in enormous quantities. We propose leveraging these data to improve deep anomaly detection by training anomaly detectors against an auxiliary dataset of outliers, an approach we call Outlier Exposure (OE). This enables anomaly detectors to generalize and detect unseen anomalies. In extensive experiments on natural language processing and small-and large-scale vision tasks, we find that Outlier Exposure significantly improves detection performance. We also observe that cutting-edge generative models trained on CIFAR-10 may assign higher likelihoods to SVHN images than to CIFAR-10 images; we use OE to mitigate this issue. We also analyze the flexibility and robustness of Outlier Exposure, and identify characteristics of the auxiliary dataset that improve performance.
translated by 谷歌翻译
在图像分类中,在检测分布(OOD)数据时发生了许多发展。但是,大多数OOD检测方法是在一组标准数据集上评估的,该数据集与培训数据任意不同。没有明确的定义``好的''ood数据集。此外,最先进的OOD检测方法已经在这些标准基准上取得了几乎完美的结果。在本文中,我们定义了2类OOD数据使用与分布(ID)数据的感知/视觉和语义相似性的微妙概念。我们将附近的OOD样本定义为感知上相似但语义上与ID样本的不同,并将样本转移为视觉上不同但在语义上与ID相似的点数据。然后,我们提出了一个基于GAN的框架,用于从这两个类别中生成OOD样品,给定一个ID数据集。通过有关MNIST,CIFAR-10/100和Imagenet的广泛实验,我们表明A)在常规基准上表现出色的ART OOD检测方法对我们提出的基准测试的稳健性明显较小。 N基准测试,反之亦然,因此表明甚至可能不需要单独的OOD集来可靠地评估OOD检测中的性能。
translated by 谷歌翻译
检测到分布(OOD)数据是一项任务,它正在接受计算机视觉的深度学习领域越来越多的研究注意力。但是,通常在隔离任务上评估检测方法的性能,而不是考虑串联中的潜在下游任务。在这项工作中,我们检查了存在OOD数据(SCOD)的选择性分类。也就是说,检测OOD样本的动机是拒绝它们,以便降低它们对预测质量的影响。我们在此任务规范下表明,与仅在OOD检测时进行评估时,现有的事后方法的性能大不相同。这是因为如果ID数据被错误分类,将分布分配(ID)数据与OOD数据混合在一起的问题不再是一个问题。但是,正确和不正确的预测的ID数据中的汇合变得不受欢迎。我们还提出了一种新颖的SCOD,SoftMax信息保留(SIRC)的方法,该方法通过功能不足信息来增强基于软疗法的置信度得分,以便在不牺牲正确和错误的ID预测之间的分离的情况下,可以提高其识别OOD样品的能力。在各种成像网尺度数据集和卷积神经网络体系结构上进行的实验表明,SIRC能够始终如一地匹配或胜过SCOD的基线,而现有的OOD检测方法则无法做到。
translated by 谷歌翻译
We propose a method for training a deterministic deep model that can find and reject out of distribution data points at test time with a single forward pass. Our approach, deterministic uncertainty quantification (DUQ), builds upon ideas of RBF networks. We scale training in these with a novel loss function and centroid updating scheme and match the accuracy of softmax models. By enforcing detectability of changes in the input using a gradient penalty, we are able to reliably detect out of distribution data. Our uncertainty quantification scales well to large datasets, and using a single model, we improve upon or match Deep Ensembles in out of distribution detection on notable difficult dataset pairs such as Fashion-MNIST vs. MNIST, and CIFAR-10 vs. SVHN.
translated by 谷歌翻译
分发(OOD)检测和无损压缩构成了两个问题,可以通过对第一个数据集的概率模型进行训练来解决,其中在第二数据集上的后续似然评估,其中数据分布不同。通过在可能性方面定义概率模型的概括,我们表明,在图像模型的情况下,泛展能力通过本地特征主导。这激励了我们对本地自回归模型的提议,该模型专门为局部图像特征而达到改善的性能。我们将拟议的模型应用于检测任务,并在未引入其他数据的情况下实现最先进的无监督的检测性能。此外,我们使用我们的模型来构建新的无损图像压缩机:Nelloc(神经本地无损压缩机)和报告最先进的压缩率和模型大小。
translated by 谷歌翻译
已知现代深度神经网络模型将错误地将分布式(OOD)测试数据分类为具有很高信心的分数(ID)培训课程之一。这可能会对关键安全应用产生灾难性的后果。一种流行的缓解策略是训练单独的分类器,该分类器可以在测试时间检测此类OOD样本。在大多数实际设置中,在火车时间尚不清楚OOD的示例,因此,一个关键问题是:如何使用合成OOD样品来增加ID数据以训练这样的OOD检测器?在本文中,我们为称为CNC的OOD数据增强提出了一种新颖的复合腐败技术。 CNC的主要优点之一是,除了培训集外,它不需要任何固定数据。此外,与当前的最新技术(SOTA)技术不同,CNC不需要在测试时间进行反向传播或结合,从而使我们的方法在推断时更快。我们与过去4年中主要会议的20种方法进行了广泛的比较,表明,在OOD检测准确性和推理时间方面,使用基于CNC的数据增强训练的模型都胜过SOTA。我们包括详细的事后分析,以研究我们方法成功的原因,并确定CNC样本的较高相对熵和多样性是可能的原因。我们还通过对二维数据集进行零件分解分析提供理论见解,以揭示(视觉和定量),我们的方法导致ID类别周围的边界更紧密,从而更好地检测了OOD样品。源代码链接:https://github.com/cnc-ood
translated by 谷歌翻译
Accurate uncertainty quantification is a major challenge in deep learning, as neural networks can make overconfident errors and assign high confidence predictions to out-of-distribution (OOD) inputs. The most popular approaches to estimate predictive uncertainty in deep learning are methods that combine predictions from multiple neural networks, such as Bayesian neural networks (BNNs) and deep ensembles. However their practicality in real-time, industrial-scale applications are limited due to the high memory and computational cost. Furthermore, ensembles and BNNs do not necessarily fix all the issues with the underlying member networks. In this work, we study principled approaches to improve uncertainty property of a single network, based on a single, deterministic representation. By formalizing the uncertainty quantification as a minimax learning problem, we first identify distance awareness, i.e., the model's ability to quantify the distance of a testing example from the training data, as a necessary condition for a DNN to achieve high-quality (i.e., minimax optimal) uncertainty estimation. We then propose Spectral-normalized Neural Gaussian Process (SNGP), a simple method that improves the distance-awareness ability of modern DNNs with two simple changes: (1) applying spectral normalization to hidden weights to enforce bi-Lipschitz smoothness in representations and (2) replacing the last output layer with a Gaussian process layer. On a suite of vision and language understanding benchmarks, SNGP outperforms other single-model approaches in prediction, calibration and out-of-domain detection. Furthermore, SNGP provides complementary benefits to popular techniques such as deep ensembles and data augmentation, making it a simple and scalable building block for probabilistic deep learning. Code is open-sourced at https://github.com/google/uncertainty-baselines
translated by 谷歌翻译
机器学习模型通常会遇到与训练分布不同的样本。无法识别分布(OOD)样本,因此将该样本分配给课堂标签会显着损害模​​型的可靠性。由于其对在开放世界中的安全部署模型的重要性,该问题引起了重大关注。由于对所有可能的未知分布进行建模的棘手性,检测OOD样品是具有挑战性的。迄今为止,一些研究领域解决了检测陌生样本的问题,包括异常检测,新颖性检测,一级学习,开放式识别识别和分布外检测。尽管有相似和共同的概念,但分别分布,开放式检测和异常检测已被独立研究。因此,这些研究途径尚未交叉授粉,创造了研究障碍。尽管某些调查打算概述这些方法,但它们似乎仅关注特定领域,而无需检查不同领域之间的关系。这项调查旨在在确定其共同点的同时,对各个领域的众多著名作品进行跨域和全面的审查。研究人员可以从不同领域的研究进展概述中受益,并协同发展未来的方法。此外,据我们所知,虽然进行异常检测或单级学习进行了调查,但没有关于分布外检测的全面或最新的调查,我们的调查可广泛涵盖。最后,有了统一的跨域视角,我们讨论并阐明了未来的研究线,打算将这些领域更加紧密地融为一体。
translated by 谷歌翻译
检测分配(OOD)输入对于安全部署现实世界的深度学习模型至关重要。在评估良性分布和OOD样品时,检测OOD示例的现有方法很好。然而,在本文中,我们表明,当在分发的分布和OOD输入时,现有的检测机制可以极其脆弱,其具有最小的对抗扰动,这不会改变其语义。正式地,我们广泛地研究了对共同的检测方法的强大分布检测问题,并表明最先进的OOD探测器可以通过对分布和ood投入增加小扰动来容易地欺骗。为了抵消这些威胁,我们提出了一种称为芦荟的有效算法,它通过将模型暴露于对抗性inlier和异常值示例来执行鲁棒训练。我们的方法可以灵活地结合使用,并使现有方法稳健。在共同的基准数据集上,我们表明芦荟大大提高了最新的ood检测的稳健性,对CiFar-10和46.59%的CiFar-100改善了58.4%的Auroc改善。
translated by 谷歌翻译
深度神经网络拥有的一个重要股权是在以前看不见的数据上对分发检测(OOD)进行强大的能力。在为现实世界应用程序部署模型时,此属性对于安全目的至关重要。最近的研究表明,概率的生成模型可以在这项任务上表现不佳,这令他们寻求估计培训数据的可能性。为了减轻这个问题,我们提出了对变分性自动化器(VAE)的指数倾斜的高斯先前分配。通过此之前,我们能够使用VAE自然分配的负面日志可能性来实现最先进的结果,同时比某些竞争方法快的数量级。我们还表明,我们的模型生产高质量的图像样本,这些样本比标准高斯VAE更清晰。新的先前分配具有非常简单的实现,它使用kullback leibler发散,该kullback leibler发散,该横向leibler发散,该分解比较潜伏向量的长度与球体的半径之间的差异。
translated by 谷歌翻译