class_docstr: Spatial transformation attack
docstr: Generate symbolic graph for adversarial examples and return.
  :param x: The model's symbolic inputs.
  :param kwargs: See `parse_params`
docstr_tok: ["Generate","symbolic","graph","for","adversarial","examples","and","return",".",":","param","x",":","The","model","'s","symbolic","inputs",".",":","param","kwargs",":","See","`","parse_params","`"]
code: def generate(self, x, **kwargs):
      """
      Generate symbolic graph for adversarial examples and return.
      :param x: The model's symbolic inputs.
      :param kwargs: See `parse_params`
      """
      # Parse and save attack-specific parameters
      assert self.parse_params(**kwargs)
  
      from cleverhans.attacks_tf import spm
  
      labels, _ = self.get_or_guess_labels(x, kwargs)
  
      return spm(
          x,
          self.model,
          y=labels,
          n_samples=self.n_samples,
          dx_min=self.dx_min,
          dx_max=self.dx_max,
          n_dxs=self.n_dxs,
          dy_min=self.dy_min,
          dy_max=self.dy_max,
          n_dys=self.n_dys,
          angle_min=self.angle_min,
          angle_max=self.angle_max,
          n_angles=self.n_angles,
          black_border_size=self.black_border_size,
      )
  
imports: import warnings
  from cleverhans.attacks.attack import Attack
label_desc: Use image node_id 2 for calling the SpatialTransformationMethod obj's underlying member method code with example usage: obj.generate(x) and returns: spm