Auto Attack using KerasClassifier #1691
Replies: 2 comments 3 replies
-
Hi @khedher1984 Yes, it is possible to use |
Beta Was this translation helpful? Give feedback.
-
Below the architecture of my model: Model: "sequential_1" Layer (type) Output Shape Param #conv2d (Conv2D) (None, 56, 56, 96) 34944 batch_normalization (BatchNo (None, 56, 56, 96) 384 activation (Activation) (None, 56, 56, 96) 0 max_pooling2d (MaxPooling2D) (None, 28, 28, 96) 0 conv2d_1 (Conv2D) (None, 28, 28, 256) 614656 batch_normalization_1 (Batch (None, 28, 28, 256) 1024 activation_1 (Activation) (None, 28, 28, 256) 0 max_pooling2d_1 (MaxPooling2 (None, 14, 14, 256) 0 zero_padding2d (ZeroPadding2 (None, 16, 16, 256) 0 conv2d_2 (Conv2D) (None, 16, 16, 384) 885120 batch_normalization_2 (Batch (None, 16, 16, 384) 1536 activation_2 (Activation) (None, 16, 16, 384) 0 max_pooling2d_2 (MaxPooling2 (None, 8, 8, 384) 0 zero_padding2d_1 (ZeroPaddin (None, 10, 10, 384) 0 conv2d_3 (Conv2D) (None, 10, 10, 384) 1327488 batch_normalization_3 (Batch (None, 10, 10, 384) 1536 activation_3 (Activation) (None, 10, 10, 384) 0 zero_padding2d_2 (ZeroPaddin (None, 12, 12, 384) 0 conv2d_4 (Conv2D) (None, 12, 12, 256) 884992 batch_normalization_4 (Batch (None, 12, 12, 256) 1024 activation_4 (Activation) (None, 12, 12, 256) 0 max_pooling2d_3 (MaxPooling2 (None, 6, 6, 256) 0 flatten (Flatten) (None, 9216) 0 dense (Dense) (None, 4096) 37752832 batch_normalization_5 (Batch (None, 4096) 16384 activation_5 (Activation) (None, 4096) 0 dropout (Dropout) (None, 4096) 0 dense_1 (Dense) (None, 2048) 8390656 batch_normalization_6 (Batch (None, 2048) 8192 activation_6 (Activation) (None, 2048) 0 dropout_1 (Dropout) (None, 2048) 0 dense_2 (Dense) (None, 1024) 2098176 batch_normalization_7 (Batch (None, 1024) 4096 activation_7 (Activation) (None, 1024) 0 dropout_2 (Dropout) (None, 1024) 0 dense_5 (Dense) (None, 2) 2050Total params: 52,025,090 ################ Below my script: ########################## attack_auto_PGD = AutoProjectedGradientDescent(estimator=classifier) Error:AttributeError Traceback (most recent call last) ~\AppData\Roaming\Python\Python36\site-packages\art\attacks\evasion\auto_projected_gradient_descent.py in init(self, estimator, norm, eps, eps_step, max_iter, targeted, nb_random_init, batch_size, loss_type, verbose) ~\AppData\Roaming\Python\Python36\site-packages\art\estimators\classification\classifier.py in replacement_function(self, *args, **kwargs) ~\AppData\Roaming\Python\Python36\site-packages\art\estimators\classification\tensorflow.py in predict(self, x, batch_size, training_mode, **kwargs) ~\AppData\Roaming\Python\Python36\site-packages\art\estimators\tensorflow.py in _apply_preprocessing(self, x, y, fit) AttributeError: 'Tensor' object has no attribute 'numpy' |
Beta Was this translation helpful? Give feedback.
-
Hello,
Is it possible to use AutoAttack with Kerass classifier?
Thank you,
Beta Was this translation helpful? Give feedback.
All reactions