Data-Driven Lipschitz Continuity: A Cost-Effective Approach to Improve Adversarial Robustness

## Abstract

Abstract The security and robustness of deep neural networks (DNNs) have become increasingly concerning. This paper aims to provide both a theoretical foundation and a practical solution to ensure the reliability of DNNs. We explore the concept of Lipschitz continuity to certify the robustness of DNNs against adversarial attacks, which aim to mislead the network with adding imperceptible perturbations into inputs. We propose a novel algorithm that remaps the input domain into a constrained range, reducing the Lipschitz constant and potentially enhancing robustness. Unlike existing adversarially trained models, where robustness is enhanced by introducing additional examples from other datasets or generative models, our method is almost cost-free as it can be integrated with existing models without requiring re-training. Experimental results demonstrate the generalizability of our method, as it can be combined with various models and achieve enhancements in robustness. Furthermore, our method achieves the best robust accuracy for CIFAR10, CIFAR100, and ImageNet datasets on the RobustBench leaderboard.

## 1 Introduction

Deep neural networks (DNNs) have demonstrated promising results across various tasks [, ], prompting concerns about AI security as these networks are increasingly deployed in our daily lives. A single erroneous prediction could lead to catastrophic consequences. For example, the Overload attack can significantly inflate the inference time of detecting objects for self-driving systems [], while even minor typos in input prompts can cause large language models (LLMs) to produce unexpected responses [].

The focus of this paper is to design robust DNNs that can defend against adversarial attacks, which aim to create perturbations in inputs that are imperceptible to humans but can mislead DNNs. Previous studies have revealed the existence of adversarial examples in diverse domains, such as image pixels [], audio data [], and textual content []. Consequently, exploring the vulnerabilities of DNNs and developing theoretically grounded explainable AI is crucial for ensuring the reliability of DNN-based applications.

Adversarial training [] has proven to be an effective strategy for enhancing the robustness of DNNs. It achieves this by generating adversarial examples on the fly during the training phase and optimizing the model’s weights to minimize the losses caused by these examples. Recent studies have shown that robustness can be further improved by introducing additional examples from other datasets [] or using generative models [, ] to cover low-frequency data. Despite the promising improvements in robustness, training costs increase significantly due to the demand for additional data, which can be up to 20 to 100 times larger than the original dataset. This poses a trade-off between training cost and robustness. The concern over high computational costs becomes a significant obstacle in deploying robust DNN-based applications, especially in fields like medicine, autonomous driving systems, and other areas where human lives are at stake.

In this paper, we explore how robustness is certified by the theorem of Lipschitz continuity, which theoretically gauges how much outputs are amplified by the perturbations. However, we argue that the set of observed data is finite and cannot cover the entire real data space,
leading to an overestimation of the Lipschitz constant derived from the theorem. Therefore, we propose an algorithm that can remap the input domain into a constrained range, resulting in a Lipschitz constant for the modified function that is less than or equal to the Lipschitz constant of the original function, thus potentially enhancing robustness. Our key contributions are outlined as follows:

- •
We introduce the concept of the empirical Lipschitz constant, which can more precisely reflect the robustness of the corresponding observed data. Compared with the original definition of Lipschitz constant, the empirical value is derived from a set of observed data, thereby eliminating the influence of space that is never drawn from real data.
As illustrated in Figure 1, we prove that any function that can be formulated as a linear system, when combined with our proposed function to remap the input domain of a specific layer to a constrained range, can reduce its empirical Lipschitz constant, resulting in better robustness.
- •
The proposed function can enhance the robustness of adversarially trained models with minimal additional costs. Specifically, it introduces only one parameter, the value of which can be determined by scanning an observed data once without the need for re-training or fine-tuning.
- •
The experimental results suggest that our method can be combined with various existing methods and gain robustness improvements. Besides, our method achieves the best robust accuracy against adversarial examples generated by AutoAttack [], a state-of-the-art ensemble attack, for CIFAR10, CIFAR100, and ImageNet datasets on the RobustBench leaderboard [].
By assessing accuracy against adaptive attacks, transfer attacks, and evaluation methods for validating obfuscated gradients [, ], we believe that the proposed algorithm should not cause robustness to be overestimated.

Figure: Figure 1: The empirical Lipschitz constant of specific layers that can be represented by linear systems, such as convolutional or fully connected layers, can be reduced by remapping their input domain to a constrained range.
Refer to caption: x1.png

The rest of this paper is organized as follows. Section 2 introduces the background on adversarial attacks and adversarial training. Section 3 presents the theoretical proof of how robustness is enhanced by manipulating the domain of linear functions and introduces the proposed algorithm. Section 4 shows the experimental results, including the comparisons among related works, and ablation studies on various hyper-parameters, combination with different activation functions and gradient masking verification. The last section is our conclusion.

## 2 Related Works

### 2.1 Adversarial Attacks

Adversarial attacks aim to inject tiny perturbations into inputs, causing victim DNNs to output incorrect predictions with high confidence []. These attacks have been observed in numerous vision applications [, , , ]. Furthermore, these tiny perturbations can be embedded not only in image pixels but also in textual contexts [, ], audio space [], and other fields []. Some research has shown how adversarial attacks threaten real applications [, , , ]. Investigating the vulnerability of DNNs and theoretically avoiding adversarial examples when optimizing model weights or designing architecture is an ongoing challenge.

Depending on the amount of information the attacker has access to, adversarial attacks can be divided into two types: white-box attacks and black-box attacks. For white-box attacks, all information about the victim models is public. Attackers can craft adversarial examples through the gradient direction, which is usually opposite to the direction in which the model weights were optimized during the training phase [, ]. Although this scenario is unrealistic, this type of research could lead to the design of more reliable models in the future. Conversely, for black-box attacks, the only information leaked to the attacker is the output prediction of the victim model. Adversarial examples can be generated by random search [], discrepancies in outputs [], or transferability from models with similar architectures [, ]. The purpose of black-box attacks is to study the risk of the victim models being attacked in real-world application scenarios.

### 2.2 Defensive Strategies

Adversarial training is a defensive strategy that aims to find optimal weights against adversarial attacks [, , ]. It achieves this by generating adversarial examples on the fly during the training phase and optimizing the model’s weights to minimize the losses caused by these examples. Despite the superior robustness achieved by adversarial training, the associated training costs of adversarially trained models are generally ten times more expensive than those of models trained utilizing a standard policy. The concern over high computational costs becomes a significant obstacle in deploying DNN-based applications.

Balancing between training cost and robustness is a challenge for adversarial training. Fast adversarial training has been proposed for applications pursuing higher robustness under a limited budget [, ]. However, numerous adversarial examples cannot be drawn from these approaches, potentially leading to catastrophic overfitting, where robust accuracy significantly decreases without warning signs []. On the contrary, some studies attempted to refine robustness by introducing additional examples from other datasets [] or using generative models [, ]. Alternatively, another line of research has demonstrated that the removal of partial adversarial examples does not compromise robust accuracy, addressing the issue of unaffordable training costs [, ].

Despite the potential of adversarial training to enhance model robustness, budgetary constraints often limit the scope of their crafting to one or two specific attack types during the training stage. This restricted approach may inadvertently render adversarially trained models susceptible to novel, unseen attacks. As an alternative, Lipschitz-based certified training offers a theoretical framework for ensuring an upper bound on prediction errors [, , ]. However, it is important to acknowledge that these training methods often suffer from scalability issues.

## 3 Methodology

### 3.1 Motivation

In this paper, we approach robustness from a theoretical perspective, aiming to demonstrate that all risks posed by adversarial examples are limited while minimizing the additional costs associated with improving robustness. Our evaluation is conducted under the white-box scenario, where the target model is capable of defending against various types of known adversarial attacks, including white-box attacks [, , ], black-box attacks [], and transfer attacks [, ]. Additionally, we conduct a set of experiments to verify that gradient masking [] does not occur in our method and to ensure that robustness is not overestimated.

### 3.2 Lipschitz Continuity

To achieve our goal, we introduce a quantitative metric known as the Lipschitz constant, which gauges how much outputs are amplified by the perturbations within the input domain. The mathematical definition is as follows, a function $f:\mathbb{R}^{m}\rightarrow\mathbb{R}^{n}$ is globally Lipschitz continuous if there exists an constant $K\geq 0$ such that

$$ $D_{f}(f(x_{1}),f(x_{2}))\leq KD_{x}(x_{1},x_{2})\quad\forall x_{1},x_{2}\in \mathbb{R}^{m},$ (1) $$

where $D_{x}$ is a metric on the domain of $f$; $D_{f}$ is a metric on the range of $f$; and $x_{1}\neq x_{2}$. For a DNN, it can be considered as a composite function:

$$ $F(x)=(f_{1}\circ f_{2}\circ\dots\circ f_{L})(x),$ (2) $$

where $f_{i}$ is the function of $i$-th layer. If there exists a Lipschitz constant for each individual layer, we can derive an upper bound of the Lipschitz constant for the victim model as follows,

$$ $K_{F}\leq\prod_{i=1}^{L}K_{i},$ (3) $$

where $K_{i}$ is the Lipschitz constant of $f_{i}$.

By defining adversarial examples $x^{\text{adv}}$ within a $\epsilon$-ball centered at an image $x$ as the inputs of (1), we can assess the impact caused by adversarial examples. Therefore, the Lipschitz constant serves as a bridge that connects the design of robust models with the measurement of risks posed by adversarial examples. A small Lipschitz constant for the victim model implies that the increase in loss is minimal, indicating a higher ability to resist adversarial attacks. Consequently, the objective of this paper is to lower the upper bound of Lipschitz constant for the given models.

As indicated by previous studies [, ], Lipschitz constant of the given model defined in (3) can be minimized by reducing the output discrepancy of individual linear layers. Under the $L_{2}$ norm, we have

$$ $\frac{||f(x^{\text{adv}})-f(x)||_{2}}{||x^{\text{adv}}-x||_{2}}=\frac{(||Wx^{ \text{adv}}+b)-(Wx+b)||_{2}}{||\delta||_{2}}=\frac{||W\delta||_{2}}{||\delta|| _{2}},$ (4) $$

where $W$ is the weight matrix; and $\delta$ is the distance between $x^{\text{adv}}$ and $x$. Therefore, the original optimization problem of minimizing Lipschitz constant is transformed into the following minimization problem:

$$ $\min_{W}\max_{\delta\neq 0,\delta\in\mathbb{R}^{m}}\frac{||W\delta||_{2}}{|| \delta||_{2}}=\min_{W}\sigma_{\text{max}}(W),$ (5) $$

where $\sigma_{\text{max}}(W)$ represents the largest singular value of the matrix $W$. Notably, there is a relation to eigenvalues:

$$ $\sigma^{2}_{i}(W)=\lambda_{i}(WW^{\dagger})=\lambda_{i}(W^{\dagger}W),$ (6) $$

where $W^{\dagger}$ is the conjugate transpose of $W$. Each singular value of the matrix $W$ is the square root of the eigenvalue of the matrices $WW^{\dagger}$ or $W^{\dagger}W$. In other words, minimizing $\lambda_{\text{max}}(WW^{\dagger})$, the largest eigenvalue of the matrices, can achieve the same objective.

Rather that minimizing the objective directly, Gershgorin circle theorem provides an alternative solution to estimate the robustness of the given linear system.

###### Theorem 1 .

(Gershgorin Circle Theorem)
For an $m\times m$ matrix $A$ with entries $a_{ij}$, each eigenvalue of $A$ is in at least one of the disk:

$$ $R_{i}=\{z\in\mathbb{C}:|z-a_{ii}|\leq\sum_{i\neq j}|a_{ij}|\}\quad\mathrm{for} \quad i=\{1,2,\ldots,m\}.$ (7) $$

Theorem 1 indicates each row vector can be represented as a disk which is centered at the diagonal entry $a_{ii}$ and whose radius is the sum of the off-diagonal entries $a_{ij}$. For any layer which can be represented by a linear system, such as convolutional or fully connected layers, robustness can be improved by shrinking the radius of the disk with the largest eigenvalue.

###### Theorem 1 .

### 3.3 Forged Function

Figure: (a) ConvNet
Refer to caption: x2.png

We argue that the largest singular value provides a loose bound for the Lipschitz constant. To precisely reflect the robustness of the corresponding observed data, we define the empirical Lipschitz constant that eliminates the influence of space that is never drawn from real data.

###### Definition 1 .

Empirical Lipschitz constant:

$$ $\max_{\delta\neq 0,x\in\mathcal{S}}\frac{||Wx||_{2}}{||x||_{2}}\quad\forall x \in\mathcal{S},$ (8) $$

where $\mathcal{S}$ is an observed dataset.
As can be seen, the empirical Lipschitz constant on the finite dataset is less than or equal to its Lipschitz constant derived from the theorem.

Based on Definition 1, we can build robust models by manipulating the output ranges of individual layers, thereby restricting the input domain of the next layer. If input vectors do not align with the direction of the eigenvector with the largest eigenvalue, the empirical constant should be bounded. Therefore, we proposed a forged function defined as follows:

$$ $f^{\text{forge}}(x)=\begin{cases}0\quad&\text{if}\quad|x|\leq c^{\text{th}}_{i },\\ x\quad&\text{otherwise},\end{cases}$ (9) $$

where $c^{\text{th}}_{i}$ is a threshold for the $i$-th layer. Compared with the original functions, the range of the forged function is suppressed if its value is less than the threshold. When $c^{\text{th}}_{i}$ is set to 0 0, the forged function degrades into the original function.

The forged function aim to reduce the empirical Lipschitz constant of the layers that can be represented as linear systems by remapping the input domain of these layers into a constrained set. Figure 2 provides a visual representation of potential insertion points for the forged function, while maintaining the integrity of other layers. For the ResNet architecture, the forged function is placed before the convolutional layers in each residual block. Similarly, for vision transformer architectures, the structure of MLP layers is adapted to seamlessly integrate the forged function.

Here is the proof that the largest eigenvalue can be shrunk by the forged function. Let $W$ be the weight of the target layer, which can be represented by an $m\times n$ matrix, and t be the input vector. Without loss of generality, we assume that $A=W^{\dagger}W$ and $f^{\text{forge}}(\textbf{t})$ is defined as:

$$ $f^{\text{forge}}(t_{i})=\begin{cases}0\quad i\leq k\\ t_{i}\quad\text{otherwise},\end{cases}$ (10) $$

where $t_{i}$ is the $i$-th element of t and $k$ is a positive number.

###### Lemma 2 .

There exists a matrix $A^{\prime}$ whose largest eigenvalue, $\lambda_{\text{max}}(A^{\prime})$, is less than or equal to the largest eigenvalue of $A$, $\lambda_{\text{max}}(A)$, if

$$ $Af^{\text{forge}}(\textbf{t})=A^{\prime}\textbf{t}.$ (11) $$

###### Proof.

Since the first $k$ entries of the vector t are replaced with zeros, above condition can be achieved by replacing the corresponding column vectors of the matrix $A$ with zero vectors. Therefore, the entries of $A^{\prime}$ are formulated as

$$ $a^{\prime}_{ij}=\begin{cases}0\quad j\leq k\\ a_{ij}\quad\text{otherwise}.\end{cases}$ (12) $$

The matrix $A$ is a positive semidefinite matrix, implying that the diagonal entries are non-negative. Moreover, with the entry representation of $A^{\prime}$ in (12), we observe that modifications are only applied to the first $k$ columns, while the rest remain unchanged. Combining the Gershgorin Circle Theorem, we know that the centers of the first $k$ disks of the matrix $A^{\prime}$ are shifted towards zero. Additionally, the radii of all disks, the absolute values of the off-diagonal entries in $A^{\prime}$, are shrunk. Consequently, the upper bound of the largest eigenvalue of the matrix $A^{\prime}$ is tighter compared to that of the original matrix $A$.
∎

Notably, the outputs of $f^{\text{forge}}(\textbf{t})$ vary depending on the inputs, resulting in each input having its own $A^{\prime}$. The upper bound of the largest eigenvalue of each matrix $A^{\prime}$ must be not greater than the largest eigenvalue of the matrix $A$. With Lamma 2, a precise upper bound of the largest eigenvalue can be obtained by feeding a set of observed images. On the contrary, there might be cases in which solving the minimization problem in (5) leads to the theoretical largest eigenvalue being minimized, but the empirical Lipschitz constant remains unchanged.

The choice of a proper $c^{\text{th}}_{i}$ is a crucial factor in reducing the largest eigenvalue.
In this paper, we propose obtaining the value of $c^{\text{th}}_{i}$ through the following equation:

$$ $c^{\text{th}}_{i}=c^{r}\max(F_{1\rightarrow i}(x))\quad\forall x\in\mathcal{S},$ (13) $$

