Title: COST-SENSITIVE ROBUSTNESS AGAINST ADVERSARIAL EXAMPLES

Abstract: Several recent works have developed methods for training classifiers that are certifiably robust against norm-bounded adversarial perturbations. These methods assume that all the adversarial transformations are equally important, which is seldom the case in real-world applications. We advocate for cost-sensitive robustness as the criteria for measuring the classifier's performance for tasks where some adversarial transformation are more important than others. We encode the potential harm of each adversarial transformation in a cost matrix, and propose a general objective function to adapt the robust training method of Wong & Kolter (2018) to optimize for cost-sensitive robustness. Our experiments on simple MNIST and CIFAR10 models with a variety of cost matrices show that the proposed approach can produce models with substantially reduced cost-sensitive robust error, while maintaining classification accuracy.

1. INTRODUCTION:

Despite the exceptional performance of deep neural networks (DNNs) on various machine learning tasks such as malware detection (Saxe & Berlin, 2015) , face recognition (Parkhi et al., 2015) and autonomous driving (Bojarski et al., 2016) , recent studies (Szegedy et al., 2014; Goodfellow et al., 2015) have shown that deep learning models are vulnerable to misclassifying inputs, known as adversarial examples, that are crafted with targeted but visually-imperceptible perturbations. While several defense mechanisms have been proposed and empirically demonstrated to be successful against existing particular attacks (Papernot et al., 2016; Goodfellow et al., 2015) , new attacks (Carlini & Wagner, 2017; Tramèr et al., 2018; Athalye et al., 2018) are repeatedly found that circumvent such defenses. To end this arm race, recent works (Wong & Kolter, 2018; Raghunathan et al., 2018; Wong et al., 2018; Wang et al., 2018) propose methods to certify examples to be robust against some specific norm-bounded adversarial perturbations for given inputs and to train models to optimize for certifiable robustness.

However, all of the aforementioned methods aim at improving the overall robustness of the classifier. This means that the methods to improve robustness are designed to prevent seed examples in any class from being misclassified as any other class. Achieving such a goal (at least for some definitions of adversarial robustness) requires producing a perfect classifier, and has, unsurprisingly, remained elusive. Indeed, Mahloujifar et al. (2019) proved that if the metric probability space is concentrated, overall adversarial robustness is unattainable for any classifier with initial constant error.

We argue that overall robustness may not be the appropriate criteria for measuring system performance in security-sensitive applications, since only certain kinds of adversarial misclassifications pose meaningful threats that provide value for potential adversaries. Whereas overall robustness places equal emphasis on every adversarial transformation, from a security perspective, only certain transformations matter. As a simple example, misclassifying a malicious program as benign results in more severe consequences than the reverse.

In this paper, we propose a general method for adapting provable defenses against norm-bounded perturbations to take into account the potential harm of different adversarial class transformations. Inspired by cost-sensitive learning (Domingos, 1999; Elkan, 2001) for non-adversarial contexts, we capture the impact of different adversarial class transformations using a cost matrix C, where each entry represents the cost of an adversary being able to take a natural example from the first class and perturb it so as to be misclassified by the model as the second class. Instead of reducing the overall robust error, our goal is to minimize the cost-weighted robust error (which we define for both binary and real-valued costs in C). The proposed method incorporates the specified cost matrix into the training objective function, which encourages stronger robustness guarantees on cost-sensitive class transformations, while maintaining the overall classification accuracy on the original inputs.

Contributions. By encoding the consequences of different adversarial transformations into a cost matrix, we introduce the notion of cost-sensitive robustness (Section 3.1) as a metric to assess the expected performance of a classifier when facing adversarial examples. We propose an objective function for training a cost-sensitive robust classifier (Section 3.2). The proposed method is general in that it can incorporate any type of cost matrix, including both binary and real-valued. We demonstrate the effectiveness of the proposed cost-sensitive defense model for a variety of cost scenarios on two benchmark image classification datasets: MNIST (Section 4.1) and CIFAR10 (Section 4.2). Compared with the state-of-the-art overall robust defense model (Wong & Kolter, 2018) , our model achieves significant improvements in cost-sensitive robustness for different tasks, while maintaining approximately the same classification accuracy on both datasets.

Notation. We use lower-case boldface letters such as x for vectors and capital boldface letters such as A to represent matrices. Let [m] be the index set {1, 2, . . . , m} and A ij be the (i, j)-th entry of matrix A. Denote the i-th natural basis vector, the all-ones vector and the identity matrix by e i , 1 and I respectively. For any vector

x ∈ R d , the ∞ -norm of x is defined as x ∞ = max i∈[d] |x i |.

2. BACKGROUND:

In this section, we provide a brief introduction on related topics, including neural network classifiers, adversarial examples, defenses with certified robustness, and cost-sensitive learning.

2.1. NEURAL NETWORK CLASSIFIERS:

