code: def test_wavelet(
      sr,
      fmin,
      n_bins,
      bins_per_octave,
      filter_scale,
      pad_fft,
      norm,
      gamma,
  ):
      freqs = librosa.cqt_frequencies(
          fmin=fmin, n_bins=n_bins, bins_per_octave=bins_per_octave
      )
  
      F, lengths = librosa.filters.wavelet(
          freqs=freqs,
          sr=sr,
          filter_scale=filter_scale,
          pad_fft=pad_fft,
          norm=norm,
          gamma=gamma,
      )
  
      assert np.all(lengths <= F.shape[1])
  
      assert len(F) == n_bins
  
      if not pad_fft:
          return
  
      assert np.mod(np.log2(F.shape[1]), 1.0) == 0.0
  
      # Check for vanishing negative frequencies
      F_fft = np.abs(np.fft.fft(F, axis=1))
      # Normalize by row-wise peak
      F_fft = F_fft / np.max(F_fft, axis=1, keepdims=True)
      assert np.max(F_fft[:, -F_fft.shape[1] // 2 :]) < 1e-3
  
imports: import os
  from contextlib import nullcontext
  import warnings
  import glob
  import numpy
  import scipy.io
  import scipy.signal
  from typing import Any, ContextManager
  import pytest
  import librosa
label_desc: Use image node_id 15 for calling a global function with example usage: test_wavelet(sr, fmin, n_bins, bins_per_octave, filter_scale, pad_fft, norm, gamma) without return types