where $\mathcal{S}$ can include all or a subset of images in the training set, $c^{r}$ is a positive number and $F_{1\rightarrow i}(x)$ represents the output of the $i$-th layer. Specifically, each layer has its own $c^{\text{th}}_{i}$, but they share the same hyper-parameter $c^{r}$. Algorithm 1 specifies the implementation details of the forged function. The variable $b$ is used to store the maximum value that appeared in $\mathcal{S}$, as defined in (13), and is initialized during construction. Similar to the implementation of the batchnorm layer, the behavior is depended on the mode configuration. When the mode is set to tracking mode, the variable $b$ is updated accordingly, and the input is set to the output without any modification. Conversely, when the mode is set to inference mode, the value of $b$ is frozen, but the input is updated as defined by (9). By default, the mode is set to inference, and the values of $b$ and $c^{r}$ are zero, respectively. As a result, the set $\mathcal{M}$ is empty, and the algorithm is degraded to the identical function.

It is worth emphasizing that by feeding all images in the set $\mathcal{S}$ once in track mode beforehand, the value of $c^{\text{th}}_{i}$ can be obtained. The elements satisfying the constraints are appropriately deactivated during inference. Notably, this operation does not necessitate gradient computations and incurs minimal time consumption, typically only a few minutes, even when executed on commonly used GPUs. In comparison to adversarial training, this process is nearly cost-free. The overall procedure shares many similarities with post-pruning techniques. Nevertheless, we posit that the proposed function is very similar to the ReLU function, as it suppresses the output values within a specific range, but the defined range in the forged function is adaptive to the observed dataset.

Figure: Algorithm 1 Forged Function

###### Definition 1 .

###### Lemma 2 .

###### Proof.

## 4 Experiments

### 4.1 Setup

We evaluated the performance on CIFAR10, CIFAR100, and ImageNet datasets under the white-box scenario with an $L_{\infty}$ norm. To ensure comparability of results, we assessed robustness using AutoAttack [], For CIFAR10 and CIFAR100 datasets, $\epsilon$ is set to $8/255$, while for the ImageNet dataset, $\epsilon$ is set to $4/255$. The model weights are publicly accessible from RobustBench. The ablation study involves exploring the selection of the optimal $c^{r}$, the combination of various models trained from different techniques, the verification of gradient masking, and assessments of certified adversarial robustness via randomized smoothing. Due to the page limit, the full experimental results of the ablation study are listed in Appendix.

### 4.2 White-box Evaluation

#### 4.2.1 Performance Analysis on CIFAR10 and CIFAR100 Datasets

**Table 1: The results of top-3 competitors on Robustbench.**
| # | Method | accnat | accAA |
| --- | --- | --- | --- |
| * | [] + Ours | 93.20 | 71.70 |
| 1 | [] | 93.27 | 71.07 |
| 2 | [] | 93.25 | 70.69 |
| 3 | [] | 95.19 | 69.71 |

The model used in this study is based on WRN-70-16 architecture with SiLU function while generative data were involved during the training phase. The value of $c^{\text{th}}_{i}$ is obtained by feeding all images from the training set without any augmentation, and $c^{r}$ was set to $2^{-8}$ for this experiment. Tables 1(a) and 1(b) summarize the top-3 competitors on Robustbench for CIFAR10 and CIFAR100 datasets, respectively, where $\#$ represent the rankings, our results are marked by the asterisk (*), accnat and accAA denote the accuracy against clean data and adversairal examples generated by AutoAttack, respectively.

As can be seen, our method combined with WRN-70-16 with SiLU function gains improvement in robustness by at least 0.9% and achieves the best results on Robustbench for both datasets. Nevertheless, standard accuracy (accnat) is decreased. Many factors might affect the results. For example, the single additional hyper-parameter introduced in this study might not provide sufficient granularity to fit all layers in the target model.

#### 4.2.2 Performance Analysis on ImageNet Dataset

**Table 2: The results of top-3 competitors for ImageNet dataset on Robustbench.**
| # | Method | Architecutre | accnat | accAA |
| --- | --- | --- | --- | --- |
| * | [] + Ours | Swin-L | 78.88 | 60.04 |
| 1 | [] | Swin-L | 78.92 | 59.56 |
| 2 | [] | ConvNeXtV2-L + Swin-L | 81.48 | 58.50 |
| 3 | [] | ConvNeXt-L | 78.02 | 58.48 |

In this experiment, we utilized the Swin [] model architecture, a variant of transformers. However, scanning the approximately 1.2 million training images provided by the ImageNet dataset to determine the value of the hyper-parameter introduced in the forged function defined in (13) might take a long time. Alternatively, we randomly selected about 5,000 images as the observed images to determine the value of the hyper-parameter.
Ideally, determining the optimal choice of $c^{r}$ requires conducting an ablation study to explore the relationship between the chosen $c^{r}$ and robust accuracy on a validation set. To accelerate this procedure, we first seek a value of $c^{r}$ with the highest standard accuracy. The candidate values are selected in a small range centered around this value.

Tables 2 lists the top-3 competitors on Robustbench for ImageNet dataset, including ranking, architecture, standard accuracy, and robust accuracy against AutoAttack. The experimental results demonstrate that the Swin-L model with GELU combined with our method can obtain improvements in robust accuracy and achieve the best result while standard accuracy has a tiny drop. This finding verifies that our method can be applied to both convolutional and fully connected layers.

#### 4.2.3 Combination with Various Models

The experiment aims to assess the generability of the proposed function on adversarial trained models with identical architecture but from various training strategies and to evaluate the potential cost reduction of adversarial training. We integrated the proposed approach with partial models selected from RobustBench, whose weights are obtained directly from the official without any modifications, and also included a model trained by TRADES [] as a baseline for CIFAR10 dataset. The selected models were trained using different techniques, such as adding perturbations in internal layers, retrieving information using knowledge distillation, reducing inefficient training data, or involving additional images from generated models or another dataset. Except for the model used in RST-WAP, which is WRN-28-10, the model architecture we utilized is WRN-34-10 with ReLU, as it is the most popular network on the RobustBench leaderboard [].

For the white-box evaluation, the value of $c^{r}$ is set to $2^{-7}$. Table 3(a) and 3(b) present standard and robust accuracy of models integrated with our method for CIFAR10 and CIFAR100 dataset, respectively. In these tables, the column Original indicates the original results reported by RobustBench, and the column Original+Ours demonstrates the results of the proposed method. As indicated in these tables, for CIFAR10 dataset, the proposed method enhances robust accuracy by more than $2\%$ for RST-AWP, DefEAT, and LTD models, while other models receive approximately $1$ to $1.5\%$ improvement in robustness. Similarly, for CIFAR100 dataset, these models meet at least a $1\%$ increase in robustness. The empirical results prove that the resilience of existing models against adversarial attacks can be improved by Lemma 2. We believe that the proposed solution is general as it achieves great success in models incorporating different training techniques.

Another advantage of the proposed method that we would like to highlight is that the cost of our approach can almost be ignored compared to the cost of adversarial training as the cost involves only a single pass scan of a set of images to determine the hyper-parameter $c^{th}$. This implies that these models can enhance robustness for free. Specifically, LefEAT can achieve a robust accuracy of 57.30% by removing inefficient training data. By combining LefEAT model with our approach, a robust accuracy of 59.55% can be achieved, which is comparable to RST-AWP (60.04%). However, RST-AWP introduces more images from another dataset, resulting in a higher cost in each epoch. Similarly, for the CIFAR100 dataset, DefEAT with our proposed method achieves a robust accuracy of 32.11%, which is better than EffAug (31.85%), which involves more complex data augmentation during the training stage. This aligns with the suggestion by DefEAT that some data can be removed without hurting robustness. Holistically, we believe that our approach might provide a hint during the late phase of adversarial training to drop inefficient weights, resulting in further cost savings or enhanced resilience.

Another interesting observation presented in these tables is that standard accuracy is also improved for all models on both CIFAR10 and CIFAR100 datasets. Although this phenomenon cannot be explained by Lemma 2, we believe that the output range between ReLU and the proposed functions has a high similarity. Consequently, this arrangement can maintain the accuracy of clean data.

Table: Table 3: Standard and robust accuracy of models integrated with our method.

#### 4.2.4 Gradient Masking Verification

Previous studies suggest that the resilience of models might be unintentionally overestimated [, ]. The proposed function in (9) suppresses values to zero if the condition is satisfied. One might argue that this property could unintentionally cause obfuscated gradients, resulting in gradient attacks being unable to efficiently produce adversarial examples. Therefore, to verify that the proposed method does not encounter the gradient masking issue, we should conduct more experiments from the following aspects:

- 1.
White-box attacks should be better than black-box attacks.
- 2.
Iterative attacks should have better performance than one-step attacks.
- 3.
Robust accuracy should gradually decrease to zero when the radius of $\epsilon$-ball increase.
- 4.
The modified model should defense against adversarial examples generated by the original models.
- 5.
Certified robustness that conducted by random smoothing [].

