docstr: Ensure that spectral_ops.pad('same') is same as stft(pad_end=True).
docstr_tok: ["Ensure","that","spectral_ops.pad","(","'same","'",")","is","same","as","stft","(","pad_end=True",")","."]
code: def test_pad_end_stft_is_consistent(self):
      """Ensure that spectral_ops.pad('same') is same as stft(pad_end=True)."""
      frame_size = 200
      hop_size = 180
      audio = tf.random.normal([1, 1000])
      padded_audio = spectral_ops.pad(
          audio, frame_size, hop_size, "same"
      )
      s_pad_end = tf.signal.stft(
          audio, frame_size, hop_size, pad_end=True
      )
      s_same = tf.signal.stft(
          padded_audio, frame_size, hop_size, pad_end=False
      )
      self.assertAllClose(
          np.abs(s_pad_end), np.abs(s_same), rtol=1e-3, atol=1e-3
      )
  
imports: from absl.testing import parameterized
  from ddsp import spectral_ops
  from ddsp.test_util import gen_np_sinusoid
  import numpy
  import tensorflow.compat.v2
label_desc: Use image node_id 1 for calling the PadTest obj's underlying member method code with example usage: obj.test_pad_end_stft_is_consistent() without return types