class_docstr: Implementation of the `LaserBeam` attack.
  
  | Paper link: https://arxiv.org/abs/2103.06504
class_docstr_tok: ["Implementation","of","the","`","LaserBeam","`","attack",".","|","Paper","link",":","https",":","\/\/arxiv.org\/abs\/2103.06504"]
docstr: :param estimator: Predictor of the image class.
  :param iterations: Maximum number of iterations of the algorithm.
  :param max_laser_beam: LaserBeam with maximal parameters or tuple (wavelength, angle::radians, bias, width)
      of the laser parameters.
  :param min_laser_beam: LaserBeam with minimal parameters or tuple (wavelength, angle::radians, bias, width)
      of the laser parameters.
  :param image_generator: Object responsible for image generation.
  :param random_initializations: How many times repeat the attack.
  :param debug: Optional debug handler.
docstr_tok: [":","param","estimator",":","Predictor","of","the","image","class",".",":","param","iterations",":","Maximum","number","of","iterations","of","the","algorithm",".",":","param","max_laser_beam",":","LaserBeam","with","maximal","parameters","or","tuple","(","wavelength",",","angle",":",":radians",",","bias",",","width",")","of","the","laser","parameters",".",":","param","min_laser_beam",":","LaserBeam","with","minimal","parameters","or","tuple","(","wavelength",",","angle",":",":radians",",","bias",",","width",")","of","the","laser","parameters",".",":","param","image_generator",":","Object","responsible","for","image","generation",".",":","param","random_initializations",":","How","many","times","repeat","the","attack",".",":","param","debug",":","Optional","debug","handler","."]
code: def __init__(
      self,
      estimator,
      iterations: int,
      max_laser_beam: Union[LaserBeam, Tuple[float, float, float, int]],
      min_laser_beam: Union[
          LaserBeam, Tuple[float, float, float, int]
      ] = (380.0, 0.0, 1.0, 1),
      random_initializations: int = 1,
      image_generator: ImageGenerator = ImageGenerator(),
      debug: Optional[DebugInfo] = None,
  ) -> None:
      """
      :param estimator: Predictor of the image class.
      :param iterations: Maximum number of iterations of the algorithm.
      :param max_laser_beam: LaserBeam with maximal parameters or tuple (wavelength, angle::radians, bias, width)
          of the laser parameters.
      :param min_laser_beam: LaserBeam with minimal parameters or tuple (wavelength, angle::radians, bias, width)
          of the laser parameters.
      :param image_generator: Object responsible for image generation.
      :param random_initializations: How many times repeat the attack.
      :param debug: Optional debug handler.
      """
  
      if isinstance(min_laser_beam, tuple):
          min_laser_beam_obj = LaserBeam.from_array(
              list(min_laser_beam)
          )
      else:
          min_laser_beam_obj = min_laser_beam
      if isinstance(max_laser_beam, tuple):
          max_laser_beam_obj = LaserBeam.from_array(
              list(max_laser_beam)
          )
      else:
          max_laser_beam_obj = max_laser_beam
  
      super().__init__(
          estimator,
          iterations,
          LaserBeamGenerator(min_laser_beam_obj, max_laser_beam_obj),
          image_generator=image_generator,
          random_initializations=random_initializations,
          debug=debug,
      )
  
imports: import logging
  from typing import Callable, List, Optional, Tuple, Union, Any
  import numpy
  from art.attacks.attack import EvasionAttack
  from art.attacks.evasion.laser_attack.algorithms import greedy_search
  from art.attacks.evasion.laser_attack.utils import AdversarialObject, AdvObjectGenerator, DebugInfo, ImageGenerator, Line, wavelength_to_rgb
label_desc: Use image node_id 1 to create a new LaserBeamAttack object from inherited base classes: LaserAttack with example: obj = LaserBeamAttack(estimator, iterations, max_laser_beam, min_laser_beam, random_initializations, image_generator, debug)