While deep neural networks (DNNs) have demonstrated impressive performance in solving many challenging tasks, they are limited to resource-constrained devices owing to their demand for computation power and storage space. Quantization is one of the most promising techniques to address this issue by quantizing the weights and/or activation tensors of a DNN into lower bit-width fixed-point numbers. While quantization has been empirically shown to introduce minor accuracy loss, it lacks formal guarantees on that, especially when the resulting quantized neural networks (QNNs) are deployed in safety-critical applications. A majority of existing verification methods focus exclusively on individual neural networks, either DNNs or QNNs. While promising attempts have been made to verify the quantization error bound between DNNs and their quantized counterparts, they are not complete and more importantly do not support fully quantified neural networks, namely, only weights are quantized. To fill this gap, in this work, we propose a quantization error bound verification method (QEBVerif), where both weights and activation tensors are quantized. QEBVerif consists of two analyses: a differential reachability analysis (DRA) and a mixed-integer linear programming (MILP) based verification method. DRA performs difference analysis between the DNN and its quantized counterpart layer-by-layer to efficiently compute a tight quantization error interval. If it fails to prove the error bound, then we encode the verification problem into an equivalent MILP problem which can be solved by off-the-shelf solvers. Thus, QEBVerif is sound, complete, and arguably efficient. We implement QEBVerif in a tool and conduct extensive experiments, showing its effectiveness and efficiency.
翻译:虽然深神经网络(DNNS)在解决许多具有挑战性的任务方面表现出了令人印象深刻的成绩,但由于对计算动力和存储空间的需求,这些网络仅限于资源紧张的装置。量化是解决这一问题最有希望的方法之一,其方法是对数字NNS及其四分点对应方之间的权重进行量化和(或)将数字NNN的振标启动到小位宽的固定点数中。虽然量化在经验上表明引入了微小的准确性损失,但缺乏这方面的正式保证,特别是当由此产生的量化的神经网络(QNNNS)被部署在安全关键应用程序中时。现有核查方法大多只侧重于单个的神经网络网络,无论是DNNNNNN(D)还是QNNNN(QNNN),其重量和启动的对QNL(Q-R-R-R)的轨距值分析,其QR-QR(QR-RO-RI)在对Q-QR-Q-RO-I-I(QR-I-I-Qral-deal-deal-deal-deal-deal-deal-deal-deal-deal-deal-deal-deal-deal-deal-deal) 分析中,它能化了QI-deal-deal-deal-deal-I)一个Q-deal-deal-deal-de-I) 和对QL 和对Q-Q-QQ-I-I-I-I-Q-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-I-