code: def test_hybrid_cqt(
      y_hybrid,
      sr,
      hop_length,
      fmin,
      n_bins,
      bins_per_octave,
      tuning,
      resolution,
      norm,
      sparsity,
      res_type,
  ):
      # This test verifies that hybrid and full cqt agree down to 1e-4
      # on 99% of bins which are nonzero (> 1e-8) in either representation.
  
      C2 = librosa.hybrid_cqt(
          y_hybrid,
          sr=sr,
          hop_length=hop_length,
          fmin=fmin,
          n_bins=n_bins,
          bins_per_octave=bins_per_octave,
          tuning=tuning,
          filter_scale=resolution,
          norm=norm,
          sparsity=sparsity,
          res_type=res_type,
      )
  
      C1 = np.abs(
          librosa.cqt(
              y_hybrid,
              sr=sr,
              hop_length=hop_length,
              fmin=fmin,
              n_bins=n_bins,
              bins_per_octave=bins_per_octave,
              tuning=tuning,
              filter_scale=resolution,
              norm=norm,
              sparsity=sparsity,
              res_type=res_type,
          )
      )
  
      assert C1.shape == C2.shape
  
      # Check for numerical comparability
      idx1 = C1 > 1e-4 * C1.max()
      idx2 = C2 > 1e-4 * C2.max()
  
      perc = 0.99
  
      thresh = 1e-3
  
      idx = idx1 | idx2
  
      assert np.percentile(
          np.abs(C1[idx] - C2[idx]), perc
      ) < thresh * max(C1.max(), C2.max())
  
imports: from __future__ import division
  import warnings
  import os
  from typing import Optional
  import librosa
  import numpy
  import scipy.stats
  import pytest
  from test_core import srand
label_desc: Use image node_id 15 for calling a global function with example usage: test_hybrid_cqt(y_hybrid, sr, hop_length, fmin, n_bins, bins_per_octave, tuning, resolution, norm, sparsity, res_type) without return types