b0aa63acadaa721d8b69f2b060048aad874522e5,tests/attacks/evasion/test_fast_gradient.py,,test_classifier_defended_images,#Any#Any#,108
Before Change
return
for classifier in defended_image_classifier_list:
if FastGradientMethod.is_valid_classifier_type(classifier) is False:
continue
attack = FastGradientMethod(classifier, eps=1, batch_size=128)
x_train_adv = attack.generate(x_train_mnist)
utils_test.check_adverse_example_x(x_train_adv, x_train_mnist)
After Change
def test_classifier_defended_images(fix_get_mnist_subset, new_image_classifier_list):
(x_train_mnist, y_train_mnist, x_test_mnist, y_test_mnist) = fix_get_mnist_subset
classifier_list = new_image_classifier_list(FastGradientMethod, defended=True)
// TODO this if statement must be removed once we have a classifier for both image and tabular data
if classifier_list is None:
logging.warning("Couldn"t perform this test because no classifier is defined")
return
In pattern: SUPERPATTERN
Frequency: 8
Non-data size: 7
Instances Project Name: IBM/adversarial-robustness-toolbox
Commit Name: b0aa63acadaa721d8b69f2b060048aad874522e5
Time: 2020-02-06
Author: killian.levacher@gmail.com
File Name: tests/attacks/evasion/test_fast_gradient.py
Class Name:
Method Name: test_classifier_defended_images
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: b0aa63acadaa721d8b69f2b060048aad874522e5
Time: 2020-02-06
Author: killian.levacher@gmail.com
File Name: tests/attacks/evasion/test_fast_gradient.py
Class Name:
Method Name: test_targeted_images
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: b0aa63acadaa721d8b69f2b060048aad874522e5
Time: 2020-02-06
Author: killian.levacher@gmail.com
File Name: tests/attacks/evasion/test_fast_gradient.py
Class Name:
Method Name: test_minimal_perturbations_images
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: b0aa63acadaa721d8b69f2b060048aad874522e5
Time: 2020-02-06
Author: killian.levacher@gmail.com
File Name: tests/attacks/evasion/test_fast_gradient.py
Class Name:
Method Name: test_no_norm_images
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: b0aa63acadaa721d8b69f2b060048aad874522e5
Time: 2020-02-06
Author: killian.levacher@gmail.com
File Name: tests/attacks/evasion/test_fast_gradient.py
Class Name:
Method Name: test_l1_norm_images
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: b0aa63acadaa721d8b69f2b060048aad874522e5
Time: 2020-02-06
Author: killian.levacher@gmail.com
File Name: tests/attacks/evasion/test_fast_gradient.py
Class Name:
Method Name: test_random_initialisation_images
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: cb6e71d2b8e51778a0284de1c85a806e731dace5
Time: 2020-02-06
Author: killian.levacher@gmail.com
File Name: tests/attacks/evasion/test_boundary.py
Class Name:
Method Name: test_images
Project Name: IBM/adversarial-robustness-toolbox
Commit Name: b0aa63acadaa721d8b69f2b060048aad874522e5
Time: 2020-02-06
Author: killian.levacher@gmail.com
File Name: tests/attacks/evasion/test_fast_gradient.py
Class Name:
Method Name: test_l2_norm_images