A K-layer neural network classifier can be represented by a function f :

X → Y such that f (x) = f K-1 (f K-2 (• • • (f 1 (x))

)), for any x ∈ X . For k ∈ {1, 2, . . . , K -2}, the mapping function f k (•) typically consists of two operations: an affine transformation (either matrix multiplication or convolution) and a nonlinear activation. In this paper, we consider rectified linear unit (ReLU) as the activation function. If denote the feature vector of the k-th layer as z k , then f k (•) is defined as

z k+1 = f k (z k ) = max{W k z k + b k , 0}, ∀k ∈ {1, 2, . . . K -2},

where W k denotes the weight parameter matrix and b k the bias vector. The output function f K-1 (•) maps the feature vector in the last hidden layer to the output space Y solely through matrix multiplication:

z K = f K-1 (z K-1 ) = W K-1 z K-1 + b K-1

, where z K can be regarded as the estimated score vector of input x for different possible output classes. In the following discussions, we use f θ to represent the neural network classifier, where

θ = {W 1 , . . . , W K-1 , b 1 , . . . , b K-1 } denotes the model parameters.

To train the neural network, a loss function

N i=1 L(f θ (x i ), y i ) is defined for a set of training examples {x i , y i } N i=1

, where x i is the i-th input vector and y i denotes its class label. Cross-entropy loss is typically used for multiclass image classification. With proper initialization, all model parameters are then updated iteratively using backpropagation. For any input example x, the predicted label y is given by the index of the largest predicted score among all classes, argmax j [f θ ( x)] j .

2.2. ADVERSARIAL EXAMPLES:

An adversarial example is an input, generated by some adversary, which is visually indistinguishable from an example from the natural distribution, but is able to mislead the target classifier. Since "visually indistinguishable" depends on human perception, which is hard to define rigorously, we consider the most popular alternative: input examples with perturbations bounded in ∞ -norm (Goodfellow et al., 2015) . More formally, the set of adversarial examples with respect to seed example {x 0 , y 0 } and classifier f θ (•) is defined as

A (x 0 , y 0 ; θ) = x ∈ X : x -x 0 ∞ ≤ and argmax j [f θ (x)] j = y 0 , (2.1)

where > 0 denotes the maximum perturbation distance. Although p distances are commonly used in adversarial examples research, they are not an adequate measure of perceptual similarity (Sharif et al., 2018) and other minimal geometric transformations can be used to find adversarial examples (Engstrom et al., 2017; Kanbak et al., 2018; Xiao et al., 2018) . Nevertheless, there is considerable interest in improving robustness in this simple domain, and hope that as this research area matures we will find ways to apply results from studying simplified problems to more realistic ones.

2.3. DEFENSES WITH CERTIFIED ROBUSTNESS:

A line of recent work has proposed defenses that are guaranteed to be robust against norm-bounded adversarial perturbations. Hein & Andriushchenko (2017) Following the definitions in Wong & Kolter (2018) , an adversarial polytope Z (x) with respect to a given example x is defined as

EQUATION

which contains all the possible output vectors for the given classifier f θ by perturbing x within an ∞ -norm ball with radius . A seed example, {x 0 , y 0 }, is said to be certified robust with respect to maximum perturbation distance , if the corresponding adversarial example set A (x 0 , y 0 ; θ) is empty. Equivalently, if we solve, for any output class y targ = y 0 , the optimization problem,

minimize z K [z K ] y0 -[z K ] ytarg , subject to z K ∈ Z (x 0 ), (2.3)

then according to the definition of A (x 0 , y 0 ; θ) in (2.1), {x 0 , y 0 } is guaranteed to be robust provided that the optimal objective value of (2.3) is positive for every output class. To train a robust model on a given dataset {x i , y i } N i=1 , the standard robust optimization aims to minimize the sample loss function on the worst-case locations through the following adversarial loss

EQUATION

where L(•, •) denotes the cross-entropy loss. However, due to the nonconvexity of the neural network classifier f θ (•) introduced by the nonlinear ReLU activation, both the adversarial polytope (2.2) and training objective (2.4) are highly nonconvex. In addition, solving optimization problem (2.3) for each pair of input example and output class is computationally intractable.

Instead of solving the optimization problem directly, Wong & Kolter (2018) proposed an alternative training objective function based on convex relaxation, which can be efficiently optimized through a dual network. Specifically, they relaxed Z (x) into a convex outer adversarial polytope Z (x) by replacing the ReLU inequalities for each neuron z = max{ z, 0} with a set of inequalities,

z ≥ 0, z ≥ z, -u z + (u -)z ≤ -u , (2.5)

where u, denote the lower and upper bounds on the considered pre-ReLU activation.1 Based on the relaxed outer bound Z (x), they propose the following alternative optimization problem,

minimize z K [z K ] y0 -[z K ] ytarg , subject to z K ∈ Z (x 0 ), (2.6)

