Giter Site home page Giter Site logo

icgy96 / apr Goto Github PK

View Code? Open in Web Editor NEW
69.0 2.0 7.0 4.47 MB

[ICCV 2021] Amplitude-Phase Recombination: Rethinking Robustness of Convolutional Neural Networks in Frequency Domain

Home Page: https://arxiv.org/abs/2108.08487

License: MIT License

Python 100.00%
robustness frequency-analysis domain-generalization out-of-distribution-detection imagenet-c

apr's People

Contributors

icgy96 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

apr's Issues

randomness in apr-p and apr-s

Hi

I see that in both APR-P and APR-S there is some randomness in the augmentations. For APR-P, the data is mixed only 40% of the time

if p > prob:

and in APR-S, the data is augmented 50% of the time

if p > 0.5:

with additional randomness in the choice of image whose phase is returned

if p > 0.5:

Were these steps used to obtain the results in your paper, as I do not find this randomness mentioned in the paper?

Also, could you briefly describe how APR-SP was implemented - did you first apply APR-S and then apply APR-P?

Thank you,
KC

Question about the section 5.3 in your paper.

Hi @iCGY96! Thanks for your insightful work! I found it is hard to understand in Section 5.3: Labeled by Amplitude or Phase? In this section, the authors investigated the use of labels amplitude and phase separately. "The model is trained for the sample x combined by the phase spectrum Pxi and the amplitude spectrum Axj by optimizing Eq(7)". How to understand x combined by the phase spectrum P and the amplitude spectrum A. Is it means that you first decouple the x into A and P, then input the A and P to the networks with two FC
layers, or input [X, P] and [X, A] into the networks?

dafault path of data_dir is wrong in ./autoattacks/train_fgsm.py

if you have tried ./main.py and prepared datasets in ./data, and you want to train the code in ./autoattacks like me, attention here.
in line 26 of train_fgsm.py:
parser.add_argument('--data-dir', default='../data', type=str)
should be modifieed to:
parser.add_argument('--data-dir', default='../data/cifar10', type=str)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.