class_docstr: Abstract base class for all attack classes.
  
  :param predict: forward pass function.
  :param loss_fn: loss function that takes .
  :param clip_min: mininum value per input dimension.
  :param clip_max: maximum value per input dimension.
docstr: Virtual method for generating the adversarial examples.
  
  :param x: the model's input tensor.
  :param **kwargs: optional parameters used by child classes.
  :return: adversarial examples.
code: def perturb(self, x, **kwargs):
      """Virtual method for generating the adversarial examples.
  
      :param x: the model's input tensor.
      :param **kwargs: optional parameters used by child classes.
      :return: adversarial examples.
      """
      error = "Sub-classes must implement perturb."
      raise NotImplementedError(error)
  
file_path: advertorch/advertorch/attacks/base.py
imports: from abc import ABCMeta
  import torch
  from advertorch.utils import replicate_input
label_desc: Use image node_id 2 for calling the Attack obj's underlying member method code with example usage: obj.perturb(x) without return types