docstr: Test that upsampling is accurate for different methods.
  
  Generates a sample signal and resamples it to a higher resolution.
  Compares the upsampled signal and original signal at corresponding
  subsampled points.
  
  Args:
    add_endpoint: Add extra timestep at end of resampling.
    method: Method of resampling.
docstr_tok: ["Test","that","upsampling","is","accurate","for","different","methods",".","Generates","a","sample","signal","and","resamples","it","to","a","higher","resolution",".","Compares","the","upsampled","signal","and","original","signal","at","corresponding","subsampled","points",".","Args",":","add_endpoint",":","Add","extra","timestep","at","end","of","resampling",".","method",":","Method","of","resampling","."]
code: def test_upsample_accuracy(self, add_endpoint, method):
      """Test that upsampling is accurate for different methods.
  
      Generates a sample signal and resamples it to a higher resolution.
      Compares the upsampled signal and original signal at corresponding
      subsampled points.
  
      Args:
        add_endpoint: Add extra timestep at end of resampling.
        method: Method of resampling.
      """
      before, after = self.create_resampled_signals(
          n_before=self.n_smaller,
          n_after=self.n_larger,
          add_endpoint=add_endpoint,
          method=method,
      )
      self.assert_subsampled_close(
          smaller=before, larger=after, add_endpoint=add_endpoint
      )
  
imports: from absl.testing import parameterized
  from ddsp import core
  import librosa
  import numpy
  from scipy import signal
  import tensorflow.compat.v2
label_desc: Use image node_id 6 for calling the ResampleTest obj's underlying member method code with example usage: obj.test_upsample_accuracy(add_endpoint, method) without return types