The first item has been examined by AutoAttack as it involves three white-box attacks and one black-box attack. By compared robust accuracy shown in Table 1(a), 1(b) and 2, the models combined with the proposed method perform better robust accuracy than the original models. It indicates black-box cannot produce more adversarial examples.

The full experimental results for the rest of experiments can be found in the appendix. The results demonstrate that the proposed algorithm does not violate any of the above rules and the certified robustness improves by our method across most settings. From the evidence, we believe that the proposed method does not encounter the gradient masking problem among different hyper-parameters and various models on CIFAR10 and CIFAR100 datasets.

## 5 Conclusion

In this paper, we recap how robustness is certified by the theorem of Lipschitz continuity. We introduce the concept of the empirical Lipschitz constant, which minimizes the influence of the space not drawn from real data, resulting in a precise estimation of the robustness of the corresponding observed data. We prove that by remapping the input domain of a specific layer to a constrained range, the Lipschitz constant can be shrunk, leading to better robustness. The proposed function introduces only one parameter, the value of which can be determined by scanning the training data once, without re-training or fine-tuning. Compared with adversarial training, the proposed method is almost cost-free. The experimental results suggest that our method can be combined with various existing methods and achieve robustness improvements, and no gradient masking occurs in our algorithm. Furthermore, our method can achieve the best robust accuracy for CIFAR10, CIFAR100, and ImageNet datasets on the RobustBench leaderboard.

Numerous future directions merit exploration. Firstly, due to the property of maximization, the proposed function might easily be influenced by outliers. Designing a better function is an interesting research topic. Secondly, exploring the combination with various activation functions, different model architectures or large-scale datasets would be beneficial. Lastly, it is worth investigating to understand the theoretical reasons why our proposed function improves standard accuracy.

## Appendix A Ablation Study

### A.1 Hyper-parameter Selection

This experiment investigates how the choice of hyper-parameter $c^{r}$ influences standard accuracy and robust accuracy. Since most models are represented in 16 bit format, and the widths of fraction bit for FP16 format defined by IEEE-754 standard and BFloat are 10 and 7 bits, respectively, truncated errors might easily occur when performing addition on two numbers with a magnitude difference of $2^{8}$ or higher. On the other hand, when $c^{r}$ is set to $2^{-5}$, all models experience a significant drop in standard accuracy, and there is meaningless in evaluating robustness at this configuration. We suggest that the candidates of $c^{r}$ are $2^{-8}$, $2^{-7}$ and $2^{-6}$.

The results on CIFAR10 and CIFAR100 are presented in Table 5 and Table 5, respectively. Moreover, the results of accuracy against CW attack on $L_{\infty}$ norm for CIFAR10 and CIFAR100 datasets are presented in Tables 6(a) and 6(b), respectively. As can be seen, when $c^{r}$ is set to $2^{-8}$, all models achieve better standard accuracy and robust accuracy. Additionally, the results for all models with $c^{r}=2^{-7}$ are surpassed by those when $c^{r}$ is set to $2^{-8}$. Robust accuracy can be further enhanced by setting $2^{-6}$, while standard accuracy might drop compared to the original. The results suggest that $c^{r}=2^{-7}$ is a solution that balances standard accuracy and robustness. Nevertheless, when robustness is a major concern, $c^{r}=2^{-6}$ is a better choice.

Intuitively, we expect that standard accuracy gradually decreases when the value of $c^{r}$ increases. The phenomenon can be observed when $c^{r}$ is $2^{-6}$ or higher but two counterexamples are reported in the ablation study when setting $c^{r}$ to $2^{-7}$ and $2^{-8}$. A possible explanation is that the optimizer becomes stuck in a saddle area, as ReLU is non-differentiable at the zero point. This might cause the gradient direction to become stuck in an oscillation when values are close to zero. By shifting those values to zero, antagonistic effects among different feature maps, filters, or channels are accidentally mitigated. However, further investigation and evidence are needed to support this conjecture.

We argue that any function that satisfies the conditions defined in (11) can shrink the largest eigenvalue. There might be another function that can perform better than the proposed one. Besides, the hyper-parameter is determined by choosing the maximum value appearing in the dataset.

**Table 4: Ablation study of selecting optimal $c^{r}$ for CIFAR10 dataset.**
| Method | RobustBench | $c^{r}=2^{-8}$ | $c^{r}=2^{-7}$ | $c^{r}=2^{-6}$ |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- |
| accnat | accAA | accnat | accAA | accnat | accAA | accnat | accAA |  |
| RST-AWP | 88.25 | 60.04 | 88.82 | 60.96 | 89.50 | 62.76 | 87.88 | 61.96 |
| DefEAT | 86.54 | 57.30 | 86.88 | 57.81 | 87.40 | 59.55 | 84.59 | 61.08 |
| LTD | 85.21 | 56.94 | 85.28 | 57.28 | 85.98 | 59.25 | 85.59 | 60.63 |
| AWP | 85.36 | 56.17 | 85.80 | 56.53 | 86.19 | 57.85 | 84.55 | 59.21 |
| TRADES | 85.34 | 52.86 | 85.57 | 52.97 | 85.78 | 53.80 | 85.49 | 55.37 |

## Appendix B Full Experimental Results of Gradient Masking Verification

**Table 6: The robust accuracy against CW attack on $L_{\infty}$ norm.**
| Method | Origin | $c^{r}$ |  |  |
| --- | --- | --- | --- | --- |
| $2^{-8}$ | $2^{-7}$ | $2^{-6}$ |  |  |
| RST-AWP | 58.98 | 61.84 | 68.24 | 80.92 |
| DefEAT | 56.92 | 58.02 | 61.06 | 65.56 |
| LTD | 58.12 | 58.56 | 60.50 | 64.86 |
| AWP | 56.84 | 57.34 | 60.58 | 66.50 |
| TRADES | 56.10 | 56.52 | 58.18 | 63.62 |

Table 7(a) and 7(b) present the robust accuracy against adversarial examples generated by the original models on CIFAR10 and CIFAR100 datasets, respectively. As observed, none of the models showed lower robust accuracy than the original model. It indicates that adversarial examples can be efficiently crafted by utilizing the gradients from the victim models.

Table 8 and 9 presents the robust accuracy against FGSM and PGD attacks among different radii of the $\epsilon$-ball on the CIFAR10 and CIFAR100 datasets, respectively. As observed, the robust accuracy against FGSM, a one-step attack, is always higher than the robust accuracy against PGD, an iterative attack. This implies that the gradient is reliable, allowing the PGD attack to adjust the gradient direction multiple times to find adversarial examples. Additionally, we observe that the robust accuracy against PGD attacks for all models gradually decreases to zero as the radius of the $\epsilon$-ball increases. This indicates that the quality of gradients is preserved, enabling PGD attacks to move the gradient toward examples not in the observed distribution.

Figure 3 illustrates the certified robustness achieved by random smoothing for various models on the CIFAR10 dataset, where Original refers to the certified robustness of the original model, while Ours denotes the robustness of the model combined with the proposed method. As can be seen, our method brings slight improvements in robustness, except for the AWP model. These results demonstrate that our algorithm does not suffer from the gradient masking issue. However, the empirical Lipschitz constant is derived from the observed data. As the input distribution drawn from random smoothing and the observed data might have discrepancies, this could result in fluctuations in robustness.

Figure: (a) RST-AWP
Refer to caption: extracted/5697146/rs-CIFAR10-WRN_28_10-RST_AWP.png

**Table 7: The robust accuracy against adversarial examples generated by the original models.**
| Method | Origin | $c^{r}$ |  |  |
| --- | --- | --- | --- | --- |
| $2^{-8}$ | $2^{-7}$ | $2^{-6}$ |  |  |
| RST-AWP | 60.04 | 62.10 | 65.10 | 70.53 |
| DefEAT | 57.30 | 58.37 | 60.39 | 66.10 |
| LTD | 56.94 | 58.71 | 61.63 | 66.47 |
| AWP | 56.17 | 57.49 | 59.74 | 65.58 |
| TRADES | 52.86 | 55.55 | 55.09 | 58.68 |

