class_docstr: Attack step for :math:`\ell_\infty` threat model. Given :math:`x_0`
  and :math:`\epsilon`, the constraint set is given by:
  
  .. math:: S = \{x | \|x - x_0\|_2 \leq \epsilon\}
class_docstr_tok: ["Attack","step","for",":","math",":","`","\\ell_\\infty","`","threat","model",".","Given",":","math",":","`","x_0","`","and",":","math",":","`","\\epsilon","`",",","the","constraint","set","is","given","by",":","..","math",":",":","S","=","\\","{","x","|","\\|x","-","x_0\\|_2","\\leq","\\epsilon\\","}"]
docstr_tok: []
code: def step(self, x, g):
      """ """
      l = len(x.shape) - 1
      g_norm = ch.norm(g.view(g.shape[0], -1), dim=1).view(
          -1, *([1] * l)
      )
      scaled_g = g / (g_norm + 1e-10)
      return x + scaled_g * self.step_size
  
imports: import torch
label_desc: Use image node_id 2 for calling the L2Step obj's underlying member method code with example usage: obj.step(x, g) and returns: unknown