class_docstr: Apply time or frequency warping to a spectrogram.
  
  If `dim=1`, time warping is applied; if `dim=2`, frequency warping is applied.
  This implementation selects a center and a window length to perform warping.
  It ensures that the temporal dimension remains unchanged by upsampling or
  downsampling the affected regions accordingly.
  
  Reference:
      https://arxiv.org/abs/1904.08779
  
  Arguments
  ---------
  warp_window : int, optional
      The width of the warping window. Default is 5.
  warp_mode : str, optional
      The interpolation mode for time warping. Default is "bicubic."
  dim : int, optional
      Dimension along which to apply warping (1 for time, 2 for frequency).
      Default is 1.
  
  Example
  -------
  >>> # Time-warping
  >>> warp = Warping()
  >>> spectrogram = torch.rand(4, 150, 40)
  >>> print(spectrogram.shape)
  torch.Size([4, 150, 40])
  >>> out = warp(spectrogram)
  >>> print(out.shape)
  torch.Size([4, 150, 40])
  >>> # Frequency-warping
  >>> warp = Warping(dim=2)
  >>> spectrogram = torch.rand(4, 150, 40)
  >>> print(spectrogram.shape)
  torch.Size([4, 150, 40])
  >>> out = warp(spectrogram)
  >>> print(out.shape)
  torch.Size([4, 150, 40])
code: def __init__(self, warp_window=5, warp_mode="bicubic", dim=1):
      super().__init__()
      self.warp_window = warp_window
      self.warp_mode = warp_mode
      self.dim = dim
  
file_path: speechbrain/speechbrain/augment/freq_domain.py
imports: import torch
  import random
label_desc: Use image node_id 1 to create a new Warping object from inherited base classes: torch.nn with example: obj = Warping(warp_window, warp_mode, dim)