1 00:00:00,000 --> 00:00:13,860 Hello, my name is Xiaojing Jiao. Today I will talk about how to leverage open source information to make effective adversarial attack and defense against deep learning model. 2 00:00:16,240 --> 00:00:25,320 Before I start, I'd like to introduce who we are. We are Northwest Security, a team of independent security researchers and data engineers. 3 00:00:28,180 --> 00:00:38,140 Right now, we have five members from left to right, Chen Li, Yang Chuan, Li Yang, Jiao Xiaojing, and Li Wei. 4 00:00:38,920 --> 00:00:46,480 We have diverse backgrounds, but we do have a united interest, which is to apply AI techniques to solve security issues. 5 00:00:48,320 --> 00:00:55,000 We have been fascinated by those ideas coming out of interaction between AI and security. 6 00:00:55,650 --> 00:01:00,140 We have been actively looking for opportunities to learn more along that direction. 7 00:01:01,030 --> 00:01:11,720 We also, we as a team, got invited for the CED CTF, which is the first CTF competition on adversarial attacks and defenses. 8 00:01:12,740 --> 00:01:20,620 As a new team attending the CTF for the first time, we learned a lot from the beginning of preparation to the end of competition. 9 00:01:21,760 --> 00:01:24,380 Today, this talk is going to mean... 10 00:01:25,320 --> 00:01:25,780 Oh, sorry. 11 00:01:26,380 --> 00:01:29,400 It's going to mainly focus on sharing our learning from this event. 12 00:01:30,080 --> 00:01:34,360 So this presentation is going to only include two parts. 13 00:01:34,700 --> 00:01:40,580 In the first part, I'm going to talk about how do we evaluate open source attacks and defenses. 14 00:01:41,160 --> 00:01:45,840 Then in the second part, we're going to introduce our design of the defense for the CTF. 15 00:01:48,780 --> 00:01:52,320 So, because due to the limitation of the time and the resources, 16 00:01:52,680 --> 00:01:55,220 we didn't try to develop our own. 17 00:01:56,820 --> 00:02:06,260 So, basically, our strategy is just try to utilize or leverage the public available information or open source code. 18 00:02:06,720 --> 00:02:11,140 So, in order to select those methods, we have to define a criteria. 19 00:02:11,740 --> 00:02:16,180 So, we define our criteria based on the requirement of the CTF. 20 00:02:16,660 --> 00:02:19,940 So, there are three factors we are considering. 21 00:02:20,260 --> 00:02:22,460 Speed, transferability, and strength. 22 00:02:24,020 --> 00:02:25,300 For defense. 23 00:02:25,300 --> 00:02:33,560 Because CTF has a hard requirement on how fast the image classifier has to run. 24 00:02:33,880 --> 00:02:36,600 So, we put that one as a top one priority. 25 00:02:37,360 --> 00:02:40,420 So, the requirement is two seconds per image. 26 00:02:41,620 --> 00:02:46,260 And also because we only can submit one defense. 27 00:02:46,620 --> 00:02:49,600 So, transferability is also very important. 28 00:02:49,860 --> 00:02:54,040 So, we even sacrifice our strengths. 29 00:02:54,040 --> 00:02:57,500 And to enhance our transferability. 30 00:02:59,160 --> 00:03:01,320 And on the other side, for the attack. 31 00:03:01,560 --> 00:03:04,280 Because there is no limitation on what kind of attack we can use. 32 00:03:04,340 --> 00:03:06,300 Or how many times we can attack. 33 00:03:06,640 --> 00:03:12,140 So, basically, we only consider the strength of the methods. 34 00:03:12,980 --> 00:03:18,900 But actually, this strategy turn out is not that 100% correct. 35 00:03:19,240 --> 00:03:21,260 So, because we just finished our CTF. 36 00:03:21,960 --> 00:03:25,180 Actually, the speed for attack is also important. 37 00:03:25,460 --> 00:03:28,780 Because we implemented some strong attacks. 38 00:03:28,980 --> 00:03:30,600 But it takes way long time. 39 00:03:30,740 --> 00:03:32,960 So, we don't have the opportunity to try it. 40 00:03:33,380 --> 00:03:40,520 So, basically, every time we each run, we only maybe just try maybe like one or two times. 41 00:03:40,700 --> 00:03:41,300 That's it. 42 00:03:41,440 --> 00:03:43,900 So, next time maybe we can improve on that. 43 00:03:44,520 --> 00:03:50,660 So, we use a target rate to evaluate the strength of the method. 44 00:03:50,660 --> 00:03:56,780 Which is a percentage of the images being misclassified as target classes. 45 00:03:59,700 --> 00:04:02,460 So, keep those criteria in mind. 46 00:04:02,620 --> 00:04:03,940 We start our evaluation. 47 00:04:04,500 --> 00:04:08,820 So, basically, the evaluation starts from building a baseline, basically. 48 00:04:09,040 --> 00:04:13,360 So, we do a benchmark of the base defense of the attacks. 49 00:04:13,640 --> 00:04:17,460 So, to do that, we use two open source libraries. 50 00:04:18,440 --> 00:04:19,560 For attack. 51 00:04:19,560 --> 00:04:21,200 We use CleverHands. 52 00:04:21,320 --> 00:04:22,720 Which is a Python library. 53 00:04:22,980 --> 00:04:24,240 Which are targeted. 54 00:04:24,460 --> 00:04:29,380 Which actually build to benchmark the machine learning system against adversarial attacks. 55 00:04:29,700 --> 00:04:33,800 So, it's basically a collection of different adversarial attack methods. 56 00:04:34,400 --> 00:04:36,140 And for defense. 57 00:04:37,380 --> 00:04:44,500 We actually, Google provided those pre-trained weights, actually. 58 00:04:44,760 --> 00:04:49,540 And even, they even provide those adversarial trained methods. 59 00:04:49,560 --> 00:04:58,300 So, what that mean is those model is trained by both original image and also some other several images. 60 00:05:01,200 --> 00:05:02,180 Let me see. 61 00:05:02,860 --> 00:05:05,560 So, there are, actually, there are two popular architectures. 62 00:05:06,280 --> 00:05:07,380 One is the Inception v3. 63 00:05:07,540 --> 00:05:09,500 And another is Inception ResNet v2. 64 00:05:11,560 --> 00:05:15,200 So, in order to do the evaluation, we have to use some test data set. 65 00:05:15,420 --> 00:05:18,640 So, basically, the test data set we are using is provided by CAD. 66 00:05:18,640 --> 00:05:22,040 Which include a thousand fresh images. 67 00:05:22,860 --> 00:05:24,660 Classified into a thousand classes. 68 00:05:24,940 --> 00:05:26,580 With ImageNet labels. 69 00:05:27,220 --> 00:05:29,200 If you look at the right hand side. 70 00:05:29,360 --> 00:05:30,120 That distribution. 71 00:05:31,280 --> 00:05:33,720 Target class versus true label. 72 00:05:34,430 --> 00:05:40,760 You can see the width of the distribution along the X direction is very consistent. 73 00:05:41,160 --> 00:05:47,400 So, that means those target class is randomly, uniformly selected. 74 00:05:47,400 --> 00:05:49,300 From zero to thousand. 75 00:05:49,480 --> 00:05:54,400 So, which means this is an average case of scenario. 76 00:05:54,920 --> 00:05:59,360 So, what that mean is if we use this data set to evaluate our method. 77 00:05:59,640 --> 00:06:03,220 That's going to give us average estimation of this method. 78 00:06:03,680 --> 00:06:05,840 It's not the best case and not the worst case. 79 00:06:05,980 --> 00:06:06,440 It's just average. 80 00:06:10,780 --> 00:06:15,060 So, by using those two libraries, we start our evaluation. 81 00:06:15,480 --> 00:06:16,540 So, this table shows. 82 00:06:17,340 --> 00:06:20,960 Hit target rate of four attacks against three defenses. 83 00:06:21,560 --> 00:06:25,480 So, all four attacks use the exact same gradient based method. 84 00:06:25,680 --> 00:06:28,400 Which is basic iterative method, DIM. 85 00:06:28,840 --> 00:06:30,260 The difference is. 86 00:06:30,740 --> 00:06:32,100 The first three. 87 00:06:32,280 --> 00:06:33,160 The difference is. 88 00:06:33,780 --> 00:06:36,780 The different model has been used to calculate the gradient. 89 00:06:37,120 --> 00:06:39,380 So, basically, the attack is calculated based on the gradient. 90 00:06:40,780 --> 00:06:43,240 But those three attacks use different models. 91 00:06:43,460 --> 00:06:45,520 Actually, they are corresponding to those three defenses. 92 00:06:45,520 --> 00:06:48,400 So, basically, the model in 7V3. 93 00:06:48,760 --> 00:06:51,760 And also the adversarial training in 7V3. 94 00:06:51,960 --> 00:06:55,740 And ensemble adversarial training in 7V2. 95 00:06:56,580 --> 00:06:58,700 Has been used to calculate the gradient. 96 00:06:58,900 --> 00:07:01,960 So, basically, we can say for each column. 97 00:07:02,160 --> 00:07:02,940 For each defense. 98 00:07:03,400 --> 00:07:05,740 We are doing a white box attack. 99 00:07:06,140 --> 00:07:08,760 So, we can say the white box attack is very effective, actually. 100 00:07:09,780 --> 00:07:11,640 For example, for the first one, DIM. 101 00:07:11,840 --> 00:07:13,400 Based on inception model. 102 00:07:13,400 --> 00:07:17,200 We can have like 89% hit target rate. 103 00:07:20,540 --> 00:07:23,500 But even for the second one and the third one. 104 00:07:23,620 --> 00:07:25,340 The second row and the third row. 105 00:07:25,460 --> 00:07:25,860 Those two. 106 00:07:28,420 --> 00:07:29,160 Oh, sorry. 107 00:07:29,280 --> 00:07:31,300 The second column and third column. 108 00:07:31,420 --> 00:07:32,120 Those two defenses. 109 00:07:32,560 --> 00:07:34,940 Those two defenses have been adversarial trained. 110 00:07:36,320 --> 00:07:37,800 Even for that model. 111 00:07:37,920 --> 00:07:40,740 It's still vulnerable to the white box attack. 112 00:07:41,080 --> 00:07:42,480 We can still have a very high. 113 00:07:42,480 --> 00:07:45,880 Like 75% and 85% hit target rates. 114 00:07:47,000 --> 00:07:48,520 But we can also say. 115 00:07:48,660 --> 00:07:51,940 Even though the white box attack is very strong. 116 00:07:52,180 --> 00:07:54,040 But the transferability is very bad. 117 00:07:54,320 --> 00:07:57,460 So, basically, it only works for that model. 118 00:07:58,080 --> 00:07:59,960 For example, if you look at the first row. 119 00:08:00,500 --> 00:08:02,620 It only works for 7V3. 120 00:08:02,840 --> 00:08:04,460 But for another two defenses. 121 00:08:04,620 --> 00:08:06,000 The hit target rate is zero. 122 00:08:06,260 --> 00:08:07,740 So, it doesn't work. 123 00:08:08,400 --> 00:08:12,200 But we can improve that by doing some ensembling. 124 00:08:12,480 --> 00:08:14,160 So, basically, the last attack. 125 00:08:14,900 --> 00:08:16,740 Ensembles three different models together. 126 00:08:17,120 --> 00:08:18,480 So, the basic idea is. 127 00:08:18,580 --> 00:08:21,020 We calculate three different adversarial images. 128 00:08:21,100 --> 00:08:22,120 Based on three models. 129 00:08:22,400 --> 00:08:24,280 Then we just calculate the average. 130 00:08:24,580 --> 00:08:27,940 And use that average image as our final attack. 131 00:08:28,880 --> 00:08:30,700 So, by doing that. 132 00:08:30,820 --> 00:08:32,180 You can see we can keep. 133 00:08:32,320 --> 00:08:34,280 We can still keep a high hit target rate. 134 00:08:34,460 --> 00:08:35,860 But also improve the transferability. 135 00:08:36,180 --> 00:08:38,340 So, basically, it works for all three defenses. 136 00:08:39,300 --> 00:08:40,200 So, that's just. 137 00:08:41,320 --> 00:08:41,800 Because. 138 00:08:42,480 --> 00:08:43,520 I forgot to mention. 139 00:08:43,700 --> 00:08:44,060 So, because. 140 00:08:44,220 --> 00:08:46,680 Those two labels are publicly available. 141 00:08:46,920 --> 00:08:48,500 So, basically, we treat those. 142 00:08:48,700 --> 00:08:51,120 When we analyze those performance. 143 00:08:51,400 --> 00:08:54,140 We just treat those like a lower boundary. 144 00:08:54,400 --> 00:08:54,880 So, basically. 145 00:08:54,960 --> 00:08:56,700 If we pick the attack or defense. 146 00:08:56,960 --> 00:08:57,460 It has to. 147 00:08:57,540 --> 00:09:00,580 It must be better than those methods. 148 00:09:02,420 --> 00:09:03,140 So, now. 149 00:09:03,220 --> 00:09:03,420 Then. 150 00:09:03,940 --> 00:09:04,840 We try. 151 00:09:04,920 --> 00:09:07,420 We also try some strong defense. 152 00:09:07,740 --> 00:09:09,740 Like guided denoise. 153 00:09:12,480 --> 00:09:13,700 That is sitting in the audience. 154 00:09:15,040 --> 00:09:17,060 And also the random padding. 155 00:09:17,260 --> 00:09:18,000 So, both of them. 156 00:09:18,100 --> 00:09:19,960 Actually the first and the second place. 157 00:09:20,220 --> 00:09:22,580 In the 2017 NIPS. 158 00:09:23,260 --> 00:09:24,680 Adelsera Defense Competition. 159 00:09:25,320 --> 00:09:26,260 So, you can see. 160 00:09:26,320 --> 00:09:28,340 Those two defenses are very strong. 161 00:09:28,580 --> 00:09:29,020 So, basically. 162 00:09:29,020 --> 00:09:30,240 For those four attacks. 163 00:09:30,620 --> 00:09:32,080 The hit target rate is zero. 164 00:09:32,320 --> 00:09:35,020 So, it's just totally not working. 165 00:09:37,480 --> 00:09:38,000 But. 166 00:09:39,560 --> 00:09:40,420 For us. 167 00:09:40,540 --> 00:09:41,940 Our strategy for. 168 00:09:42,480 --> 00:09:43,200 Attack selection. 169 00:09:43,500 --> 00:09:44,680 Is basically just make sure. 170 00:09:44,800 --> 00:09:46,720 We have a corresponding attack. 171 00:09:47,000 --> 00:09:49,660 For each single defense we can find. 172 00:09:51,140 --> 00:09:51,860 So, because. 173 00:09:51,980 --> 00:09:53,120 There is no limitation on. 174 00:09:53,240 --> 00:09:54,620 How many times we can try. 175 00:09:54,780 --> 00:09:55,120 So, basically. 176 00:09:55,160 --> 00:09:56,380 We build a set of. 177 00:09:56,500 --> 00:09:57,860 A broad set of attacks. 178 00:09:58,240 --> 00:10:00,300 For this CTF competition. 179 00:10:01,540 --> 00:10:03,740 So, this diagram is a polar plot. 180 00:10:04,020 --> 00:10:06,140 Which is a polar plot of hit target rate. 181 00:10:06,460 --> 00:10:07,100 So, basically. 182 00:10:07,100 --> 00:10:08,900 Different colors stand for. 183 00:10:09,020 --> 00:10:10,020 Different attacks. 184 00:10:10,480 --> 00:10:13,160 And six different defense. 185 00:10:13,500 --> 00:10:15,060 Is located on six different. 186 00:10:15,400 --> 00:10:16,280 Angular position. 187 00:10:17,180 --> 00:10:18,440 So, from this. 188 00:10:18,580 --> 00:10:20,240 This is like a needle like branch. 189 00:10:20,520 --> 00:10:22,020 So, this needle like branch pattern. 190 00:10:22,260 --> 00:10:24,060 Actually can tell us two kinds of info. 191 00:10:24,420 --> 00:10:26,360 One is the length of the branch. 192 00:10:26,860 --> 00:10:29,040 Which is the value of the hit target rate. 193 00:10:29,260 --> 00:10:30,800 So, which actually is the strength. 194 00:10:30,900 --> 00:10:31,500 Of the attack. 195 00:10:32,140 --> 00:10:33,960 And the number of branch. 196 00:10:34,380 --> 00:10:35,840 Which actually tells us. 197 00:10:37,100 --> 00:10:38,440 What the transability of this method is. 198 00:10:38,740 --> 00:10:40,500 Because the more branch we have. 199 00:10:40,620 --> 00:10:42,080 Which means this single method. 200 00:10:42,460 --> 00:10:44,280 Can attack more defenses. 201 00:10:44,680 --> 00:10:45,480 So, basically. 202 00:10:45,980 --> 00:10:47,700 Through all our evaluation. 203 00:10:47,900 --> 00:10:49,060 We use this plot. 204 00:10:49,240 --> 00:10:50,380 To evaluate all the methods. 205 00:10:50,860 --> 00:10:52,400 Just trying to get a balance. 206 00:10:52,520 --> 00:10:55,340 Between the transability and the defense. 207 00:10:56,320 --> 00:10:57,540 So, those three methods. 208 00:10:57,660 --> 00:10:58,560 We implemented. 209 00:10:59,060 --> 00:11:00,320 So, for guided denoise. 210 00:11:00,480 --> 00:11:01,760 We kind of like. 211 00:11:01,820 --> 00:11:03,360 Because they open source everything. 212 00:11:07,100 --> 00:11:08,020 Which is actually very effective. 213 00:11:08,740 --> 00:11:10,020 We can get like. 214 00:11:10,160 --> 00:11:11,860 98% hit target rate. 215 00:11:12,160 --> 00:11:14,580 And for another two kinds of defense. 216 00:11:14,740 --> 00:11:15,760 Like random padding. 217 00:11:15,900 --> 00:11:17,820 Basically they randomly adding some. 218 00:11:18,120 --> 00:11:19,920 Paddings onto the input image. 219 00:11:20,260 --> 00:11:21,600 Because they try to utilize. 220 00:11:21,860 --> 00:11:23,800 The transfer environment feature. 221 00:11:23,960 --> 00:11:26,520 Of the CNN based image classifier. 222 00:11:26,720 --> 00:11:27,140 So, basically. 223 00:11:27,320 --> 00:11:29,000 For original image. 224 00:11:29,220 --> 00:11:31,100 If you add random stuff on it. 225 00:11:31,280 --> 00:11:33,720 It won't affect the classification results. 226 00:11:34,120 --> 00:11:36,580 But if we input a fake image. 227 00:11:37,100 --> 00:11:37,880 Out of a serial image. 228 00:11:38,100 --> 00:11:39,860 When you add some random stuff. 229 00:11:40,220 --> 00:11:40,940 Onto it. 230 00:11:41,120 --> 00:11:43,640 It's going to strongly degrade. 231 00:11:43,980 --> 00:11:45,860 The influence of that attack. 232 00:11:46,240 --> 00:11:48,100 So, that's the idea of the random padding. 233 00:11:48,440 --> 00:11:50,040 So, we also implant some. 234 00:11:51,160 --> 00:11:52,280 Adopt some method. 235 00:11:52,400 --> 00:11:54,500 To implant a targeted attack. 236 00:11:54,740 --> 00:11:55,420 For that. 237 00:11:58,320 --> 00:11:59,080 So, now. 238 00:11:59,180 --> 00:12:00,760 I will talk about some strategies. 239 00:12:00,860 --> 00:12:02,600 We applied in. 240 00:12:03,200 --> 00:12:04,580 Both defense and attack. 241 00:12:04,880 --> 00:12:06,420 So, basically for the first row. 242 00:12:07,100 --> 00:12:07,260 It's called defense. 243 00:12:08,620 --> 00:12:09,840 It's very popular one. 244 00:12:09,940 --> 00:12:12,000 It's called ensemble adversarial training. 245 00:12:12,180 --> 00:12:12,580 So, basically. 246 00:12:12,940 --> 00:12:15,320 We not only just train the model. 247 00:12:15,400 --> 00:12:16,860 With both original image. 248 00:12:17,060 --> 00:12:17,940 And adversarial image. 249 00:12:18,180 --> 00:12:21,800 We also try to generate those adversarial image. 250 00:12:22,000 --> 00:12:24,360 From several different methods. 251 00:12:24,640 --> 00:12:25,320 So, we tried. 252 00:12:25,440 --> 00:12:26,400 By doing that. 253 00:12:26,500 --> 00:12:28,520 By doing this ensemble adversarial training. 254 00:12:28,760 --> 00:12:29,920 You can strongly. 255 00:12:30,120 --> 00:12:32,020 You can effectively improve the transferability. 256 00:12:32,100 --> 00:12:33,160 Of your defense. 257 00:12:37,100 --> 00:12:37,120 And also. 258 00:12:38,340 --> 00:12:40,560 Apply ensemble adversarial attacking. 259 00:12:41,020 --> 00:12:42,440 Which also can improve. 260 00:12:42,640 --> 00:12:44,200 The transferability of your attack method. 261 00:12:44,680 --> 00:12:45,060 So, basically. 262 00:12:45,320 --> 00:12:46,120 Same idea. 263 00:12:46,320 --> 00:12:48,960 You can apply for both defense and attack. 264 00:12:49,960 --> 00:12:51,100 Another idea is. 265 00:12:52,100 --> 00:12:53,860 For defense is gradient masking. 266 00:12:54,200 --> 00:12:54,680 So, basically. 267 00:12:55,920 --> 00:12:56,700 Right now. 268 00:12:56,840 --> 00:12:58,940 For those popular attacks. 269 00:12:59,260 --> 00:13:00,380 Most of the popular attacks. 270 00:13:00,560 --> 00:13:01,800 Is gradient based. 271 00:13:02,100 --> 00:13:02,580 So, basically. 272 00:13:07,100 --> 00:13:07,900 If you have a gradient of that. 273 00:13:08,820 --> 00:13:09,660 Target model. 274 00:13:09,940 --> 00:13:10,820 Then based on the gradient. 275 00:13:10,960 --> 00:13:12,540 You can generate your attacks. 276 00:13:13,080 --> 00:13:14,400 But this gradient mask. 277 00:13:14,600 --> 00:13:17,780 Is just trying to hide those gradient info. 278 00:13:18,080 --> 00:13:19,280 So, they can. 279 00:13:20,540 --> 00:13:23,180 They can just make gradient unsmooth. 280 00:13:23,440 --> 00:13:24,040 Which means. 281 00:13:24,220 --> 00:13:25,200 It's kind of like stabilized. 282 00:13:26,000 --> 00:13:28,700 Or they can just make the gradient vanish. 283 00:13:28,900 --> 00:13:30,400 Totally become very small. 284 00:13:30,640 --> 00:13:31,480 Or very large. 285 00:13:31,580 --> 00:13:32,160 It's exploding. 286 00:13:32,560 --> 00:13:33,100 So, basically. 287 00:13:37,100 --> 00:13:37,640 They can go in the wrong direction. 288 00:13:37,820 --> 00:13:38,500 Basically. 289 00:13:38,660 --> 00:13:39,800 By doing that. 290 00:13:39,880 --> 00:13:42,320 They can achieve the defensing purpose. 291 00:13:44,360 --> 00:13:45,040 But. 292 00:13:45,700 --> 00:13:46,380 Still. 293 00:13:46,660 --> 00:13:48,160 On the attack side. 294 00:13:48,420 --> 00:13:49,460 Researchers still. 295 00:13:49,500 --> 00:13:52,780 Also propose some corresponding attacking strategies. 296 00:13:53,480 --> 00:13:53,800 Basically. 297 00:13:53,880 --> 00:13:56,200 If you make a stepwise gradient. 298 00:13:57,020 --> 00:13:57,520 Basically. 299 00:13:57,560 --> 00:14:00,080 You generate a lot of local minimum. 300 00:14:00,800 --> 00:14:01,240 So. 301 00:14:01,240 --> 00:14:01,800 Then. 302 00:14:01,960 --> 00:14:05,140 When the attack try to escape from those local minimum. 303 00:14:05,440 --> 00:14:05,920 They just. 304 00:14:06,080 --> 00:14:06,560 They can. 305 00:14:06,700 --> 00:14:07,760 There's one way they can do it. 306 00:14:07,800 --> 00:14:09,700 They can just add a random perturbation. 307 00:14:10,520 --> 00:14:13,380 Each time onto that calculation. 308 00:14:13,860 --> 00:14:14,240 So, basically. 309 00:14:14,280 --> 00:14:17,900 When you start into some local spot. 310 00:14:18,120 --> 00:14:19,180 And then you just randomly jump. 311 00:14:19,340 --> 00:14:19,980 Jump it out. 312 00:14:20,520 --> 00:14:21,460 That's just the idea. 313 00:14:22,160 --> 00:14:23,920 That's the idea of random perturbation. 314 00:14:24,180 --> 00:14:24,700 And also. 315 00:14:24,700 --> 00:14:25,960 Some attack. 316 00:14:26,080 --> 00:14:27,880 They use a gradient smoothing. 317 00:14:28,080 --> 00:14:28,480 So, basically. 318 00:14:28,520 --> 00:14:29,040 When you calculate. 319 00:14:29,340 --> 00:14:30,820 When they get a gradient info. 320 00:14:31,120 --> 00:14:33,940 They apply a Gaussian smoothing. 321 00:14:33,960 --> 00:14:35,640 And smooth that gradient out. 322 00:14:35,940 --> 00:14:38,200 So, everything is perfect for the attack. 323 00:14:38,280 --> 00:14:38,660 Again. 324 00:14:40,140 --> 00:14:42,260 A third new method is called. 325 00:14:42,800 --> 00:14:44,860 Backward pass differentiable approximation. 326 00:14:45,300 --> 00:14:45,720 So, basically. 327 00:14:45,820 --> 00:14:47,540 So, basically. 328 00:14:47,580 --> 00:14:48,400 This method is just. 329 00:14:48,400 --> 00:14:50,460 We cannot get the. 330 00:14:50,940 --> 00:14:52,480 The real gradient. 331 00:14:52,560 --> 00:14:54,480 Real gradient from that network. 332 00:14:54,680 --> 00:14:55,240 Then we can. 333 00:14:55,400 --> 00:14:58,160 Then somehow we can approximately calculate one. 334 00:14:58,980 --> 00:14:59,820 So, basically. 335 00:14:59,860 --> 00:15:00,680 That's the idea. 336 00:15:01,040 --> 00:15:03,760 So, we don't use the target to calculate the gradient. 337 00:15:03,920 --> 00:15:06,420 We just somehow come out an idea. 338 00:15:06,580 --> 00:15:07,680 Get a close one. 339 00:15:08,080 --> 00:15:10,460 And use that one as our gradient. 340 00:15:10,720 --> 00:15:12,120 Then achieve the. 341 00:15:12,420 --> 00:15:13,280 The attack. 342 00:15:14,560 --> 00:15:16,800 The third strategy for defense. 343 00:15:17,420 --> 00:15:18,240 So, basically. 344 00:15:18,400 --> 00:15:18,980 The gradient. 345 00:15:19,260 --> 00:15:20,640 The adversarial attack. 346 00:15:20,880 --> 00:15:21,340 Which is. 347 00:15:21,840 --> 00:15:24,540 Because of the adversarial noise. 348 00:15:24,920 --> 00:15:26,420 So, it is a noise. 349 00:15:26,900 --> 00:15:30,160 So, very nature solution for the noise is. 350 00:15:30,320 --> 00:15:31,980 Just do a filtering. 351 00:15:32,280 --> 00:15:33,480 Just get rid of noise. 352 00:15:33,940 --> 00:15:35,260 So, that's the third. 353 00:15:35,400 --> 00:15:37,500 The basic idea of the third one. 354 00:15:37,660 --> 00:15:38,100 Which is. 355 00:15:38,400 --> 00:15:40,720 Which is use some image processing method. 356 00:15:40,980 --> 00:15:43,560 Just filter those noise out. 357 00:15:44,460 --> 00:15:45,300 But still. 358 00:15:45,460 --> 00:15:46,500 From attack side. 359 00:15:48,400 --> 00:15:48,540 And figure out. 360 00:15:48,620 --> 00:15:50,600 How to attack this kind of defense. 361 00:15:50,920 --> 00:15:51,540 So, basically. 362 00:15:51,980 --> 00:15:53,980 What you are doing in the defense side. 363 00:15:54,260 --> 00:15:56,300 I just doing the same thing on the attack side. 364 00:15:56,560 --> 00:15:57,520 When I calculate the attack. 365 00:15:57,800 --> 00:16:00,780 We just improve those filtering or anything inside it. 366 00:16:01,020 --> 00:16:02,780 So, when I calculate the attack. 367 00:16:02,940 --> 00:16:04,700 It's going to take into account everything. 368 00:16:05,360 --> 00:16:06,320 So, that's the idea. 369 00:16:06,540 --> 00:16:07,500 So, actually we use this. 370 00:16:07,580 --> 00:16:10,480 We use this method to achieve the attack. 371 00:16:10,600 --> 00:16:11,640 Against the random padding. 372 00:16:11,940 --> 00:16:12,480 So, basically. 373 00:16:12,480 --> 00:16:16,540 When we calculate the attacking adversarial image. 374 00:16:16,700 --> 00:16:18,060 We also add the random padding. 375 00:16:18,220 --> 00:16:19,700 Into an iterative calculation. 376 00:16:21,380 --> 00:16:22,560 Then the last one. 377 00:16:23,100 --> 00:16:24,800 I think that's the only one. 378 00:16:24,920 --> 00:16:26,520 There is no effect attack method. 379 00:16:27,440 --> 00:16:28,300 So, which is. 380 00:16:29,160 --> 00:16:30,280 Detection only method. 381 00:16:30,500 --> 00:16:30,860 So, basically. 382 00:16:32,100 --> 00:16:34,520 It's not enhance the. 383 00:16:35,520 --> 00:16:37,300 The robustness of the system. 384 00:16:37,520 --> 00:16:39,200 It's just add on another module. 385 00:16:39,380 --> 00:16:39,840 To attack. 386 00:16:40,080 --> 00:16:42,320 If there is an adversarial attack happening. 387 00:16:42,480 --> 00:16:42,720 Or not. 388 00:16:43,380 --> 00:16:44,360 If it's happening. 389 00:16:44,560 --> 00:16:45,820 We just give an alert. 390 00:16:45,980 --> 00:16:48,760 Or we just return some random stuff. 391 00:16:50,500 --> 00:16:51,740 That's the idea of a detection. 392 00:16:55,300 --> 00:16:56,400 So, that's all. 393 00:16:56,600 --> 00:16:57,360 About the evaluation. 394 00:16:57,820 --> 00:16:58,780 So, based on the. 395 00:16:58,960 --> 00:17:02,180 We do a very extensive evaluation. 396 00:17:03,160 --> 00:17:04,520 Of a lot of attacks. 397 00:17:04,640 --> 00:17:05,020 And defenses. 398 00:17:06,000 --> 00:17:07,400 Then based on those learning. 399 00:17:07,560 --> 00:17:10,380 We came out this design of our defense. 400 00:17:10,980 --> 00:17:11,780 So, basically. 401 00:17:12,480 --> 00:17:13,840 The defense includes two modules. 402 00:17:14,340 --> 00:17:15,500 The first one. 403 00:17:17,440 --> 00:17:18,660 The left hand side. 404 00:17:18,840 --> 00:17:19,560 That big. 405 00:17:20,060 --> 00:17:21,140 Big rectangle. 406 00:17:22,240 --> 00:17:24,820 Which actually is our image classifier. 407 00:17:25,420 --> 00:17:26,780 But this image classifier. 408 00:17:26,840 --> 00:17:28,320 Includes two image classifiers. 409 00:17:28,660 --> 00:17:29,180 So, basically. 410 00:17:29,240 --> 00:17:32,400 We parallel align those two image classifiers. 411 00:17:32,500 --> 00:17:32,740 Together. 412 00:17:33,800 --> 00:17:36,300 Then we put a difference filter. 413 00:17:36,460 --> 00:17:37,280 At the end. 414 00:17:37,460 --> 00:17:38,900 So, basically what is happening is. 415 00:17:38,900 --> 00:17:40,860 When there is an adversarial image coming. 416 00:17:41,140 --> 00:17:42,500 It's going to get classified. 417 00:17:42,640 --> 00:17:44,600 By both of those two classifiers. 418 00:17:44,780 --> 00:17:46,700 One is the CV2 plus random padding. 419 00:17:47,000 --> 00:17:48,880 Another is a guided noise. 420 00:17:49,560 --> 00:17:50,140 So, then. 421 00:17:50,220 --> 00:17:51,720 There are two labels. 422 00:17:52,180 --> 00:17:53,860 Output from those two classifiers. 423 00:17:54,260 --> 00:17:57,280 Going to get fit into that difference filter. 424 00:17:57,560 --> 00:17:57,980 So, basically. 425 00:17:57,980 --> 00:17:58,620 We're going to compare. 426 00:17:58,780 --> 00:18:00,960 If those two agree with each other. 427 00:18:01,080 --> 00:18:01,580 Then we think. 428 00:18:03,760 --> 00:18:05,540 That's the attack field. 429 00:18:05,700 --> 00:18:06,140 Basically. 430 00:18:08,900 --> 00:18:09,520 That's the true label. 431 00:18:09,740 --> 00:18:13,120 But if they don't agree with each other. 432 00:18:13,260 --> 00:18:14,440 Or contradict with each other. 433 00:18:14,640 --> 00:18:15,880 Then we just. 434 00:18:16,120 --> 00:18:18,520 Simply return a zero or random number. 435 00:18:19,800 --> 00:18:20,820 So, that's the. 436 00:18:20,820 --> 00:18:22,020 Idea of the first module. 437 00:18:23,980 --> 00:18:24,960 So, I want to. 438 00:18:25,040 --> 00:18:26,480 Spend a little bit of time on that. 439 00:18:27,300 --> 00:18:28,080 CV2 filter. 440 00:18:30,000 --> 00:18:30,960 So, basically. 441 00:18:31,380 --> 00:18:32,760 CV2 is the name of the. 442 00:18:33,160 --> 00:18:34,740 OpenCV package in Python. 443 00:18:35,200 --> 00:18:35,700 So, basically. 444 00:18:36,940 --> 00:18:38,820 This is also an image percentage. 445 00:18:38,900 --> 00:18:39,240 Image processing idea. 446 00:18:39,960 --> 00:18:41,380 Because when we are doing. 447 00:18:41,540 --> 00:18:42,920 We read a lot of codes. 448 00:18:43,120 --> 00:18:44,000 They are doing a lot of. 449 00:18:44,140 --> 00:18:46,480 They are doing the image processing. 450 00:18:46,480 --> 00:18:47,960 Through a lot of different ways. 451 00:18:48,500 --> 00:18:49,680 But then we think. 452 00:18:49,780 --> 00:18:53,100 Why don't we just use a professional package. 453 00:18:53,200 --> 00:18:54,720 Just doing the image processing. 454 00:18:54,980 --> 00:18:57,080 So, OpenCV is the very famous. 455 00:18:57,140 --> 00:18:58,780 Open source library. 456 00:18:59,200 --> 00:19:00,600 They are just doing the image. 457 00:19:00,700 --> 00:19:01,760 Image processing. 458 00:19:02,280 --> 00:19:04,760 So, they provide a lot of sophisticated functions. 459 00:19:05,820 --> 00:19:06,700 So, basically. 460 00:19:08,900 --> 00:19:10,180 It's implemented by C. 461 00:19:10,400 --> 00:19:11,320 So, it's very fast. 462 00:19:11,560 --> 00:19:13,120 And very easy to use. 463 00:19:13,260 --> 00:19:15,020 Basically, you can just use the function. 464 00:19:15,240 --> 00:19:16,320 Just add one line. 465 00:19:16,500 --> 00:19:18,560 Just as simple as one line code. 466 00:19:18,860 --> 00:19:20,000 Just add the filter. 467 00:19:20,300 --> 00:19:22,600 In any existing defenses. 468 00:19:23,980 --> 00:19:24,940 So, right now. 469 00:19:25,000 --> 00:19:26,280 What we are using is called. 470 00:19:26,640 --> 00:19:27,420 Bilaterally filtering. 471 00:19:27,780 --> 00:19:29,660 So, which is edge preserving. 472 00:19:30,880 --> 00:19:32,680 Nodes reducing smoothing filter. 473 00:19:32,980 --> 00:19:33,560 So, basically. 474 00:19:33,560 --> 00:19:34,380 What it's doing is. 475 00:19:34,420 --> 00:19:36,040 Actually those four images. 476 00:19:36,140 --> 00:19:37,260 Show the effect. 477 00:19:37,620 --> 00:19:40,420 So, the left up corner. 478 00:19:40,840 --> 00:19:44,020 The first one is the original adversarial image. 479 00:19:44,460 --> 00:19:45,040 Then. 480 00:19:45,160 --> 00:19:47,240 If you go through those filters. 481 00:19:47,440 --> 00:19:48,260 Three times. 482 00:19:48,480 --> 00:19:49,200 And the last one. 483 00:19:49,380 --> 00:19:50,380 The bottom right. 484 00:19:50,660 --> 00:19:51,200 That one. 485 00:19:51,960 --> 00:19:52,780 You can see that. 486 00:19:52,880 --> 00:19:54,860 Those funny patterns on the background. 487 00:19:55,120 --> 00:19:57,560 Those actually is the adversarial partition. 488 00:19:58,420 --> 00:20:00,760 Try to confuse the classify. 489 00:20:03,560 --> 00:20:04,720 So, all those filters. 490 00:20:05,740 --> 00:20:08,020 Those noise is smooth out. 491 00:20:08,280 --> 00:20:09,360 But at the same time. 492 00:20:09,420 --> 00:20:11,080 The edge is still preserved. 493 00:20:11,820 --> 00:20:12,840 Because we know. 494 00:20:12,920 --> 00:20:14,380 For those image classifier. 495 00:20:15,080 --> 00:20:16,020 They kind of like. 496 00:20:16,120 --> 00:20:18,320 They try to learn those edges. 497 00:20:18,600 --> 00:20:20,420 So, if you can maintain those edges. 498 00:20:21,160 --> 00:20:23,200 Which means this matter won't affect. 499 00:20:23,340 --> 00:20:25,500 Your classification accuracy. 500 00:20:27,060 --> 00:20:29,160 So, to prove that. 501 00:20:29,440 --> 00:20:30,660 We apply this. 502 00:20:31,640 --> 00:20:32,620 CV2 filter. 503 00:20:33,740 --> 00:20:35,640 Guided denoise defense. 504 00:20:36,840 --> 00:20:37,480 And. 505 00:20:37,840 --> 00:20:39,180 Use it against. 506 00:20:39,440 --> 00:20:40,400 Three different. 507 00:20:41,660 --> 00:20:42,300 Attacks. 508 00:20:42,600 --> 00:20:44,600 So, this time those color. 509 00:20:45,160 --> 00:20:46,620 Pattern stands for defense. 510 00:20:47,580 --> 00:20:48,220 And. 511 00:20:49,720 --> 00:20:51,580 The left up corner. 512 00:20:51,820 --> 00:20:52,740 That one is. 513 00:20:52,820 --> 00:20:53,760 What we implement. 514 00:20:55,320 --> 00:20:57,400 Attacks against this guided denoise method. 515 00:20:57,740 --> 00:20:58,500 So, you can see. 516 00:20:58,720 --> 00:20:59,720 The yellow one. 517 00:20:59,820 --> 00:21:01,300 Which is the one we use. 518 00:21:04,120 --> 00:21:06,020 This guided denoise method. 519 00:21:06,300 --> 00:21:08,040 It can effectively reduce. 520 00:21:08,140 --> 00:21:09,320 The pay target rate. 521 00:21:09,560 --> 00:21:11,320 From 96%. 522 00:21:11,320 --> 00:21:12,580 Down to like. 523 00:21:13,520 --> 00:21:14,120 45%. 524 00:21:15,920 --> 00:21:18,100 So, our method is. 525 00:21:18,220 --> 00:21:19,460 This CV2 filter. 526 00:21:19,600 --> 00:21:21,900 Is actually the effective method. 527 00:21:22,220 --> 00:21:23,400 And also the reason. 528 00:21:23,440 --> 00:21:25,040 Why we put another two defenses. 529 00:21:25,540 --> 00:21:26,660 Another two attacks. 530 00:21:26,880 --> 00:21:28,440 On the other side. 531 00:21:28,700 --> 00:21:30,000 We just try to save. 532 00:21:30,080 --> 00:21:31,000 This CV2 filter. 533 00:21:33,560 --> 00:21:34,620 But it turns out. 534 00:21:34,760 --> 00:21:36,840 It doesn't do that. 535 00:21:37,520 --> 00:21:38,560 So, we think. 536 00:21:38,620 --> 00:21:39,900 We believe this CV2 filter. 537 00:21:40,000 --> 00:21:42,100 Is a very effective. 538 00:21:42,480 --> 00:21:43,440 Way to. 539 00:21:43,960 --> 00:21:45,820 At least enhance your defense. 540 00:21:46,680 --> 00:21:48,160 Because it's very fast. 541 00:21:48,380 --> 00:21:50,200 And it's also very flexible. 542 00:21:50,380 --> 00:21:52,200 You can apply it. 543 00:21:52,220 --> 00:21:53,540 To any existing system. 544 00:21:56,020 --> 00:21:57,220 So, that's. 545 00:21:57,220 --> 00:21:58,620 About the first module. 546 00:21:58,940 --> 00:21:59,840 So, the first module. 547 00:22:00,140 --> 00:22:01,460 The successful defense. 548 00:22:03,560 --> 00:22:03,860 The first module. 549 00:22:04,240 --> 00:22:05,420 Relying on our assumption. 550 00:22:05,660 --> 00:22:06,340 Which is. 551 00:22:06,700 --> 00:22:07,800 There's no attack. 552 00:22:08,000 --> 00:22:09,020 Which is strong enough. 553 00:22:09,440 --> 00:22:12,100 To fool or confuse both of them. 554 00:22:12,740 --> 00:22:14,420 But that's not true actually. 555 00:22:14,760 --> 00:22:16,540 Even we know that's not true. 556 00:22:16,620 --> 00:22:18,080 Because when we do the testing. 557 00:22:18,520 --> 00:22:19,780 There's some attacks. 558 00:22:20,080 --> 00:22:21,700 Which can fool both of them. 559 00:22:22,300 --> 00:22:23,680 CV2 plus random finding. 560 00:22:23,820 --> 00:22:24,800 And also the guided denoise. 561 00:22:24,940 --> 00:22:25,280 So, basically. 562 00:22:25,280 --> 00:22:26,920 Both of them gonna output. 563 00:22:27,520 --> 00:22:28,860 The exact same label. 564 00:22:28,940 --> 00:22:29,820 But that label is wrong. 565 00:22:30,960 --> 00:22:31,840 So, which means. 566 00:22:31,980 --> 00:22:33,380 The first module gonna fail. 567 00:22:33,520 --> 00:22:34,700 If that happens. 568 00:22:35,080 --> 00:22:38,120 So, that's where the second module come into play. 569 00:22:38,320 --> 00:22:39,660 Which is a K-mean filter. 570 00:22:42,560 --> 00:22:43,040 So. 571 00:22:43,700 --> 00:22:45,540 This K-mean filter is based on. 572 00:22:45,580 --> 00:22:46,480 A machine learning method. 573 00:22:46,580 --> 00:22:47,580 Called K-mean clustering. 574 00:22:49,920 --> 00:22:50,400 So. 575 00:22:50,880 --> 00:22:52,600 The assumption here is. 576 00:22:52,780 --> 00:22:53,980 This K-mean clustering. 577 00:22:55,280 --> 00:22:56,520 Is robust against. 578 00:22:56,600 --> 00:22:58,880 Neural network based adversarial attack. 579 00:22:59,340 --> 00:23:00,680 So, in order to. 580 00:23:01,120 --> 00:23:01,940 Verify that. 581 00:23:02,140 --> 00:23:04,600 We conduct a very little experiment. 582 00:23:05,540 --> 00:23:07,160 So, this is an experiment. 583 00:23:07,380 --> 00:23:07,700 So, basically. 584 00:23:07,820 --> 00:23:08,940 What I'm doing is. 585 00:23:10,620 --> 00:23:12,920 There's a thousand original images. 586 00:23:13,080 --> 00:23:15,580 Then we generate another thousand adversarial images. 587 00:23:16,520 --> 00:23:19,240 Then we put both those two thousand images. 588 00:23:19,500 --> 00:23:21,360 Into this K-mean clustering. 589 00:23:21,560 --> 00:23:22,680 So, this K-mean clustering gonna. 590 00:23:23,160 --> 00:23:24,120 Gonna put. 591 00:23:25,280 --> 00:23:26,820 And automatically classify those images. 592 00:23:26,900 --> 00:23:28,500 Into different classes. 593 00:23:28,880 --> 00:23:29,880 Then we compare. 594 00:23:30,540 --> 00:23:33,060 Each original images classes. 595 00:23:34,040 --> 00:23:35,160 Against that. 596 00:23:35,900 --> 00:23:36,840 Adversarial version. 597 00:23:37,100 --> 00:23:38,020 Then we found that. 598 00:23:38,080 --> 00:23:40,460 Actually ninety-four percent of them are matched. 599 00:23:40,860 --> 00:23:41,680 So, which means. 600 00:23:41,800 --> 00:23:43,660 Those adversarial attack doesn't affect. 601 00:23:43,980 --> 00:23:45,820 The accuracy of the K-mean clustering. 602 00:23:46,100 --> 00:23:47,600 So, we can trust this method. 603 00:23:49,440 --> 00:23:50,860 Then based on that method. 604 00:23:52,220 --> 00:23:53,380 I'm gonna talk about. 605 00:23:53,460 --> 00:23:54,520 How we implement. 606 00:23:55,280 --> 00:23:55,420 K-mean filter. 607 00:23:55,780 --> 00:23:56,260 So, basically. 608 00:23:56,620 --> 00:23:57,660 The first one. 609 00:23:57,820 --> 00:23:58,840 The top one is. 610 00:23:59,260 --> 00:24:01,360 Describe how we generate a mapping. 611 00:24:01,520 --> 00:24:03,140 Because this. 612 00:24:03,860 --> 00:24:04,760 All the. 613 00:24:04,860 --> 00:24:07,360 All this competition is based on the ImageNet. 614 00:24:07,640 --> 00:24:08,160 Dataset. 615 00:24:08,380 --> 00:24:10,900 So, ImageNet has like thousand labels. 616 00:24:11,420 --> 00:24:13,340 But when we do the K-mean clustering. 617 00:24:13,640 --> 00:24:14,380 It's impossible. 618 00:24:14,880 --> 00:24:16,760 For us to do like thousand. 619 00:24:16,960 --> 00:24:17,800 Thousand clusters. 620 00:24:19,040 --> 00:24:19,740 So, basically. 621 00:24:25,280 --> 00:24:26,620 So, how can you map. 622 00:24:26,840 --> 00:24:27,560 A thousand. 623 00:24:28,960 --> 00:24:30,000 Different labels. 624 00:24:30,140 --> 00:24:31,420 Into ten different classes. 625 00:24:31,760 --> 00:24:34,420 So, that's how we do it. 626 00:24:34,440 --> 00:24:36,040 Basically, after we train our. 627 00:24:36,160 --> 00:24:37,320 K-mean cluster. 628 00:24:38,100 --> 00:24:40,260 We use another test dataset. 629 00:24:41,320 --> 00:24:43,040 So, that test set is gonna go inside. 630 00:24:43,300 --> 00:24:45,200 Into the K-mean clustering. 631 00:24:45,600 --> 00:24:47,140 We know those two labels. 632 00:24:47,260 --> 00:24:49,000 Those ImageNet labels of those test cluster. 633 00:24:49,280 --> 00:24:50,540 Then after we classify. 634 00:24:50,860 --> 00:24:53,140 Those images with K-mean cluster. 635 00:24:53,360 --> 00:24:54,180 We also know the. 636 00:24:55,280 --> 00:24:55,480 Classes. 637 00:24:55,480 --> 00:24:57,400 So, that's gonna generate a map. 638 00:24:58,060 --> 00:24:59,320 Basically, it's a table. 639 00:24:59,760 --> 00:25:01,100 So, we know which. 640 00:25:01,140 --> 00:25:03,160 Which class gonna correspond to which. 641 00:25:03,340 --> 00:25:04,200 ImageNet labels. 642 00:25:04,760 --> 00:25:05,920 So, after that. 643 00:25:06,660 --> 00:25:08,280 Mapping label is ready. 644 00:25:09,040 --> 00:25:11,580 We start to finalize our logic. 645 00:25:11,840 --> 00:25:12,320 So, basically. 646 00:25:12,400 --> 00:25:13,220 It's very simple. 647 00:25:13,500 --> 00:25:14,960 So, when. 648 00:25:15,460 --> 00:25:16,580 Adversarial image coming. 649 00:25:18,020 --> 00:25:20,220 First it's gonna go through the first module. 650 00:25:20,380 --> 00:25:21,200 I just discussed. 651 00:25:25,280 --> 00:25:26,880 Then that ImageNet label gonna. 652 00:25:27,040 --> 00:25:28,180 Convert to a. 653 00:25:28,540 --> 00:25:31,100 K-mean label by using that. 654 00:25:31,920 --> 00:25:33,480 Mapping table we just generated. 655 00:25:33,860 --> 00:25:34,360 So, which. 656 00:25:34,460 --> 00:25:35,920 It's basically just a. 657 00:25:36,180 --> 00:25:37,540 Ten elements list. 658 00:25:37,780 --> 00:25:40,640 Because we only have ten. 659 00:25:40,740 --> 00:25:41,500 K-mean classes. 660 00:25:41,880 --> 00:25:44,960 So, those ten elements actually. 661 00:25:45,080 --> 00:25:46,820 Is ordered by probability. 662 00:25:47,380 --> 00:25:47,780 So. 663 00:25:49,440 --> 00:25:50,480 For example. 664 00:25:50,520 --> 00:25:52,100 The first list which means. 665 00:25:52,400 --> 00:25:53,460 We think. 666 00:25:56,320 --> 00:25:56,880 Is. 667 00:25:57,080 --> 00:25:58,980 Most likely in class nine. 668 00:25:59,260 --> 00:26:00,920 But least likely in class four. 669 00:26:02,420 --> 00:26:02,980 Then. 670 00:26:03,220 --> 00:26:04,280 At same time. 671 00:26:04,400 --> 00:26:06,000 This attack image also gonna. 672 00:26:06,180 --> 00:26:07,560 Directly fit into the. 673 00:26:08,300 --> 00:26:09,260 K-mean cluster. 674 00:26:09,640 --> 00:26:11,760 So, K-mean cluster gonna generate another list. 675 00:26:12,380 --> 00:26:14,360 So, it's also a ten elements list. 676 00:26:14,860 --> 00:26:16,020 But for this list. 677 00:26:16,180 --> 00:26:17,060 The K-mean thinks. 678 00:26:19,180 --> 00:26:20,880 Most likely this image. 679 00:26:21,100 --> 00:26:23,200 Is in class two. 680 00:26:23,480 --> 00:26:25,260 But least likely in class nine. 681 00:26:25,280 --> 00:26:26,700 So, this two list actually. 682 00:26:26,840 --> 00:26:28,620 They contradict to each other. 683 00:26:28,680 --> 00:26:29,520 They don't agree. 684 00:26:30,160 --> 00:26:32,900 So, that's when we think. 685 00:26:32,920 --> 00:26:34,300 This filter think. 686 00:26:34,680 --> 00:26:37,260 This attack actually succeed. 687 00:26:37,940 --> 00:26:39,160 Because they are contradict. 688 00:26:39,500 --> 00:26:40,080 So, then. 689 00:26:40,100 --> 00:26:42,260 They gonna just output a zero. 690 00:26:42,360 --> 00:26:43,140 Or random number. 691 00:26:43,940 --> 00:26:46,320 Only when those two list match. 692 00:26:47,020 --> 00:26:47,660 Or some. 693 00:26:47,780 --> 00:26:50,320 Or pass some checking logic. 694 00:26:50,640 --> 00:26:51,380 We set. 695 00:26:51,900 --> 00:26:53,740 It's gonna let the. 696 00:26:55,280 --> 00:26:55,620 K-mean filter come through. 697 00:26:56,300 --> 00:26:57,300 So, that's the idea. 698 00:26:57,380 --> 00:26:58,080 Of the K-mean filter. 699 00:27:00,480 --> 00:27:02,060 So, that's all about. 700 00:27:02,140 --> 00:27:03,660 The design of our final. 701 00:27:04,340 --> 00:27:05,360 Summation for the defense. 702 00:27:05,600 --> 00:27:07,700 So, this is just a quick. 703 00:27:08,280 --> 00:27:10,640 Just a same polar plot. 704 00:27:10,860 --> 00:27:12,080 Showing the hit target rate. 705 00:27:12,380 --> 00:27:13,860 Of our defense against. 706 00:27:14,660 --> 00:27:15,820 Some strong attacks. 707 00:27:16,160 --> 00:27:16,980 So, you can see. 708 00:27:17,060 --> 00:27:18,460 For all six attacks. 709 00:27:19,220 --> 00:27:22,020 Hit target rate is close to zero. 710 00:27:22,400 --> 00:27:23,340 So, we believe. 711 00:27:25,280 --> 00:27:26,380 It is effective. 712 00:27:26,500 --> 00:27:28,880 And also has a good transferability. 713 00:27:30,080 --> 00:27:30,600 But. 714 00:27:30,740 --> 00:27:31,580 It's turn out. 715 00:27:32,020 --> 00:27:32,740 It's not. 716 00:27:34,000 --> 00:27:36,220 We still lost some points. 717 00:27:37,040 --> 00:27:37,940 So, I think. 718 00:27:38,940 --> 00:27:40,520 I think for the K-mean filter. 719 00:27:40,600 --> 00:27:42,260 K-mean module. 720 00:27:42,580 --> 00:27:44,740 There's still a lot to improve space. 721 00:27:45,780 --> 00:27:46,860 So, that might be. 722 00:27:47,080 --> 00:27:49,300 A direction we try to improve. 723 00:27:51,420 --> 00:27:52,700 So, in summary. 724 00:27:53,380 --> 00:27:54,340 I talk about. 725 00:27:55,280 --> 00:27:56,000 A set of attacks. 726 00:27:56,200 --> 00:27:58,240 Aiming different defense. 727 00:27:59,200 --> 00:28:00,040 And also. 728 00:28:00,080 --> 00:28:01,540 I talk about the defense. 729 00:28:01,740 --> 00:28:03,320 Compressed of image processing. 730 00:28:03,700 --> 00:28:04,900 Classified difference filter. 731 00:28:05,160 --> 00:28:05,860 And K-mean filter. 732 00:28:06,680 --> 00:28:07,540 With that. 733 00:28:07,780 --> 00:28:09,340 I'm going to finish my talk. 734 00:28:09,920 --> 00:28:10,820 Any questions? 735 00:28:12,600 --> 00:28:13,160 Yes. 736 00:28:13,300 --> 00:28:13,780 I want to ask you. 737 00:28:14,020 --> 00:28:15,020 Is the noise. 738 00:28:15,300 --> 00:28:16,820 The primary type of attack. 739 00:28:17,100 --> 00:28:19,700 Just random noise? 740 00:28:25,280 --> 00:28:26,160 Changes in the image? 741 00:28:27,100 --> 00:28:27,840 You mean. 742 00:28:27,880 --> 00:28:29,340 Is that random or not? 743 00:28:29,660 --> 00:28:32,860 Is the noise the main attack? 744 00:28:33,300 --> 00:28:35,040 That you're going into the image. 745 00:28:35,260 --> 00:28:36,540 Just random. 746 00:28:37,340 --> 00:28:37,900 Yes. 747 00:28:39,400 --> 00:28:39,960 Yes. 748 00:28:40,240 --> 00:28:41,500 So, we are. 749 00:28:41,640 --> 00:28:42,200 Yes. 750 00:28:42,380 --> 00:28:45,500 That's the main way to achieve the attack. 751 00:28:45,940 --> 00:28:48,140 Are there any types of targeted attacks. 752 00:28:48,460 --> 00:28:49,340 To try and manipulate. 753 00:28:49,680 --> 00:28:51,420 Actual portions of the image. 754 00:28:52,060 --> 00:28:53,300 Like the distort. 755 00:28:56,320 --> 00:28:57,680 Or elongate it. 756 00:28:57,820 --> 00:28:58,240 Or shrink it. 757 00:28:58,520 --> 00:29:00,280 You mean the attack method? 758 00:29:00,540 --> 00:29:00,880 Yes. 759 00:29:00,980 --> 00:29:01,400 Actually. 760 00:29:01,500 --> 00:29:03,760 So the attack actually is. 761 00:29:05,460 --> 00:29:07,120 Mathematically is actually. 762 00:29:07,160 --> 00:29:09,340 Just solving optimization problem. 763 00:29:09,740 --> 00:29:11,000 So it totally depends on. 764 00:29:11,100 --> 00:29:13,000 How do you define your problem. 765 00:29:13,320 --> 00:29:14,460 So there are some attacks. 766 00:29:14,720 --> 00:29:17,400 They can only adjust one pixel. 767 00:29:18,100 --> 00:29:21,160 It still achieves their purpose. 768 00:29:21,360 --> 00:29:22,560 To change the classification. 769 00:29:22,560 --> 00:29:24,000 And also they have. 770 00:29:24,100 --> 00:29:25,140 Some research proposal. 771 00:29:25,920 --> 00:29:26,880 Some patch. 772 00:29:27,740 --> 00:29:29,480 So basically it's just a pattern. 773 00:29:29,600 --> 00:29:29,920 A patch. 774 00:29:30,100 --> 00:29:31,900 When you put that patch onto anything. 775 00:29:32,240 --> 00:29:34,940 The image classifier gonna misclassify that image. 776 00:29:35,300 --> 00:29:36,320 So basically you can. 777 00:29:36,500 --> 00:29:36,680 Yes. 778 00:29:36,780 --> 00:29:38,920 By define your problem. 779 00:29:39,080 --> 00:29:42,100 You can control where you put those noise. 780 00:29:42,340 --> 00:29:43,300 Even though there are noise. 781 00:29:43,480 --> 00:29:44,400 But you can still control. 782 00:29:44,660 --> 00:29:46,400 Where you apply to it. 783 00:29:47,040 --> 00:29:47,300 Yes. 784 00:29:52,560 --> 00:29:53,940 From an image perspective. 785 00:29:54,020 --> 00:29:56,780 How the attacks and defenses work. 786 00:29:57,040 --> 00:29:57,400 Yes. 787 00:29:57,740 --> 00:29:59,660 How can you translate. 788 00:29:59,700 --> 00:30:01,440 Those same concepts to. 789 00:30:02,360 --> 00:30:03,800 Let's say some malware. 790 00:30:04,220 --> 00:30:06,420 That you're trying to process through. 791 00:30:06,860 --> 00:30:08,220 AI or ML. 792 00:30:09,020 --> 00:30:10,340 To classify. 793 00:30:10,580 --> 00:30:12,080 Whether it's benign or. 794 00:30:12,720 --> 00:30:13,400 Malicious. 795 00:30:13,480 --> 00:30:15,520 How would we say. 796 00:30:15,640 --> 00:30:17,920 Okay this is how we modify. 797 00:30:18,000 --> 00:30:19,640 The piece of malware with noise. 798 00:30:20,300 --> 00:30:21,100 Or padding. 799 00:30:22,560 --> 00:30:23,980 Process it through the AI. 800 00:30:24,140 --> 00:30:26,520 Is it literally the same way. 801 00:30:26,520 --> 00:30:28,020 That you would modify. 802 00:30:28,020 --> 00:30:29,580 The image to be able to. 803 00:30:31,000 --> 00:30:32,440 Tamper with the algorithm. 804 00:30:32,840 --> 00:30:34,380 Okay so your question is just. 805 00:30:34,480 --> 00:30:36,100 Ask if the same method. 806 00:30:36,280 --> 00:30:37,740 Can be applied to a different. 807 00:30:38,060 --> 00:30:39,700 Other AI applications. 808 00:30:40,000 --> 00:30:41,720 Is it literally the same way. 809 00:30:41,980 --> 00:30:44,000 Or is it completely different. 810 00:30:44,180 --> 00:30:44,400 At all. 811 00:30:46,200 --> 00:30:47,140 I think. 812 00:30:48,720 --> 00:30:49,720 Fundamentally they are same. 813 00:30:50,200 --> 00:30:51,700 So it's still another. 814 00:30:52,880 --> 00:30:53,400 Optimizing. 815 00:30:53,820 --> 00:30:54,800 Optimization problem. 816 00:30:55,120 --> 00:30:57,120 You just try to solve that optimization problem. 817 00:30:57,440 --> 00:30:58,960 But in practical. 818 00:30:59,280 --> 00:31:00,900 When you're doing attack. 819 00:31:01,140 --> 00:31:02,820 Against some other stuff. 820 00:31:03,100 --> 00:31:04,680 Even though it's not that far away. 821 00:31:04,820 --> 00:31:06,400 Like I'm doing the same. 822 00:31:07,000 --> 00:31:09,020 Attack against an image classifier. 823 00:31:09,120 --> 00:31:10,420 But in real. 824 00:31:10,580 --> 00:31:11,380 In the real world. 825 00:31:11,860 --> 00:31:12,960 There are more. 826 00:31:13,300 --> 00:31:14,620 There are a lot of factor. 827 00:31:14,800 --> 00:31:17,000 Has to be taken into account. 828 00:31:17,500 --> 00:31:18,520 For example. 829 00:31:22,560 --> 00:31:23,000 What I'm talking about. 830 00:31:23,040 --> 00:31:24,840 Is totally in the digital domain. 831 00:31:25,100 --> 00:31:26,080 So basically everything. 832 00:31:26,220 --> 00:31:27,060 Achieving in the computer. 833 00:31:27,340 --> 00:31:28,840 But if you want to achieve. 834 00:31:28,960 --> 00:31:29,620 A physical domain. 835 00:31:29,900 --> 00:31:32,060 Like you just put something on the wall. 836 00:31:32,220 --> 00:31:33,040 On the like. 837 00:31:33,240 --> 00:31:34,180 On the washing machine. 838 00:31:34,420 --> 00:31:35,200 The washing machine gonna. 839 00:31:35,280 --> 00:31:37,680 As a dryer or something. 840 00:31:38,100 --> 00:31:38,860 For that. 841 00:31:38,980 --> 00:31:40,140 You have to take into account. 842 00:31:40,360 --> 00:31:41,280 Like the light. 843 00:31:42,300 --> 00:31:43,600 The wheel angle. 844 00:31:53,080 --> 00:31:53,600 Yeah. 845 00:31:54,900 --> 00:31:55,420 Yes. 846 00:32:00,800 --> 00:32:01,320 Yeah. 847 00:32:07,320 --> 00:32:09,200 Actually that's a very good point. 848 00:32:09,360 --> 00:32:10,480 So yeah. 849 00:32:10,540 --> 00:32:11,400 That's why we. 850 00:32:11,620 --> 00:32:13,280 So there are a lot of different ways. 851 00:32:13,500 --> 00:32:15,980 To apply the same idea. 852 00:32:16,240 --> 00:32:16,960 So basically. 853 00:32:18,480 --> 00:32:20,620 Basically what we are trying to do. 854 00:32:22,620 --> 00:32:23,140 Is to keep the. 855 00:32:23,140 --> 00:32:23,840 The bad noise. 856 00:32:24,200 --> 00:32:25,580 Which is adversarial noise. 857 00:32:25,840 --> 00:32:27,240 But still keep the valid information. 858 00:32:27,400 --> 00:32:28,380 For the classifier. 859 00:32:28,620 --> 00:32:30,840 Because you cannot just totally get rid of everything. 860 00:32:31,080 --> 00:32:33,560 So that's also gonna mess up your classifier. 861 00:32:34,160 --> 00:32:35,580 Actually even for this. 862 00:32:35,620 --> 00:32:37,320 I didn't show here. 863 00:32:37,480 --> 00:32:38,660 But if you. 864 00:32:38,860 --> 00:32:41,320 If the parameter didn't set correctly. 865 00:32:41,840 --> 00:32:43,980 The accuracy of the classifier. 866 00:32:44,060 --> 00:32:45,620 Gonna strongly degrade. 867 00:32:46,140 --> 00:32:46,480 Yeah. 868 00:32:46,480 --> 00:32:47,460 So basically. 869 00:32:47,720 --> 00:32:49,060 Actually that's a good point. 870 00:32:49,300 --> 00:32:52,820 We can try to do something in the frequency domain. 871 00:32:53,000 --> 00:32:54,200 Actually that's one of our. 872 00:32:54,280 --> 00:32:55,640 Team members. 873 00:32:56,260 --> 00:32:56,440 Yes. 874 00:32:56,720 --> 00:32:59,000 Actually that's one of our team members. 875 00:32:59,200 --> 00:33:00,980 He's trying to work on that direction. 876 00:33:01,200 --> 00:33:01,940 Basically it's. 877 00:33:04,700 --> 00:33:05,940 It's not doing the. 878 00:33:06,400 --> 00:33:07,260 Image filtering. 879 00:33:07,700 --> 00:33:10,000 We're trying to look at the frequency domain. 880 00:33:10,080 --> 00:33:12,440 To tell if it's a real image or not. 881 00:33:12,940 --> 00:33:13,800 So that's. 882 00:33:13,800 --> 00:33:16,040 That's our idea. 883 00:33:16,360 --> 00:33:16,920 Yeah. 884 00:33:19,820 --> 00:33:20,420 Yes. 885 00:33:21,480 --> 00:33:22,580 That's another way. 886 00:33:22,860 --> 00:33:23,200 Yeah. 887 00:33:23,300 --> 00:33:24,060 And also because. 888 00:33:25,860 --> 00:33:27,860 Even though you carefully set up. 889 00:33:27,880 --> 00:33:29,320 Your filtering algorithm. 890 00:33:29,680 --> 00:33:32,240 It's still gonna affect the classifier accuracy. 891 00:33:32,500 --> 00:33:33,300 So basically. 892 00:33:33,420 --> 00:33:34,600 I read some paper. 893 00:33:34,760 --> 00:33:36,360 Basically the researcher is doing is. 894 00:33:36,780 --> 00:33:39,620 They use another set of neural network. 895 00:33:39,920 --> 00:33:41,020 Just try to calculate. 896 00:33:41,320 --> 00:33:43,360 Something called class activation. 897 00:33:43,800 --> 00:33:44,320 Region. 898 00:33:44,640 --> 00:33:45,340 So basically. 899 00:33:45,540 --> 00:33:47,560 When the classifier look at the image. 900 00:33:47,780 --> 00:33:49,120 There is an interesting region. 901 00:33:49,320 --> 00:33:50,640 Or those not interesting region. 902 00:33:50,900 --> 00:33:52,600 So basically that neural network. 903 00:33:52,660 --> 00:33:53,700 Just try to figure out. 904 00:33:53,720 --> 00:33:55,740 Which region is more important. 905 00:33:56,100 --> 00:33:57,780 Gonna affect the final classification. 906 00:33:58,120 --> 00:33:59,340 For that classifier. 907 00:33:59,580 --> 00:34:01,440 Then when we know that region. 908 00:34:01,640 --> 00:34:04,400 When we apply the image filter for the attack. 909 00:34:04,680 --> 00:34:05,940 We don't touch that region. 910 00:34:06,440 --> 00:34:09,340 We just filter everything else out. 911 00:34:09,620 --> 00:34:09,880 Yeah. 912 00:34:14,340 --> 00:34:15,680 But that's gonna be slow. 913 00:34:16,080 --> 00:34:16,560 Yeah. 914 00:34:17,160 --> 00:34:17,640 Yeah. 915 00:34:20,940 --> 00:34:21,420 Okay. 916 00:34:22,540 --> 00:34:23,600 I have one more. 917 00:34:23,840 --> 00:34:24,320 Okay. 918 00:34:27,060 --> 00:34:29,080 So you talked about. 919 00:34:29,860 --> 00:34:31,000 Processing the different images. 920 00:34:31,120 --> 00:34:32,100 Through different filters. 921 00:34:32,200 --> 00:34:33,020 To increase the accuracy. 922 00:34:33,320 --> 00:34:33,540 Right? 923 00:34:33,800 --> 00:34:34,280 Yes. 924 00:34:34,280 --> 00:34:35,580 One of the things that you mentioned. 925 00:34:35,660 --> 00:34:36,140 Was. 926 00:34:43,800 --> 00:34:44,880 You know your scan. 927 00:34:45,060 --> 00:34:45,320 Right? 928 00:34:45,320 --> 00:34:45,500 Yeah. 929 00:34:45,560 --> 00:34:47,760 So does the accuracy. 930 00:34:49,240 --> 00:34:50,580 Improve the more. 931 00:34:52,440 --> 00:34:54,300 Images you feed into. 932 00:34:55,180 --> 00:34:56,360 Into your data set. 933 00:34:56,560 --> 00:34:58,720 Or is there a certain point that. 934 00:34:58,800 --> 00:34:59,880 It doesn't matter how many. 935 00:35:00,960 --> 00:35:01,920 Images you throw. 936 00:35:02,080 --> 00:35:03,700 At your data set. 937 00:35:03,920 --> 00:35:05,660 The accuracy just peaks. 938 00:35:07,840 --> 00:35:09,320 So I think that depends. 939 00:35:09,680 --> 00:35:10,600 So it depends. 940 00:35:10,600 --> 00:35:12,020 What kind of. 941 00:35:13,500 --> 00:35:14,580 Algorithm you are using. 942 00:35:14,760 --> 00:35:15,440 So for example. 943 00:35:15,580 --> 00:35:16,040 If you are. 944 00:35:19,320 --> 00:35:20,120 So when. 945 00:35:20,320 --> 00:35:22,160 When you train that. 946 00:35:22,640 --> 00:35:23,200 Classifier. 947 00:35:23,840 --> 00:35:25,700 If you take into account both. 948 00:35:26,060 --> 00:35:27,820 Like pure original image. 949 00:35:28,060 --> 00:35:29,960 Or some image after filtering. 950 00:35:30,260 --> 00:35:31,360 So when you train that model. 951 00:35:31,640 --> 00:35:33,340 You already take into account that factor. 952 00:35:34,400 --> 00:35:35,520 So then. 953 00:35:35,620 --> 00:35:37,340 When you do the image filter later. 954 00:35:37,340 --> 00:35:38,860 It won't affect that. 955 00:35:39,420 --> 00:35:39,900 Classifier. 956 00:35:41,360 --> 00:35:42,520 But if you. 957 00:35:43,000 --> 00:35:44,220 If you try to. 958 00:35:44,300 --> 00:35:45,540 When you feed more image. 959 00:35:45,700 --> 00:35:45,960 I don't know. 960 00:35:46,220 --> 00:35:48,040 I'm not sure I fully understand it. 961 00:35:48,140 --> 00:35:48,820 But you mean. 962 00:35:48,920 --> 00:35:51,100 If you feed a lot of image. 963 00:35:51,300 --> 00:35:52,620 I think you are talking about training. 964 00:35:52,760 --> 00:35:53,000 Right? 965 00:35:53,120 --> 00:35:53,580 Yeah. 966 00:35:53,960 --> 00:35:55,220 So for training. 967 00:35:55,620 --> 00:35:56,520 Yeah we can. 968 00:35:56,640 --> 00:35:57,460 So that's actually. 969 00:36:07,540 --> 00:36:08,620 We can also do. 970 00:36:08,620 --> 00:36:10,820 But we can also do a mist of original image. 971 00:36:10,920 --> 00:36:12,660 And some image after image filter. 972 00:36:12,940 --> 00:36:14,440 So by doing that. 973 00:36:14,580 --> 00:36:16,340 We train that. 974 00:36:16,580 --> 00:36:17,140 Classifier. 975 00:36:17,300 --> 00:36:18,640 That classifier is going to learn. 976 00:36:18,740 --> 00:36:18,960 Okay. 977 00:36:19,160 --> 00:36:20,820 So some image is original. 978 00:36:21,060 --> 00:36:23,320 But some image is after some filtering. 979 00:36:23,720 --> 00:36:26,180 I can still identify they are same. 980 00:36:26,640 --> 00:36:28,020 So that's kind of like. 981 00:36:28,160 --> 00:36:31,380 How you build your training data set. 982 00:36:31,620 --> 00:36:33,340 But let's say you had unlimited time. 983 00:36:34,000 --> 00:36:35,460 And unlimited resources. 984 00:36:37,340 --> 00:36:39,420 Does the accuracy continue to improve. 985 00:36:39,560 --> 00:36:40,980 The more you feed. 986 00:36:41,220 --> 00:36:42,720 Or is there a certain point. 987 00:36:42,820 --> 00:36:43,720 Where it just peaks. 988 00:36:43,840 --> 00:36:47,160 No matter how much more time you spend. 989 00:36:48,280 --> 00:36:49,320 I think. 990 00:36:49,400 --> 00:36:51,240 That's limited by the. 991 00:36:51,700 --> 00:36:52,940 The neural network. 992 00:36:53,480 --> 00:36:55,340 Is not limited by the image filtering. 993 00:36:55,800 --> 00:36:56,400 So basically. 994 00:36:56,460 --> 00:36:57,720 I think it's going to reach a peak. 995 00:36:58,160 --> 00:37:00,380 I don't think you can just keep going. 996 00:37:00,740 --> 00:37:01,260 Yeah. 997 00:37:01,260 --> 00:37:02,000 I don't think. 998 00:37:02,440 --> 00:37:02,960 Yeah. 999 00:37:09,840 --> 00:37:10,160 Okay. 1000 00:37:11,140 --> 00:37:11,460 Okay. 1001 00:37:11,540 --> 00:37:11,800 Yeah. 1002 00:37:11,880 --> 00:37:12,100 Thanks.