**Table 8: The robust accuracy against FGSM and PGD attacks among different radii of $\epsilon$-ball on CIFAR10 dataset.**
| Method | $c^{r}$ | Attack | $\epsilon$ |  |  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| $\frac{1}{255}$ | $\frac{2}{255}$ | $\frac{4}{255}$ | $\frac{8}{255}$ | $\frac{16}{255}$ | $\frac{32}{255}$ | $\frac{64}{255}$ | $\frac{96}{255}$ |  |  |  |
| RST-AWP | $2^{-8}$ | FGSM | 88.28 | 86.94 | 83.80 | 75.12 | 57.23 | 34.04 | 18.80 | 19.03 |
| PGD | 86.78 | 84.47 | 79.03 | 66.03 | 34.02 | 2.01 | 0.01 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 89.46 | 88.28 | 85.64 | 77.62 | 60.60 | 35.91 | 19.39 | 20.68 |  |
| PGD | 88.03 | 85.88 | 80.89 | 69.24 | 38.27 | 3.08 | 0.1 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 87.70 | 86.63 | 84.38 | 77.91 | 60.93 | 33.48 | 16.12 | 18.81 |  |
| PGD | 86.38 | 84.69 | 81.19 | 73.72 | 52.24 | 11.89 | 0.19 | 0.0 |  |  |
| DefEAT | $2^{-8}$ | FGSM | 86.38 | 85.40 | 81.98 | 72.73 | 53.28 | 30.34 | 18.13 | 19.65 |
| PGD | 84.52 | 82.07 | 76.51 | 63.71 | 33.87 | 1.76 | 0.0 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 86.69 | 85.70 | 83.05 | 74.35 | 56.36 | 32.04 | 18.88 | 21.40 |  |
| PGD | 85.11 | 82.87 | 78.00 | 66.54 | 38.70 | 3.12 | 0.0 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 84.14 | 83.57 | 81.03 | 74.63 | 57.67 | 28.11 | 13.17 | 19.38 |  |
| PGD | 82.96 | 81.35 | 77.37 | 69.52 | 50.70 | 10.05 | 0.2 | 0.0 |  |  |
| LTD | $2^{-8}$ | FGSM | 84.94 | 83.87 | 81.15 | 72.80 | 55.45 | 33.06 | 18.44 | 17.48 |
| PGD | 83.13 | 80.68 | 75.53 | 63.52 | 34.81 | 2.64 | 0.0 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 85.48 | 84.67 | 82.24 | 74.10 | 57.41 | 35.53 | 17.57 | 17.50 |  |
| PGD | 83.88 | 81.88 | 77.00 | 65.38 | 28.57 | 3.95 | 0.0 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 85.06 | 84.28 | 82.21 | 75.77 | 60.79 | 34.39 | 14.34 | 15.42 |  |
| PGD | 83.91 | 82.00 | 78.33 | 69.82 | 49.95 | 11.63 | 0.21 | 0.0 |  |  |
| AWP | $2^{-8}$ | FGSM | 85.11 | 83.90 | 80.68 | 71.28 | 53.78 | 33.21 | 20.86 | 19.61 |
| PGD | 83.34 | 80.34 | 75.08 | 61.53 | 30.50 | 1.89 | 0.03 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 85.50 | 84.68 | 81.75 | 73.56 | 57.19 | 35.50 | 20.63 | 20.16 |  |
| PGD | 83.94 | 81.62 | 76.34 | 65.57 | 34.16 | 2.89 | 0.02 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 83.87 | 83.19 | 81.08 | 74.97 | 61.49 | 35.13 | 16.12 | 18.69 |  |
| PGD | 83.00 | 81.42 | 78.13 | 71.50 | 54.95 | 14.78 | 0.41 | 0.0 |  |  |
| TRADES | $2^{-8}$ | FGSM | 84.74 | 83.51 | 70.58 | 70.50 | 54.23 | 36.53 | 23.97 | 23.46 |
| PGD | 82.62 | 79.72 | 72.81 | 57.30 | 24.21 | 1.21 | 0.01 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 85.00 | 84.02 | 80.57 | 71.61 | 55.94 | 25.67 | 22.31 | 22.51 |  |
| PGD | 82.96 | 80.31 | 73.75 | 58.91 | 26.22 | 1.31 | 0.02 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 85.05 | 84.19 | 81.40 | 75.07 | 60.24 | 36.99 | 21.81 | 21.21 |  |
| PGD | 83.23 | 81.33 | 75.81 | 64.56 | 36.76 | 3.37 | 0.02 | 0.0 |  |  |

**Table 9: The robust accuracy against FGSM and PGD attacks among different radii of $\epsilon$-ball on CIFAR100 dataset.**
| Method | $c^{r}$ | Attack | $\epsilon$ |  |  |  |  |  |  |  |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| $\frac{1}{255}$ | $\frac{2}{255}$ | $\frac{4}{255}$ | $\frac{8}{255}$ | $\frac{16}{255}$ | $\frac{32}{255}$ | $\frac{64}{255}$ | $\frac{96}{255}$ |  |  |  |
| EffAug | $2^{-8}$ | FGSM | 68.02 | 65.96 | 60.36 | 49.65 | 33.90 | 17.39 | 7.11 | 5.77 |
| PGD | 64.92 | 61.04 | 52.82 | 39.37 | 17.53 | 1.81 | 0.0 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 68.41 | 66.56 | 61.84 | 51.83 | 36.59 | 18.34 | 7.02 | 6.70 |  |
| PGD | 65.66 | 62.02 | 54.58 | 41.55 | 19.70 | 2.26 | 0.0 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 67.84 | 67.25 | 64.65 | 57.97 | 44.23 | 22.20 | 8.26 | 8.85 |  |
| PGD | 66.38 | 64.20 | 59.63 | 50.89 | 33.98 | 7.27 | 0.17 | 0.0 |  |  |
| DKLD | $2^{-8}$ | FGSM | 63.47 | 61.94 | 58.15 | 48.86 | 34.39 | 17.73 | 6.26 | 3.66 |
| PGD | 60.71 | 57.14 | 50.44 | 38.14 | 17.38 | 1.97 | 0.0 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 63.55 | 62.31 | 58.65 | 50.37 | 36.49 | 18.69 | 6.36 | 4.29 |  |
| PGD | 61.06 | 57.84 | 51.51 | 39.99 | 19.71 | 2.37 | 0.0 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 63.26 | 62.77 | 60.41 | 55.18 | 43.86 | 21.17 | 5.50 | 4.97 |  |
| PGD | 61.67 | 59.62 | 55.83 | 48.06 | 33.51 | 7.55 | 0.17 | 0.0 |  |  |
| DefEAT | $2^{-8}$ | FGSM | 65.57 | 64.36 | 59.88 | 49.38 | 32.48 | 15.38 | 5.50 | 3.30 |
| PGD | 62.39 | 58.96 | 51.85 | 38.59 | 17.18 | 1.45 | 0.0 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 65.97 | 64.96 | 60.67 | 51.44 | 34.84 | 16.36 | 5.33 | 3.96 |  |
| PGD | 62.94 | 59.83 | 52.98 | 41.05 | 20.07 | 2.02 | 0.0 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 64.69 | 63.58 | 61.31 | 54.47 | 40.06 | 16.91 | 4.64 | 4.46 |  |
| PGD | 62.85 | 60.50 | 56.29 | 47.54 | 30.76 | 5.84 | 0.09 | 0.0 |  |  |
| LTD | $2^{-8}$ | FGSM | 63.59 | 62.35 | 58.10 | 48.86 | 33.11 | 16.78 | 5.92 | 3.20 |
| PGD | 61.06 | 57.65 | 50.70 | 38.21 | 18.21 | 1.98 | 0.0 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 64.05 | 62.87 | 59.02 | 50.16 | 34.90 | 17.27 | 5.54 | 3.11 |  |
| PGD | 61.51 | 58.32 | 51.84 | 39.89 | 20.32 | 2.26 | 0.0 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 63.62 | 62.98 | 60.96 | 54.96 | 41.51 | 19.78 | 4.69 | 3.12 |  |
| PGD | 61.90 | 59.68 | 55.23 | 46.49 | 29.13 | 5.74 | 0.05 | 0.0 |  |  |
| AWP | $2^{-8}$ | FGSM | 59.77 | 58.06 | 54.21 | 45.54 | 30.98 | 16.69 | 6.49 | 3.97 |
| PGD | 56.72 | 52.92 | 46.53 | 34.90 | 16.03 | 2.11 | 0.0 | 0.0 |  |  |
| $2^{-7}$ | FGSM | 60.00 | 58.52 | 54.93 | 46.65 | 32.66 | 17.42 | 6.04 | 3.60 |  |
| PGD | 57.19 | 53.75 | 47.46 | 36.22 | 17.48 | 2.58 | 0.0 | 0.0 |  |  |
| $2^{-6}$ | FGSM | 60.20 | 59.71 | 57.47 | 52.05 | 39.78 | 21.10 | 5.70 | 3.90 |  |
| PGD | 58.19 | 55.66 | 50.91 | 42.37 | 25.53 | 5.68 | 0.09 | 0.0 |  |  |

## NeurIPS Paper Checklist