which is in fact a linear program. Since Z (x) ⊆ Z (x) for any x ∈ X , solving (2.6) for all output classes provides stronger robustness guarantees compared with (2.3), provided all the optimal objective values are positive. In addition, they derived a guaranteed lower bound, denoted by J x 0 , g θ (e y0 -e ytarg ) , on the optimal objective value of Equation 2.6 using duality theory, where g θ (•) is a K-layer feedforward dual network (Theorem 1 in Wong & Kolter (2018) ). Finally, according to the properties of cross-entropy loss, they minimize the following objective to train the robust model, which serves as an upper bound of the adversarial loss (2.4):

minimize θ 1 N N i=1 L -J x i , g θ (e yi • 1 -I) , y i , (2.7)

where g θ (•) is regarded as a columnwise function when applied to a matrix. Although the proposed method in Wong & Kolter (2018) achieves certified robustness, its computational complexity is quadratic with the network size in the worst case so it only scales to small networks. Recently, Wong et al. (2018) extended the training procedure to scale to larger networks by using nonlinear random projections. However, if the network size allows for both methods, we observe a small decrease in performance using the training method provided in Wong et al. (2018) . Therefore, we only use the approximation techniques for the experiments on CIFAR10 ( §4.2), and use the less scalable method for the MNIST experiments ( §4.1).

2.4. COST-SENSITIVE LEARNING:

Cost-sensitive learning (Domingos, 1999; Elkan, 2001; Liu & Zhou, 2006) was proposed to deal with unequal misclassification costs and class imbalance problems commonly found in classification applications. The key observation is that cost-blind learning algorithms tend to overwhelm the major class, but the neglected minor class is often our primary interest. For example, in medical diagnosis misclassifying a rare cancerous lesion as benign is extremely costly. Various cost-sensitive learning algorithms (Kukar & Kononenko, 1998; Zadrozny et al., 2003; Zhou & Liu, 2010; Khan et al., 2018) have been proposed in literature, but only a few algorithms, limited to simple classifiers, considered adversarial settings. 2 Dalvi et al. (2004) studied the naive Bayes classifier for spam detection in the presence of a cost-sensitive adversary, and developed an adversary-aware classifier based on game theory. Asif et al. (2015) proposed a cost-sensitive robust minimax approach that hardens a linear discriminant classifier with robustness in the adversarial context. All of these methods are designed for simple linear classifiers, and cannot be directly extended to neural network classifiers. In addition, the robustness of their proposed classifier is only examined experimentally based on the performance against some specific adversary, so does not provide any notion of certified robustness. Recently, Dreossi et al. (2018) advocated for the idea of using application-level semantics in adversarial analysis, however, they didn't provide a formal method on how to train such classifier.

Our work provides a practical training method that hardens neural network classifiers with certified cost-sensitive robustness against adversarial perturbations.

3. TRAINING A COST-SENSITIVE ROBUST CLASSIFIER:

The approach introduced in Wong & Kolter (2018) penalizes all adversarial class transformations equally, even though the consequences of adversarial examples usually depends on the specific class transformations. Here, we provide a formal definition of cost-sensitive robustness ( §3.1) and propose a general method for training cost-sensitive robust models ( §3.2).

3.1. CERTIFIED COST-SENSITIVE ROBUSTNESS:

Our approach uses a cost matrix C that encodes the cost (i. , let δ j = 0 if Ω j is an empty set, and δ j = 1 otherwise. We are only concerned with adversarial transformations from a seed class j to target classes j ∈ Ω j . For any example x in seed class j, x is said to be certified cost-sensitive robust if the lower bound J (x, g θ (e j -e j )) ≥ 0 for all j ∈ Ω j . That is, no adversarial perturbations in an ∞ -norm ball around x with radius can mislead the classifier to any target class in Ω j .

The cost-sensitive robust error on a dataset {x i , y i } N i=1 is defined as the number of examples that are not guaranteed to be cost-sensitive robust over the number of non-zero cost candidate seed examples:

cost-sensitive robust error = 1 - #{i ∈ [N ] : J (x i , g θ (e yi -e j )) ≥ 0, ∀j ∈ Ω yi } j| δ j =1 N j ,

where #A represents the cardinality of a set A, and N j is the total number of examples in class j.

Next, we consider a more general case where C is a m×m real-valued cost matrix. Each entry of C is a non-negative real number, which represents the cost of the corresponding adversarial transformation.

To take into account the different potential costs among adversarial examples, we measure the costsensitive robustness by the average certified cost of adversarial examples. The cost of an adversarial example x in class j is defined as the sum of all C jj such that J (x, g θ (e j -e j )) < 0. Intuitively speaking, an adversarial example will induce more cost if it can be adversarially misclassified as more target classes with high cost. Accordingly, the robust cost is defined as the total cost of adversarial examples divided by the total number of valued seed examples:

EQUATION

where 1(•) denotes the indicator function.

3.2. COST-SENSITIVE ROBUST OPTIMIZATION:

Recall that our goal is to develop a classifier with certified cost-sensitive robustness, as defined in §3.1, while maintaining overall classification accuracy. According to the guaranteed lower bound, J x 0 , g θ (e y0 -e ytarg ) on Equation 2.6 and inspired by the cost-sensitive CE loss (Khan et al., 2018) , we propose the following robust optimization with respect to a neural network classifier f θ :

minimize θ 1 N i∈[N ] L f θ (x i ), y i + α j∈[m] δ j N j i|y i =j log 1 + j ∈Ωj C jj • exp -J (x i , g θ (e j -e j )) , (3.2)

where α ≥ 0 denotes the regularization parameter. The first term in Equation 3.2 denotes the cross-entropy loss for standard classification, whereas the second term accounts for the cost-sensitive robustness. Compared with the overall robustness training objective function (2.7), we include a regularization parameter α to control the trade-off between classification accuracy on original inputs and adversarial robustness.

To provide cost-sensitivity, the loss function selectively penalizes the adversarial examples based on their cost. For binary cost matrixes, the regularization term penalizes every cost-sensitive adversarial example equally, but has no impact for instances where C jj = 0. For the real-valued costs, a larger value of C jj increases the weight of the corresponding adversarial transformation in the training objective. This optimization problem (3.2) can be solved efficiently using gradient-based algorithms, such as stochastic gradient descent and ADAM (Kingma & Ba, 2015) .

4. EXPERIMENTS:

We evaluate the performance of our cost-sensitive robustness training method on models for two benchmark image classification datasets: MNIST (LeCun et al., 2010) and CIFAR10 (Krizhevsky & Hinton, 2009) . We compare our results for various cost scenarios with overall robustness training seed class 0.41% 0.92% 0.92% 1.02% 1.02% 1.22% 0.82% 1.63% 0.82% 0.35% 1.41% 1.85% 0.70% 0.88% 1.23% 0.62% 3.96% 0.26% 3.00% 2.23% 7.07% 1.84% 1.74% 2.33% 2.71% 6.69% 1.45%

1.58% 1.98% 6.73% 1.49% 5.54% 1.09% 3.37% 6.83% 2.77%

2.95% 2.14% 2.34% 1.93% 1.43% 2.75% 2.55% 4.48% 10.08%

4.04% 1.68% 3.14% 9.75% 3.48% 4.71% 3.36% 9.08% 4.15%

3.34% 1.88% 2.51% 1.46% 3.55% 3.55% 1.15% 3.34% 1.04% 0.78% 3.31% 5.06% 5.06% 3.70% 2.04% 0.39% 4.86% 6.13%

3.59% 3.39% 4.83% 7.29% 4.93% 6.06% 5.13% 3.90% 5.75%

3.47% 2.97% 2.78% 5.05% 10.01% 5.95% 1.59% 4.96% 6.64% ( §2.3) as a baseline. For both datasets, the relevant family of attacks is specified as all the adversarial perturbations that are bounded in an ∞ -norm ball.

Our goal in the experiments is to evaluate how well a variety of different types of cost matrices can be supported. MNIST and CIFAR-10 are toy datasets, thus there are no obvious cost matrices that correspond to meaningful security applications for these datasets. Instead, we select representative tasks and design cost matrices to capture them.

4.1. MNIST:

For MNIST, we use the same convolutional neural network architecture (LeCun et al., 1998) as Wong & Kolter (2018) , which includes two convolutional layers, with 16 and 32 filters respectively, and a two fully-connected layers, consisting of 100 and 10 hidden units respectively. ReLU activations are applied to each layer except the last one. For both our cost-sensitive robust model and the overall robust model, we randomly split the 60,000 training samples into five folds of equal size, and train the classifier over 60 epochs on four of them using the Adam optimizer (Kingma & Ba, 2015) with batch size 50 and learning rate 0.001. We treat the remaining fold as a validation dataset for model selection. In addition, we use the -scheduling and learning rate decay techniques, where we increase from 0.05 to the desired value linearly over the first 20 epochs and decay the learning rate by 0.5 every 10 epochs for the remaining epochs.

Baseline: Overall Robustness. Figure 1 (a) illustrates the learning curves of both classification error and overall robust error during training based on robust loss (2.7) with maximum perturbation distance = 0.2. The model with classification error less than 4% and minimum overall robust error on the validation dataset is selected over the 60 training epochs. The best classifier reaches 3.39% classification error and 13.80% overall robust error on the 10,000 MNIST testing samples. We report the robust test error for every adversarial transformation in Figure 1(b ) (for the model without any robustness training all of the values are 100%). The (i, j)-th entry is a bound on the robustness of that seed-target transformation-the fraction of testing examples in class i that cannot be certified robust against transformation into class j for any norm-bounded attack. As shown in Figure 1(b) , the vulnerability to adversarial transformations differs considerably among class pairs and appears correlated with perceptual similarity. For instance, only 0.26% of seeds in class 1 cannot be certified robust for target class 9 compare to 10% of seeds from class 9 into class 4.

Binary Cost Matrix. Next, we evaluate the effectiveness of cost-sensitive robustness training in producing models that are more robust for adversarial transformations designated as valuable. We consider four types of tasks defined by different binary cost matrices that capture different sets of adversarial transformations: single pair: particular seed class s to particular target class t; single seed: particular seed class s to any target class; single target: any seed class to particular target class t; and multiple: multiple seed and target classes. For each setting, the cost matrix is defined as

C ij = 1 if (i, j) is selected; otherwise, C ij = 0.

In general, we expect that the sparser the cost matrix, the more opportunity there is for cost-sensitive training to improve cost-sensitive robustness over models trained for overall robustness.

For the single pair task, we selected three representative adversarial goals: a low vulnerability pair (0, 2), medium vulnerability pair (6, 5) and high vulnerability pair (4, 9). We selected these pairs by considering the robust error results on the overall-robustness trained model (Figure 1 (b)) as a rough measure for transformation hardness. This is generally consistent with intuitions about the MNIST digit classes (e.g., 9 and 4 look similar, so are harder to induce robustness against adversarial transformation), as well as with the visualization results produced by dimension reduction techniques, such as t-SNE (Maaten & Hinton, 2008) .

Similarly, for the single seed and single target tasks we select three representative examples representing low, medium, and high vulnerability to include in Table 1 and provide full results for all the single-seed and single target tasks for MNIST in Figure 2 . For the multiple transformations task, we consider four variations: (i) the ten most vulnerable seed-target transformations; (ii) ten randomly-selected seed-target transformations; (iii) all the class transformations from odd digit seed to any other class; (iv) all the class transformations from even digit seed to any other class.

Table 1 summarizes the results, comparing the cost-sensitive robust error between the baseline model trained for overall robustness and a model trained using our cost-sensitive robust optimization. The cost-sensitive robust defense model is trained with = 0.2 based on loss function (3.2) and the corresponding cost matrix C. The regularization parameter α is tuned via cross validation (see Appendix A for details). We report the selected best α, classification error and cost-sensitive robust error on the testing dataset.

Our model achieves a substantial improvement on the cost-sensitive robustness compared with the baseline model on all of the considered tasks, with no significant increases in normal classification error. The cost-sensitive robust error reduction varies from 30% to 90%, and is generally higher for sparse cost matrices. In particular, our classifier reduces the number of cost-sensitive adversarial examples from 198 to 12 on the single target task with digit 1 as the target class.

Real-valued Cost Matrices. Loosely motivated by a check forging adversary who obtains value by changing the semantic interpretation of a number (Papernot et al., 2016) , we consider two real-valued cost matrices: small-large, where only adversarial transformations from a smaller digit class to a larger one are valued, and the cost of valued-transformation is quadratic with the absolute difference between the seed and target class digits: C ij = (i -j) 2 if j > i, otherwise C ij = 0; large-small: only adversarial transformations from a larger digit class to a smaller one are valued:

C ij = (i -j) 2 if i > j, otherwise C ij = 0.

We tune α for the cost-sensitive robust model on the training MNIST dataset via cross validation, and set all the other parameters the same as in the binary case. The certified robust error for every adversarial transformation on MNIST testing dataset is shown in Figure 3 , and the classification error and robust cost are given in Table 2 . Compared with the model trained for overall robustness (Figure 1 (b)), our trained classifier achieves stronger robustness guarantees on the adversarial transformations that induce costs, especially for those with larger costs. 

4.2. CIFAR10:

We use the same neural network architecture for the CIFAR10 dataset as Wong et al. (2018) , with four convolutional layers and two fully-connected layers. For memory and computational efficiency, we incorporate the approximation technique based on nonlinear random projection during the training phase (Wong et al. (2018) , §3.2). We train both the baseline model and our model using random projection of 50 dimensions, and optimize the training objective using SGD. Other parameters such as learning rate and batch size are set as same as those in Wong et al. (2018) .

Given a specific task, we train the cost-sensitive robust classifier on 80% randomly-selected training examples, and tune the regularization parameter α according to the performance on the remaining examples as validation dataset. The tasks are similar to those for MNIST ( §4.1), except for the multiple transformations task we cluster the ten CIFAR10 classes into two large groups: animals and vehicles, and consider the cases where only transformations between an animal class and a vehicle class are sensitive, and the converse.

Table 3 shows results on the testing data based on different robust defense models with = 2/255. For all of the aforementioned tasks, our models substantially reduce the cost-sensitive robust error while keeping a lower classification error than the baseline.

For the real-valued task, we are concerned with adversarial transformations from seed examples in vehicle classes to other target classes. In addition, more cost is placed on transformations from vehicle to animal, which is 10 times larger compared with that from vehicle to vehicle. Figures 4(a )

Cost-Sensitive Robustness against Adversarial Examples:

Supplemental Materials

A PARAMETER TUNING:

For experiments on the MNIST dataset, we first perform a coarse tuning on regularization parameter α with searching grid {10 -2 , 10 -1 , 10 0 , 10 1 , 10 2 }, and select the most appropriate one, denoted by α coarse , with overall classification error less than 4% and the lowest cost-sensitive robust error on validation dataset. Then, we further finely tune α from the range {2 -3 , 2 -2 , 2 -1 , 2 0 , 2 1 , 2 2 , 2 3 } • α coarse , and choose the best robust model according to the same criteria.

Figures 6(a) and 6(b) show the learning curves for task B with digit 9 as the selected seed class based on the proposed cost-sensitive robust model with varying α (we show digit 9 because it is one of the most vulnerable seed classes). The results suggest that as the value of α increases, the corresponding classifier will have a lower cost-sensitive robust error but a higher classification error, which is what we expect from the design of (3.2).

We observe similar trends for the learning curves for the other tasks, so do not present them here. For the CIFAR10 experiments, a similar tuning strategy is implemented. The only difference is that we use 35% as the threshold of overall classification error for selecting the best α. To provide a fair comparison, we assume the cost matrix used for (B.1) coincides with the cost matrix used for cost-sensitive robust training (3.2) in our experiment, whereas they are unlikely to be the same for real security applications. For instance, misclassifying a benign program as malicious may still induce some cost in the non-adversarial setting, whereas the adversary may only benefit from transforming a malicious program into a benign one.

We consider the small-large real-valued task for MNIST, where the cost matrix C is designed as C ij = 0.1, if i > j; C ij = 0, if i = j; C ij = (i -j) 2 , otherwise. (Wong & Kolter, 2018) and our proposed classifier trained for cost-sensitive robustness.

Compared with baseline, the standard cost-sensitive classifier indeed reduces the misclassification cost. But, it does not provide improvement on the robust cost, as defined in (3.1). In sharp contrast, our robust training method significantly improves the cost-sensitive robustness.

:

The elementwise activation bounds can be computed efficiently using Algorithm 1 inWong & Kolter (2018).

Given the vulnerability of standard classifiers to adversarial examples, it is not surprising that standard cost-sensitive classifiers are also ineffective against adversaries. The experiments described in Appendix B supported this expectation.

Figures and Tables:

e., potential harm to model deployer) of different adversarial examples. First, we consider the case where there are m classes and C is a m × m binary matrix with C jj ∈ {0, 1}. The value C jj indicates whether we care about an adversary transforming a seed input in class j into one recognized by the model as being in class j . If the adversarial transformation j → j matters, C jj = 1, otherwise C jj = 0. Let Ω j = {j ∈ [m] : C jj = 0} be the index set of output classes that induce cost with respect to input class j. For any j ∈ [m]

