code: def peaking_equalizer(
      audio: Union[str, np.ndarray],
      sample_rate: int = DEFAULT_SAMPLE_RATE,
      center_hz: float = 500.0,
      q: float = 1.0,
      gain_db: float = -3.0,
      output_path: Optional[str] = None,
      metadata: Optional[List[Dict[str, Any]]] = None,
  ) -> Tuple[np.ndarray, int]:
      """
      Applies a two-pole peaking equalization filter. The signal-level at and around
      `center_hz` can be increased or decreased, while all other frequencies are unchanged
  
      @param audio: the path to the audio or a variable of type np.ndarray that
          will be augmented
  
      @param sample_rate: the audio sample rate of the inputted audio
  
      @param center_hz: point in the frequency spectrum at which EQ is applied
  
      @param q: ratio of center frequency to bandwidth; bandwidth is inversely
          proportional to Q, meaning that as you raise Q, you narrow the bandwidth
  
      @param gain_db: amount of gain (boost) or reduction (cut) that is applied at a
          given frequency. Beware of clipping when using positive gain
  
      @param output_path: the path in which the resulting audio will be stored. If None,
          the resulting np.ndarray will still be returned
  
      @param metadata: if set to be a list, metadata about the function execution
          including its name, the source & dest duration, sample rates, etc. will be
          appended to the inputted list. If set to None, no metadata will be appended
  
      @returns: the augmented audio array and sample rate
      """
      assert isinstance(
          center_hz, (int, float)
      ), "Expected 'center_hz' to be a number"
      assert (
          isinstance(q, (int, float)) and q > 0
      ), "Expected 'q' to be a positive number"
      assert isinstance(
          gain_db, (int, float)
      ), "Expected 'gain_db' to be a number"
      audio, sample_rate = audutils.validate_and_load_audio(
          audio, sample_rate
      )
  
      if metadata is not None:
          func_kwargs = deepcopy(locals())
          func_kwargs.pop("metadata")
  
      num_channels = 1 if audio.ndim == 1 else audio.shape[0]
      aug_audio = audio.reshape((num_channels, -1))
  
      aug_audio, out_sample_rate = sox_effects.apply_effects_tensor(
          torch.Tensor(aug_audio),
          sample_rate,
          [["equalizer", str(center_hz), f"{q}q", str(gain_db)]],
      )
  
      aug_audio = aug_audio.numpy()
      if num_channels == 1:
          aug_audio = aug_audio.reshape((aug_audio.shape[-1],))
  
      if metadata is not None:
          audutils.get_metadata(
              metadata=metadata,
              function_name="peaking_equalizer",
              dst_audio=aug_audio,
              dst_sample_rate=out_sample_rate,
              # pyre-fixme[61]: `func_kwargs` may not be initialized here.
              **func_kwargs,
          )
  
      return audutils.ret_and_save_audio(
          aug_audio, output_path, out_sample_rate
      )
  
imports: from copy import deepcopy
  from typing import Any, Callable, Dict, List, Optional, Tuple, Union
  import numpy
  import torch
  from augly.audio import utils
  from augly.utils import DEFAULT_SAMPLE_RATE
  from augly.utils.libsndfile import install_libsndfile
  import librosa
  from torchaudio import sox_effects
  from torchaudio.functional import fftconvolve, resample
label_desc: Use image node_id 13 for calling a global function with example usage: peaking_equalizer(audio, sample_rate, center_hz, q, gain_db, output_path, metadata) and returns: audutils