- 1.
Claims
- Question: Do the main claims made in the abstract and introduction accurately reflect the paper’s contributions and scope?
- Answer: [Yes]
- Justification: The main claim is stated in the abstract and highlighted in the introduction.
- Guidelines:
•
The answer NA means that the abstract and introduction do not include the claims made in the paper.
•
The abstract and/or introduction should clearly state the claims made, including the contributions made in the paper and important assumptions and limitations. A No or NA answer to this question will not be perceived well by the reviewers.
•
The claims made should match theoretical and experimental results, and reflect how much the results can be expected to generalize to other settings.
•
It is fine to include aspirational goals as motivation as long as it is clear that these goals are not attained by the paper.
- 2.
Limitations
- Question: Does the paper discuss the limitations of the work performed by the authors?
- Answer: [Yes]
- Justification: We leave some topics unexplored for further work as described in the conclusion.
- Guidelines:
•
The answer NA means that the paper has no limitation while the answer No means that the paper has limitations, but those are not discussed in the paper.
•
The authors are encouraged to create a separate "Limitations" section in their paper.
•
The paper should point out any strong assumptions and how robust the results are to violations of these assumptions (e.g., independence assumptions, noiseless settings, model well-specification, asymptotic approximations only holding locally). The authors should reflect on how these assumptions might be violated in practice and what the implications would be.
•
The authors should reflect on the scope of the claims made, e.g., if the approach was only tested on a few datasets or with a few runs. In general, empirical results often depend on implicit assumptions, which should be articulated.
•
The authors should reflect on the factors that influence the performance of the approach. For example, a facial recognition algorithm may perform poorly when image resolution is low or images are taken in low lighting. Or a speech-to-text system might not be used reliably to provide closed captions for online lectures because it fails to handle technical jargon.
•
The authors should discuss the computational efficiency of the proposed algorithms and how they scale with dataset size.
•
If applicable, the authors should discuss possible limitations of their approach to address problems of privacy and fairness.
•
While the authors might fear that complete honesty about limitations might be used by reviewers as grounds for rejection, a worse outcome might be that reviewers discover limitations that aren’t acknowledged in the paper. The authors should use their best judgment and recognize that individual actions in favor of transparency play an important role in developing norms that preserve the integrity of the community. Reviewers will be specifically instructed to not penalize honesty concerning limitations.
- 3.
Theory Assumptions and Proofs
- Question: For each theoretical result, does the paper provide the full set of assumptions and a complete (and correct) proof?
- Answer: [Yes]
- Justification: The proof of Lemma 2 is shown in Section 2.
- Guidelines:
•
The answer NA means that the paper does not include theoretical results.
•
All the theorems, formulas, and proofs in the paper should be numbered and cross-referenced.
•
All assumptions should be clearly stated or referenced in the statement of any theorems.
•
The proofs can either appear in the main paper or the supplemental material, but if they appear in the supplemental material, the authors are encouraged to provide a short proof sketch to provide intuition.
•
Inversely, any informal proof provided in the core of the paper should be complemented by formal proofs provided in appendix or supplemental material.
•
Theorems and Lemmas that the proof relies upon should be properly referenced.
- 4.
Experimental Result Reproducibility
- Question: Does the paper fully disclose all the information needed to reproduce the main experimental results of the paper to the extent that it affects the main claims and/or conclusions of the paper (regardless of whether the code and data are provided or not)?
- Answer: [Yes]
- Justification: The experiment were conducted by the public leaderboard RobusBench. The process is standardized and hardware-independent. The results can be fare compared to the competitiers.
- Guidelines:
•
The answer NA means that the paper does not include experiments.
•
If the paper includes experiments, a No answer to this question will not be perceived well by the reviewers: Making the paper reproducible is important, regardless of whether the code and data are provided or not.
•
If the contribution is a dataset and/or model, the authors should describe the steps taken to make their results reproducible or verifiable.
•
Depending on the contribution, reproducibility can be accomplished in various ways. For example, if the contribution is a novel architecture, describing the architecture fully might suffice, or if the contribution is a specific model and empirical evaluation, it may be necessary to either make it possible for others to replicate the model with the same dataset, or provide access to the model. In general. releasing code and data is often one good way to accomplish this, but reproducibility can also be provided via detailed instructions for how to replicate the results, access to a hosted model (e.g., in the case of a large language model), releasing of a model checkpoint, or other means that are appropriate to the research performed.
•
While NeurIPS does not require releasing code, the conference does require all submissions to provide some reasonable avenue for reproducibility, which may depend on the nature of the contribution. For example
(a)
If the contribution is primarily a new algorithm, the paper should make it clear how to reproduce that algorithm.
(b)
If the contribution is primarily a new model architecture, the paper should describe the architecture clearly and fully.
(c)
If the contribution is a new model (e.g., a large language model), then there should either be a way to access this model for reproducing the results or a way to reproduce the model (e.g., with an open-source dataset or instructions for how to construct the dataset).
(d)
We recognize that reproducibility may be tricky in some cases, in which case authors are welcome to describe the particular way they provide for reproducibility. In the case of closed-source models, it may be that access to the model is limited in some way (e.g., to registered users), but it should be possible for other researchers to have some path to reproducing or verifying the results.
- 5.
Open access to data and code
- Question: Does the paper provide open access to the data and code, with sufficient instructions to faithfully reproduce the main experimental results, as described in supplemental material?
- Answer: [N/A]
- Justification: The model architecture and pre-trained weights proposed in this work will be submitted to Robusbench. This information will be published once the results are certified by Robusbench.
- Guidelines:
•
The answer NA means that paper does not include experiments requiring code.
•
Please see the NeurIPS code and data submission guidelines ([https://nips.cc/public/guides/CodeSubmissionPolicy](https://nips.cc/public/guides/CodeSubmissionPolicy)) for more details.
•
While we encourage the release of code and data, we understand that this might not be possible, so “No” is an acceptable answer. Papers cannot be rejected simply for not including code, unless this is central to the contribution (e.g., for a new open-source benchmark).
•
The instructions should contain the exact command and environment needed to run to reproduce the results. See the NeurIPS code and data submission guidelines ([https://nips.cc/public/guides/CodeSubmissionPolicy](https://nips.cc/public/guides/CodeSubmissionPolicy)) for more details.
•
The authors should provide instructions on data access and preparation, including how to access the raw data, preprocessed data, intermediate data, and generated data, etc.
•
The authors should provide scripts to reproduce all experimental results for the new proposed method and baselines. If only a subset of experiments are reproducible, they should state which ones are omitted from the script and why.
•
At submission time, to preserve anonymity, the authors should release anonymized versions (if applicable).
•
Providing as much information as possible in supplemental material (appended to the paper) is recommended, but including URLs to data and code is permitted.
- 6.
Experimental Setting/Details
- Question: Does the paper specify all the training and test details (e.g., data splits, hyperparameters, how they were chosen, type of optimizer, etc.) necessary to understand the results?
- Answer: [Yes]
- Justification: The assessments utilized by RobustBench are standardized.
- Guidelines:
•
The answer NA means that the paper does not include experiments.
•
The experimental setting should be presented in the core of the paper to a level of detail that is necessary to appreciate the results and make sense of them.
•
The full details can be provided either with the code, in appendix, or as supplemental material.
- 7.
Experiment Statistical Significance
- Question: Does the paper report error bars suitably and correctly defined or other appropriate information about the statistical significance of the experiments?
- Answer: [N/A]
- Justification: The assessments utilized by RobustBench are standardized. The impact of Statistical variances have been included in the assessments.
- Guidelines:
•
The answer NA means that the paper does not include experiments.
•
The authors should answer "Yes" if the results are accompanied by error bars, confidence intervals, or statistical significance tests, at least for the experiments that support the main claims of the paper.
•
The factors of variability that the error bars are capturing should be clearly stated (for example, train/test split, initialization, random drawing of some parameter, or overall run with given experimental conditions).
•
The method for calculating the error bars should be explained (closed form formula, call to a library function, bootstrap, etc.)
•
The assumptions made should be given (e.g., Normally distributed errors).
•
It should be clear whether the error bar is the standard deviation or the standard error of the mean.
•
It is OK to report 1-sigma error bars, but one should state it. The authors should preferably report a 2-sigma error bar than state that they have a 96% CI, if the hypothesis of Normality of errors is not verified.
•
For asymmetric distributions, the authors should be careful not to show in tables or figures symmetric error bars that would yield results that are out of range (e.g. negative error rates).
•
If error bars are reported in tables or plots, The authors should explain in the text how they were calculated and reference the corresponding figures or tables in the text.
- 8.
Experiments Compute Resources
- Question: For each experiment, does the paper provide sufficient information on the computer resources (type of compute workers, memory, time of execution) needed to reproduce the experiments?
- Answer: [N/A]
- Justification: The assessments utilized by RobustBench are hardware-independent. Experiments can be performed on any GPU, but powerful GPUs can complete the evaluation in shorter execution times.
- Guidelines:
•
The answer NA means that the paper does not include experiments.
•
The paper should indicate the type of compute workers CPU or GPU, internal cluster, or cloud provider, including relevant memory and storage.
•
The paper should provide the amount of compute required for each of the individual experimental runs as well as estimate the total compute.
•
The paper should disclose whether the full research project required more compute than the experiments reported in the paper (e.g., preliminary or failed experiments that didn’t make it into the paper).
- 9.
Code Of Ethics
- Question: Does the research conducted in the paper conform, in every respect, with the NeurIPS Code of Ethics [https://neurips.cc/public/EthicsGuidelines](https://neurips.cc/public/EthicsGuidelines)?
- Answer: [Yes]
- Justification: This work follows the NeurIPS Code of Ethics.
- Guidelines:
•
The answer NA means that the authors have not reviewed the NeurIPS Code of Ethics.
•
If the authors answer No, they should explain the special circumstances that require a deviation from the Code of Ethics.
•
The authors should make sure to preserve anonymity (e.g., if there is a special consideration due to laws or regulations in their jurisdiction).
- 10.
Broader Impacts
- Question: Does the paper discuss both potential positive societal impacts and negative societal impacts of the work performed?
- Answer: [N/A]
- Justification: The main goal of this work is to design reliable models. This work is unlikely to have a negative social impact.
- Guidelines:
•
The answer NA means that there is no societal impact of the work performed.
•
If the authors answer NA or No, they should explain why their work has no societal impact or why the paper does not address societal impact.
•
Examples of negative societal impacts include potential malicious or unintended uses (e.g., disinformation, generating fake profiles, surveillance), fairness considerations (e.g., deployment of technologies that could make decisions that unfairly impact specific groups), privacy considerations, and security considerations.
•
The conference expects that many papers will be foundational research and not tied to particular applications, let alone deployments. However, if there is a direct path to any negative applications, the authors should point it out. For example, it is legitimate to point out that an improvement in the quality of generative models could be used to generate deepfakes for disinformation. On the other hand, it is not needed to point out that a generic algorithm for optimizing neural networks could enable people to train models that generate Deepfakes faster.
•
The authors should consider possible harms that could arise when the technology is being used as intended and functioning correctly, harms that could arise when the technology is being used as intended but gives incorrect results, and harms following from (intentional or unintentional) misuse of the technology.
•
If there are negative societal impacts, the authors could also discuss possible mitigation strategies (e.g., gated release of models, providing defenses in addition to attacks, mechanisms for monitoring misuse, mechanisms to monitor how a system learns from feedback over time, improving the efficiency and accessibility of ML).
- 11.
Safeguards
- Question: Does the paper describe safeguards that have been put in place for responsible release of data or models that have a high risk for misuse (e.g., pretrained language models, image generators, or scraped datasets)?
- Answer: [N/A]
- Justification: This models used in this works are existing public models. Therefore, this work poses no such risks.
- Guidelines:
•
The answer NA means that the paper poses no such risks.
•
Released models that have a high risk for misuse or dual-use should be released with necessary safeguards to allow for controlled use of the model, for example by requiring that users adhere to usage guidelines or restrictions to access the model or implementing safety filters.
•
Datasets that have been scraped from the Internet could pose safety risks. The authors should describe how they avoided releasing unsafe images.
•
We recognize that providing effective safeguards is challenging, and many papers do not require this, but we encourage authors to take this into account and make a best faith effort.
- 12.
Licenses for existing assets
- Question: Are the creators or original owners of assets (e.g., code, data, models), used in the paper, properly credited and are the license and terms of use explicitly mentioned and properly respected?
- Answer: [Yes]
- Justification: The related works and RobustBench are correctly cited in this work.
- Guidelines:
•
The answer NA means that the paper does not use existing assets.
•
The authors should cite the original paper that produced the code package or dataset.
•
The authors should state which version of the asset is used and, if possible, include a URL.
•
The name of the license (e.g., CC-BY 4.0) should be included for each asset.
•
For scraped data from a particular source (e.g., website), the copyright and terms of service of that source should be provided.
•
If assets are released, the license, copyright information, and terms of use in the package should be provided. For popular datasets, [paperswithcode.com/datasets](paperswithcode.com/datasets) has curated licenses for some datasets. Their licensing guide can help determine the license of a dataset.
•
For existing datasets that are re-packaged, both the original license and the license of the derived asset (if it has changed) should be provided.
•
If this information is not available online, the authors are encouraged to reach out to the asset’s creators.
- 13.
New Assets
- Question: Are new assets introduced in the paper well documented and is the documentation provided alongside the assets?
- Answer: [N/A]
- Justification: This work does not release new assets.
- Guidelines:
•
The answer NA means that the paper does not release new assets.
•
Researchers should communicate the details of the dataset/code/model as part of their submissions via structured templates. This includes details about training, license, limitations, etc.
•
The paper should discuss whether and how consent was obtained from people whose asset is used.
•
At submission time, remember to anonymize your assets (if applicable). You can either create an anonymized URL or include an anonymized zip file.
- 14.
Crowdsourcing and Research with Human Subjects
- Question: For crowdsourcing experiments and research with human subjects, does the paper include the full text of instructions given to participants and screenshots, if applicable, as well as details about compensation (if any)?
- Answer: [N/A]
- Justification: This work does not involve crowdsourcing nor research with human subjects.
- Guidelines:
•
The answer NA means that the paper does not involve crowdsourcing nor research with human subjects.
•
Including this information in the supplemental material is fine, but if the main contribution of the paper involves human subjects, then as much detail as possible should be included in the main paper.
•
According to the NeurIPS Code of Ethics, workers involved in data collection, curation, or other labor should be paid at least the minimum wage in the country of the data collector.
- 15.
Institutional Review Board (IRB) Approvals or Equivalent for Research with Human Subjects
- Question: Does the paper describe potential risks incurred by study participants, whether such risks were disclosed to the subjects, and whether Institutional Review Board (IRB) approvals (or an equivalent approval/review based on the requirements of your country or institution) were obtained?
- Answer: [N/A]
- Justification: This work does not involve crowdsourcing nor research with human subjects.
- Guidelines:
•
The answer NA means that the paper does not involve crowdsourcing nor research with human subjects.
•
Depending on the country in which research is conducted, IRB approval (or equivalent) may be required for any human subjects research. If you obtained IRB approval, you should clearly state this in the paper.
•
We recognize that the procedures for this may vary significantly between institutions and locations, and we expect authors to adhere to the NeurIPS Code of Ethics and the guidelines for their institution.
•
For initial submissions, do not include any information that would break anonymity (if applicable), such as the institution conducting the review.

## Peer Reviews

confidence: 4
contribution: 3
initial_rating: 5
presentation: 3
questions: Please see weakness part.
soundness: 3
strengths: The logic flow of this work is coherent, and the writing is clear and easy to understand. The idea of optimizing the Lipschitz constant to achieve certified adversarial robustness is also a classic approach. The implementation is very straightforward, and the proposed forged function can serve as a plug-in module that integrates with any CNN or transformer-based model.
summary: This work starts from Lipschitz continuity and enhances adversarial robustness by minimizing the empirical Lipschitz constant. Specifically, the authors propose a plug-in forged function that can be inserted before each convolutional layer and MLP layer to remap the input domain of each layer into a constrained set. The theoretical guarantee of this paper primarily demonstrates that the largest singular value of the parameter matrix can serve as a loose bound for the Lipschitz constant. Experimental results show that the forged layers can bring some improvement to existing adversarial training methods.
weaknesses: Theoretical side: The bound is somewhat too loose. This paper derives the final optimization objective through the Gershgorin Circle Theorem, but this bound lacks guarantees due to the multiple assumptions made.

Empirical side: On one hand, from Tables 1 and 2, it seems that the forged function does not show significant improvements; in fact, when combined with other robust methods, the accuracy under AutoAttack even decreases. On the other hand, the robustness of the forged function itself lacks experimental support, such as how much robustness it can provide without any robustness designs (including adversarial training). An important contribution of this paper is that it incurs lower costs compared to adversarial training, so a comparison of performance with adversarial training is necessary.

Meanwhile, I suggest conducting adaptive attack against forged function to test the white-box robustness.

---

confidence: 4
contribution: 2
initial_rating: 5
presentation: 2
questions: 1. How effective is the proposed method in more complex tasks and models, such as object detection and multimodal tasks?
2. Although the authors validated against gradient obfuscation through AutoAttack, the forged function suppresses inputs below a threshold to zero, potentially introducing gradient obfuscation under untested attack methods. Are there further theoretical or experimental supports to ensure that this method does not introduce gradient obfuscation under various attack strategies?
3. How generalizable is this method? Is it applicable to non-vision tasks?
soundness: 2
strengths: The proposed forged function based on Lipschitz continuity is implemented during the inference phase, eliminating the need for retraining or model parameter adjustments. Compared to traditional adversarial training, this method offers a significant computational cost advantage, making it more efficient for applications with limited resources.
summary: This paper proposes a robustness enhancement method based on Lipschitz continuity, aiming to improve the security of deep neural networks (DNNs) under adversarial attacks. The authors introduce a forged function that constrains the input domain of the model to reduce its Lipschitz constant, potentially enhancing robustness. This method optimizes inference without retraining the model, thus reducing computational costs. Experiments on CIFAR10, CIFAR100, and ImageNet datasets tested various model architectures like WRN and Swin Transformer, evaluating performance under both white-box and black-box attacks.
weaknesses: 1. Please distinguish between the use of `\cite{}` and `\citep{}`.
2. The authors are encouraged to open-source their code.
3. In the "Related Work" section, the authors should mention the names of methods alongside author names to aid reader comprehension.
4. In Algorithm 1, Forged Function, please add a description of the hyperparameter $c^r$ in the `require` section.
5. AutoAttack is not the latest attack method; the authors are encouraged to use more advanced black-box attack methods, as referenced in [1].
6. Although the paper emphasizes low computational overhead during the inference phase, it is recommended that the authors provide specific experimental data or quantitative analysis to compare computational overhead.

**Reference**:

[1] https://github.com/Trustworthy-AI-Group/TransferAttack

---

confidence: 4
contribution: 3
initial_rating: 5
presentation: 3
questions: 1.	In the evaluation using $acc_{AA}$, are the adversarial examples generated using the original neural network architecture, or using the architecture with the proposed forged function?
2.	Can this method be extended to other tasks, such as NLP applications? Alternatively, could the proposed forged function improve the generalization ability of the model in standard training?
3.	Could the authors elaborate on the selection process of parameter $c^r$ and explore a broader range of $c^r$ values across additional datasets?
4.	The method is efficient for certain datasets, but for large datasets like the full ImageNet, it still be computationally expensive. Do the authors have any future plans to further reduce computational requirements?
soundness: 3
strengths: 1.	The method is highly cost-effective as it does not require model retraining or additional data. Moreover, due to its plug-and-play nature, the proposed method can be easily integrated with existing algorithms. 
2.	The authors provide detailed theoretical insights into the relationship between the Lipschitz constant and adversarial robustness. 
3.	The paper is well-organized and clearly presented, with extensive experiments across diverse datasets that validate the robustness of the proposed method.
summary: The author proposes a plug-play method to enhance the adversarial robustness of deep neural networks by focusing on Lipschitz continuity. This work reduces the Lipschitz constant by remapping the input domain to a constrained range, thus improving robustness without requiring retraining. This approach is almost cost-free, and experimental results combined with the previous work show the effectiveness of the proposed method.
weaknesses: 1.	The experimental results, along with the authors' own analysis, indicate that the proposed method may reduce the classification accuracy on clean samples in some cases. While the authors discuss possible reasons, the paper could further analyze this trade-off and explore strategies to mitigate accuracy loss. 
2.	The choice of parameter $c^r$ is crucial to performance, but finding a single $c^r$ that performs well across all tasks is challenging based on the results presented. For example, $c^r=2^{-6}$ performs well on most tasks, while $c^r=2^{-7}$ works better for RST-AWP in Table 4. Adjusting this parameter for new tasks could be time-consuming.

---

confidence: 4
contribution: 2
initial_rating: 5
presentation: 3
questions: 1. As $c^r$ is very small, I wonder the proportion of activation that be pruned in the experiment. 

2. As the proposed method change the activation even in the natural images, why the natural accuracy is improved in some cases?
soundness: 2
strengths: 1. The paper proposes a model agnostic method that can be easily applied to various robust models and improve the robustness of these method. Such methods have good potential for wide applications.

2. While the proposed method is simple, the pruning technique shows to improve the robust accuracy of various models. Considering the newly introduced hyperparameters are limited, the improvement is far above the margin of errors.
summary: The paper proposes a model agnostic method for improving the robustness of the network. Essentially, the method prune the activation of small values of the pretrained models. The pruning threshold is determined by the data and a hyperparameter. The paper performs a series experiment on different kinds of adversarially-trained models and shows that the proposed method can improve the robust accuracy by about 0.5%-2% while keeping the accuracy on the natural images. The paper discuss the possibility of gradient masking. However, the experiments cannot fully eliminate such possibility.
weaknesses: 1. While the paper discuss the possibility of gradient masking, the experiment is not enough to completely rule out such possibilities. Specially, the paper uses forging function to cut specific activation. Therefore, attacking methods like BPDA should be combined into AutoAttack and the robust accuracy under such attacks should be reported.

2. The motivation of the paper is not fully elaborated in the experiment. For example, whether the empirical Lipschitz has truly been lowered by such method should be reported.

3. Despite the simplicity the method, the novelty of  the proposed method is limited.

---

confidence: 3
contribution: 2
initial_rating: 3
presentation: 2
questions: See weakness.
soundness: 2
strengths: 1. The idea of enhancing the adversarial robustness by reducing the Lipschitz constant is reasonable and straightforward.

2. This paper is well structured.
summary: This work aims to enhance the adversarial robustness of DNNs by reducing the Lipschitz constant. Unlike existing adversarially trained models, this method is a cost-free method to enhance adversarial robustness by introducing a forged function in the DNNs. Experimental results on CIFAR10, CIFAR100, and ImageNet datasets have demonstrated the proposed method outperforms the adversarial training method.
weaknesses: 1. The concept of utilizing the Lipschitz constant to certify the adversarial robustness of DNNs has been explored in many previous works [1-3]. This Lipschitz constant is utilized to provide a provable adversarial robustness. However, this paper does not discuss the main differences and improvements from those provable adversarial defense methods.

2. The proposed forged function seems to be a variation of ReLU, just with a different threshold. Additionally, as illustrated in Figure 2, the Forged function is concatenated with ReLU. How does this differ from simply applying a shifted ReLU?

3. Given Equation (3), if the model becomes larger and more complex, would this increase the Lipschitz constant, potentially worsening the model's robustness?


[1] Certified adversarial robustness via randomized smoothing, In ICML2019
[2] Provably robust deep learning via adversarially trained smoothed classifiers, In Neurips 2019
[3] Scaling provable adversarial defenses, In Neurips 2018.

Meta-review: The paper proposes a method to enhance adversarial robustness in deep neural networks by reducing the empirical Lipschitz constant through a novel forged function applied during inference. While the work aims to address a critical issue in AI safety and robustness, it falls short of meeting the standard for acceptance due to several significant weaknesses. The theoretical foundation is undermined by overly loose bounds derived under multiple assumptions, which limits the generalizability and rigor of the approach. Empirically, the method demonstrates marginal improvements in robustness, with results that are inconsistent across different datasets and adversarial scenarios. The robustness gains, often within 0.5%-2%, are accompanied by trade-offs in clean accuracy, which are neither systematically analyzed nor mitigated. Additionally, the novelty of the approach is questionable, as it builds upon well-established techniques such as ReLU-like thresholding without substantial innovation.

The reviewers have highlighted critical gaps, including insufficient motivation, incomplete experimental support for robustness claims, and unresolved concerns about potential gradient masking under adversarial attacks. For example, while the authors argue that their method is computationally efficient, they do not convincingly compare its performance against state-of-the-art adversarial training methods in terms of robustness-to-cost ratio. Furthermore, the paper lacks a thorough investigation of its applicability beyond vision tasks, which limits its impact and generalizability. The claims of cost-effectiveness, while appealing, are undercut by the method's limited scalability to larger datasets and complex tasks. Moreover, the rebuttal failed to adequately address concerns about empirical validation and theoretical soundness, leaving doubts about the reliability and significance of the results.

The paper does present a coherent structure and a clear narrative, with some potential for practical application due to its plug-and-play nature. However, these strengths are overshadowed by the method's incremental contribution and lack of robustness against adaptive attacks. In light of these limitations, the submission does not meet the bar for acceptance at ICLR, where originality, rigor, and impact are paramount. The work would benefit from a stronger theoretical underpinning, comprehensive empirical evaluations, and a clearer articulation of its contribution relative to existing literature.

Decision: Reject