Figure 1: Preliminary results on MNIST using overall robust classifier: (a) learning curves of the classification error and overall robust error over the 60 training epochs; (b) heatmap of the robust test error for pairwise class transformations based on the best trained classifier.

Figure 2: Cost-sensitive robust error using the proposed model and baseline model on MNIST for different binary tasks: (a) treat each digit as the seed class of concern respectively; (b) treat each digit as the target class of concern respectively.

Figure 3: Heatmaps of robust test error using our cost-sensitive robust classifier on MNIST for various real-valued cost tasks: (a) small-large; (b) large-small.

Figure 4: Heatmaps of robust test error for the real-valued task on CIFAR10 using different robust classifiers: (a) baseline model; (b) our proposed cost-sensitive robust model.

Figure 6: Learning curves for single seed task with digit 9 as the selected seed class on MNIST using the proposed model with varying α: (a) learning curves of classification error; (b) learning curves of cost-sensitive robust error. The maximum perturbation distance is specified as = 0.2.

Comparisons between different robust defense models on MNIST dataset against ∞ normbounded adversarial perturbations with = 0.2. The sparsity gives the number of non-zero entries in the cost matrix over the total number of possible adversarial transformations. The candidates column is the number of potential seed examples for each task.

Table content: <table><tr><td colspan="3">Task Description</td><td colspan="3">Sparsity Candidates Best α</td><td colspan="2">Classification Error</td><td>Robust Error</td></tr><tr><td/><td/><td/><td/><td/><td/><td>baseline</td><td>ours</td><td>baseline ours</td></tr><tr><td/><td/><td>(0,2)</td><td>1/90</td><td>980</td><td>10.0</td><td>3.39%</td><td>2.68%</td><td>0.92% 0.31%</td></tr><tr><td>single pair</td><td/><td>(6,5)</td><td>1/90</td><td>958</td><td>5.0</td><td>3.39%</td><td>2.49%</td><td>3.55% 0.42%</td></tr><tr><td/><td/><td>(4,9)</td><td>1/90</td><td>982</td><td>4.0</td><td>3.39%</td><td>3.00%</td><td>10.08% 1.02%</td></tr><tr><td/><td/><td>digit 0</td><td>9/90</td><td>980</td><td>10.0</td><td>3.39%</td><td>3.48%</td><td>3.67% 0.92%</td></tr><tr><td>single seed</td><td/><td>digit 2</td><td>9/90</td><td>1032</td><td>1.0</td><td>3.39%</td><td>2.91%</td><td>14.34% 3.68%</td></tr><tr><td/><td/><td>digit 8</td><td>9/90</td><td>974</td><td>0.4</td><td>3.39%</td><td>3.37%</td><td>22.28% 5.75%</td></tr><tr><td/><td/><td>digit 1</td><td>9/90</td><td>8865</td><td>4.0</td><td>3.39%</td><td>3.29%</td><td>2.23% 0.14%</td></tr><tr><td colspan="2">single target</td><td>digit 5</td><td>9/90</td><td>9108</td><td>2.0</td><td>3.39%</td><td>3.24%</td><td>3.10% 0.29%</td></tr><tr><td/><td/><td>digit 8</td><td>9/90</td><td>9026</td><td>1.0</td><td>3.39%</td><td>3.52%</td><td>5.24% 0.54%</td></tr><tr><td/><td/><td>top 10</td><td>10/90</td><td>6024</td><td>0.4</td><td>3.39%</td><td>3.34%</td><td>11.14% 7.02%</td></tr><tr><td>multiple</td><td/><td>random 10 odd digit</td><td>10/90 45/90</td><td>7028 5074</td><td>0.4 0.2</td><td>3.39% 3.39%</td><td>3.18% 3.30%</td><td>5.01% 2.18% 14.45% 9.97%</td></tr><tr><td/><td/><td>even digit</td><td>45/90</td><td>4926</td><td>0.1</td><td>3.39%</td><td>2.82%</td><td>13.13% 9.44%</td></tr><tr><td>digit 9 digit 8 digit 7 digit 6 digit 5 digit 4 digit 3 digit 2 digit 1 digit 0</td><td/><td/><td colspan="2">baseline model our model</td><td>digit 9 digit 8 digit 7 digit 6 digit 5 digit 4 digit 3 digit 2 digit 1 digit 0</td><td/><td/><td>baseline model our model</td></tr><tr><td>0.0%</td><td colspan="4">5.0% Cost-sensitive robust error 10.0% 15.0% 20.0%</td><td colspan="4">0.0% 1.0% 2.0% 3.0% 4.0% 5.0% Cost-sensitive robust error</td></tr><tr><td/><td/><td colspan="2">(a) single seed class</td><td/><td/><td colspan="3">(b) single target class</td></tr></table>

