Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Semantic Attacks PyTorch #2200

Open
wants to merge 9 commits into
base: dev_1.16.0
Choose a base branch
from

Conversation

sarathknv
Copy link

@sarathknv sarathknv commented Jun 22, 2023

Description

Implementation of single semantic attacks on PyTorch image classifiers. The attacks are generated by perturbing hue, saturation, contrast, brightness, and rotation.

Paper: https://openaccess.thecvf.com/content/CVPR2023/papers/Hsiung_Towards_Compositional_Adversarial_Robustness_Generalizing_Adversarial_Training_to_Composite_Semantic_CVPR_2023_paper.pdf

Fixes #2126

Type of change

Please check all relevant options.

  • Improvement (non-breaking)
  • Bug fix (non-breaking)
  • New feature (non-breaking)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Testing

Please describe the tests that you ran to verify your changes. Consider listing any relevant details of your test configuration.

  • Unit tests
  • Notebook example

Test Configuration:

  • OS
  • Python version
  • ART version or commit number
  • TensorFlow / Keras / PyTorch / MXNet version

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@beat-buesser beat-buesser self-requested a review June 26, 2023 10:09
@beat-buesser beat-buesser self-assigned this Jun 26, 2023
@codecov-commenter
Copy link

codecov-commenter commented Jun 27, 2023

Codecov Report

Merging #2200 (643d6fb) into dev_1.15.0 (4bfed67) will decrease coverage by 16.42%.
The diff coverage is 18.48%.

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

Impacted file tree graph

@@               Coverage Diff               @@
##           dev_1.15.0    #2200       +/-   ##
===============================================
- Coverage       85.68%   69.26%   -16.42%     
===============================================
  Files             306      313        +7     
  Lines           27022    28081     +1059     
  Branches         4962     5168      +206     
===============================================
- Hits            23153    19451     -3702     
- Misses           2599     7481     +4882     
+ Partials         1270     1149      -121     
Impacted Files Coverage Δ
...on/semantic_attacks/brightness_gradient_pytorch.py 17.83% <17.83%> (ø)
...sion/semantic_attacks/contrast_gradient_pytorch.py 17.83% <17.83%> (ø)
...s/evasion/semantic_attacks/hue_gradient_pytorch.py 17.83% <17.83%> (ø)
...on/semantic_attacks/saturation_gradient_pytorch.py 17.83% <17.83%> (ø)
art/attacks/evasion/__init__.py 98.24% <100.00%> (+0.03%) ⬆️
art/attacks/evasion/semantic_attacks/__init__.py 100.00% <100.00%> (ø)

... and 80 files with indirect coverage changes

@beat-buesser beat-buesser added the enhancement New feature or request label Jun 30, 2023
@beat-buesser beat-buesser added this to the ART 1.16.0 milestone Jun 30, 2023
Signed-off-by: Sarath Chandra Kothapalli <[email protected]>
Signed-off-by: Sarath Chandra Kothapalli <[email protected]>
Signed-off-by: Sarath Chandra Kothapalli <[email protected]>
Signed-off-by: Sarath Chandra Kothapalli <[email protected]>
Signed-off-by: Sarath Chandra Kothapalli <[email protected]>
Signed-off-by: Sarath Chandra Kothapalli <[email protected]>
Signed-off-by: Sarath Chandra Kothapalli <[email protected]>
@sarathknv sarathknv changed the base branch from dev_1.15.0 to dev_1.16.0 July 9, 2023 20:55
@sarathknv sarathknv marked this pull request as draft July 13, 2023 04:12
Signed-off-by: Sarath Chandra Kothapalli <[email protected]>
@sarathknv sarathknv marked this pull request as ready for review July 19, 2023 21:05
@beat-buesser beat-buesser added this to Pull request review in ART 1.16.0 Sep 12, 2023
@beat-buesser beat-buesser modified the milestones: ART 1.16.0, ART 1.17.0 Sep 22, 2023
@beat-buesser beat-buesser removed this from Pull request review in ART 1.16.0 Sep 22, 2023
@beat-buesser beat-buesser modified the milestones: ART 1.17.0, ART 1.18.0 Dec 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
ART 1.18.0
Awaiting triage
Development

Successfully merging this pull request may close these issues.

None yet

3 participants