code: def testRegression(self):
      # Simple regression test, comparing to reference values
      #
      # This test started to fail after the improvements
      # described in 16258bf97eedb35299450874675bf2bde6eb5aa8.
      # However, as the new way to compute the bands makes more
      # sense, lets asumme that the current behavior is correct.
      # The expected values were updated after commit
      # 3e3538080a1d4336c293f822d44cc7619b40660f
  
      audio = MonoLoader(
          filename=join(testdata.audio_dir, "recorded/musicbox.wav"),
          sampleRate=44100,
      )()
  
      fft = Spectrum()
      window = Windowing(type="hamming")
      SC = SpectralContrast(sampleRate=44100)
  
      expected = 0
  
      sc = []
      valleys = []
      for frame in FrameGenerator(audio, frameSize=2048, hopSize=512):
          result = SC(fft(window(frame)))
          self.assert_(not any(numpy.isnan(result[0])))
          self.assert_(not any(numpy.isinf(result[1])))
          sc += [result[0]]
          valleys += [result[1]]
  
      expected_constrast = [
          -0.39171591,
          -0.47914168,
          -0.56516778,
          -0.71739447,
          -0.81886953,
          -0.85993105,
      ]
      expected_valleys = [
          -6.09844828,
          -6.20369911,
          -8.22635174,
          -9.10304642,
          -9.83238029,
          -10.69903278,
      ]
  
      self.assertAlmostEqualVector(
          numpy.mean(sc, 0), expected_constrast, 1e-6
      )
      self.assertAlmostEqualVector(
          numpy.mean(valleys, 0), expected_valleys, 1e-6
      )
  
file_path: essentia/test/src/unittests/spectral/test_spectralcontrast.py
imports: from essentia_test import *
label_desc: Use image node_id 1 for calling the TestSpectralContrast obj's underlying member method code with example usage: obj.testRegression() without return types