Comparison results of different robust defense models for tasks with real-valued cost matrix.

Table content: <table><tr><td colspan="2">Dataset Task</td><td colspan="3">Sparsity Candidates Best α</td><td colspan="2">Classification Error</td><td colspan="2">Robust Cost</td></tr><tr><td/><td/><td/><td/><td/><td>baseline</td><td>ours</td><td>baseline</td><td>ours</td></tr><tr><td colspan="2">MNIST small-large</td><td>45/90</td><td>10000</td><td>0.04</td><td>3.39%</td><td>3.47%</td><td>2.245</td><td>0.947</td></tr><tr><td colspan="2">MNIST large-small</td><td>45/90</td><td>10000</td><td>0.04</td><td>3.39%</td><td>3.13%</td><td>3.344</td><td>1.549</td></tr><tr><td>CIFAR</td><td>vehicle</td><td>40/90</td><td>4000</td><td>0.1</td><td>31.80%</td><td>26.19%</td><td>4.183</td><td>3.095</td></tr></table>

Cost-sensitive robust models for CIFAR10 dataset against adversarial examples, = 2/255.

Table content: <table><tr><td colspan="4">Task Description</td><td colspan="3">Sparsity Candidates Best α</td><td>Classification Error</td><td>Robust Error</td></tr><tr><td/><td/><td/><td/><td/><td/><td>baseline</td><td>ours</td><td>baseline</td><td>ours</td></tr><tr><td colspan="2">single pair</td><td colspan="3">(frog, bird) (cat, plane)</td><td>1/90 1/90</td><td>1000 1000</td><td>10.0 31.80% 27.88% 19.90% 1.20% 10.0 31.80% 28.63% 9.30% 2.60%</td></tr><tr><td colspan="2">single seed</td><td>dog truck</td><td/><td/><td>9/90 9/90</td><td>1000 1000</td><td>0.2 0.8</td><td>31.80% 30.69% 57.20% 28.90% 31.80% 31.55% 35.60% 15.40%</td></tr><tr><td colspan="2">single target</td><td>deer ship</td><td/><td/><td>9/90 9/90</td><td>9000 9000</td><td>0.1 0.1</td><td>31.80% 26.69% 16.99% 3.77% 31.80% 24.80% 9.42% 3.06%</td></tr><tr><td>multiple</td><td/><td>A-V V-A</td><td/><td/><td>24/90 24/90</td><td>6000 4000</td><td>0.1 0.2</td><td>31.80% 26.65% 16.67% 7.42% 31.80% 27.60% 12.07% 8.00%</td></tr><tr><td colspan="4">p la n e c a r b ir d c a t</td><td colspan="3">d e e r d o g f r o g h o r s e s h ip t r u c k</td></tr><tr><td>plane</td><td/><td colspan="5">7.2% 8.9% 9.5% 8.4% 8.0% 4.9% 7.4% 20.7% 10.7%</td></tr><tr><td>car</td><td>7.4%</td><td colspan="5">4.0% 7.2% 4.2% 5.7% 3.2% 3.8% 8.8% 18.5%</td></tr><tr><td>bird</td><td colspan="2">20.8% 8.3%</td><td colspan="4">38.9% 43.2% 35.7% 23.4% 19.1% 11.2% 8.6%</td></tr><tr><td>cat</td><td colspan="2">9.3% 5.2% 13.9%</td><td/><td colspan="3">18.6% 31.6% 14.3% 11.0% 6.8% 7.4%</td></tr><tr><td>deer</td><td colspan="4">12.9% 3.5% 22.1% 31.2%</td><td colspan="2">25.9% 18.5% 19.8% 7.3% 4.7%</td></tr><tr><td>dog</td><td colspan="4">8.2% 3.6% 15.8% 46.9% 17.3%</td><td colspan="2">11.5% 12.7% 6.5% 5.6%</td></tr><tr><td>frog</td><td colspan="5">7.3% 5.1% 19.9% 31.7% 30.5% 24.0%</td><td>10.9% 4.8% 5.9%</td></tr><tr><td>horse</td><td colspan="5">8.2% 4.6% 13.2% 24.7% 18.5% 24.4% 9.2%</td><td>5.7% 7.8%</td></tr><tr><td>ship</td><td colspan="6">14.0% 9.3% 5.3% 6.5% 4.6% 5.6% 3.1% 3.7%</td><td>9.8%</td></tr><tr><td>truck</td><td colspan="6">12.7% 20.9% 7.2% 10.4% 7.6% 8.4% 5.2% 9.2% 13.0%</td></tr></table>

