Imported from https://github.com/louis2889184/pytorch-adversarial-training