code: def test_cqt_2010(device):
      # Log sweep case
      fs = 44100
      t = 1
      f0 = 55
      f1 = 22050
      s = np.linspace(0, t, fs * t)
      x = chirp(s, f0, 1, f1, method="logarithmic")
      x = x.astype(dtype=np.float32)
  
      # Magnitude
      stft = CQT2010(
          sr=fs,
          fmin=110,
          output_format="Magnitude",
          n_bins=160,
          bins_per_octave=24,
      ).to(device)
      X = stft(torch.tensor(x, device=device).unsqueeze(0))
  
      # Complex
      stft = CQT2010(
          sr=fs,
          fmin=110,
          output_format="Complex",
          n_bins=160,
          bins_per_octave=24,
      ).to(device)
      X = stft(torch.tensor(x, device=device).unsqueeze(0))
  
      # Phase
      stft = CQT2010(
          sr=fs,
          fmin=110,
          output_format="Phase",
          n_bins=160,
          bins_per_octave=24,
      ).to(device)
      X = stft(torch.tensor(x, device=device).unsqueeze(0))
      assert True
  
file_path: nnAudio/Installation/tests/test_cqt.py
imports: import pytest
  import librosa
  import torch
  from scipy.signal import chirp, sweep_poly
  import sys
  import os
  from nnAudio.Spectrogram import *
  from parameters import *
  import warnings
label_desc: Use image node_id 2 for calling a global function with example usage: test_cqt_2010(device) without return types