Comparison results of different trained classifiers for small-large real-valued task on MNIST with maximum perturbation distance = 0.2.

Table content: <table><tr><td>Classifier</td><td colspan="3">Classification Error Misclassification Cost Robust Cost</td></tr><tr><td>Baseline</td><td>0.91%</td><td>0.054</td><td>85.197</td></tr><tr><td>Cost-Sensitive Standard</td><td>2.57%</td><td>0.016</td><td>85.197</td></tr><tr><td>Overall Robustness</td><td>3.49%</td><td>0.252</td><td>1.982</td></tr><tr><td>Cost-Sensitive Robustness</td><td>3.38%</td><td>0.060</td><td>0.915</td></tr></table>

Table 4 demonstrates the comparison results of different classifiers in such setting: the baseline standard deep learning classifier, a standard cost-sensitive classifier (Khan et al., 2018) trained using (B.1), classifier trained for overall robustness

Table content: <table/>

Peer review (iclr2019):
 The paper introduces a new concept of certified cost-sensitive robustness against adversarial attacks. A cost-sensitive robust optimization formulation is then proposed for deep adversarial learning. Experimental results on two benchmark datasets (MNIST, CIFAR-10) are reported to show the superiority of the proposed method to overall robustness method, both with binary and real-value cost matrices. The idea of cost-sensitive adversarial deep learning is well motivated. The proposed method is clearly presented and the results are easy to access. My main concern is about the novelty of the approach which looks mostly incremental as a rather direct extension of the robust model (Wong & Kolter 2018) to cost-sensitive setting. Particularly, the duality lower-bound based loss function and its related training procedure are almost identical to those from (Wong & Kolter 2018), up to certain trivial modification to respect the pre-specified misclassification costs. The numerical results show some promise. However, as a practical paper, the current empirical study appears limited in data scale: I believe additional evaluation on more challenging data sets can be useful to better support the importance of approach. Pros: - The concept of certified cost-sensitive robustness is well motivated and clearly presented. Cons: - The novelty of method is mostly incremental given the prior work of (Wong & Kolter 2018). - Numerical results show some promise of cost-sensitive adversarial learning in the considered settings, but still not supportive enough to the importance of approach.