code: def random_time_stretch(
      spectrogram: tf.Tensor,
      factor_min: float = 0.9,
      factor_max: float = 1.1,
      **kwargs,
  ) -> tf.Tensor:
      """
      Time stretch a spectrogram preserving shape with random ratio in
      tensorflow. Applies time_stretch to spectrogram with a random ratio
      drawn uniformly in `[factor_min, factor_max]`.
  
      Parameters:
          spectrogram (tf.Tensor):
              Input spectrogram to be time stretched as tensor.
          factor_min (float):
              (Optional) Min time stretch factor, default to `0.9`.
          factor_max (float):
              (Optional) Max time stretch factor, default to `1.1`.
          ** kwargs:
              Time stretch args.
  
      Returns:
          tf.Tensor:
              Randomly time stretched spectrogram as tensor with same shape.
      """
      factor = (
          tf.random_uniform(shape=(1,), seed=0)
          * (factor_max - factor_min)
          + factor_min
      )
      return time_stretch(spectrogram, factor=factor, **kwargs)
  
imports: import tensorflow
  from tensorflow.signal import hann_window, stft
label_desc: Use image node_id 3 for calling a global function with example usage: random_time_stretch(spectrogram, factor_min, factor_max) and returns: time_stretch