code: def plot_waveform(waveform, sr, title="Waveform", ax=None):
      waveform = waveform.numpy()
  
      num_channels, num_frames = waveform.shape
      time_axis = torch.arange(0, num_frames) / sr
  
      if ax is None:
          _, ax = plt.subplots(num_channels, 1)
      ax.plot(time_axis, waveform[0], linewidth=1)
      ax.grid(True)
      ax.set_xlim([0, time_axis[-1]])
      ax.set_title(title)
  
file_path: audio/examples/tutorials/audio_feature_extractions_tutorial.py
imports: import torch
  import torchaudio
  import torchaudio.functional
  import torchaudio.transforms
  import librosa
  import matplotlib.pyplot
  from IPython.display import Audio
  from matplotlib.patches import Rectangle
  from torchaudio.utils import download_asset
label_desc: Use image node_id 1 for calling a global function with example usage: plot_waveform(waveform, sr, title, ax) without return types