code: def test_returns_expected_shapes(
      self, shape, use_gibbs_predictive_dist
  ):
      series = self._build_test_series(
          shape=shape, freq=pd.DateOffset(hours=1)
      )
      predictions = anomaly_detection.detect_anomalies(
          series,
          anomaly_threshold=0.01,
          use_gibbs_predictive_dist=use_gibbs_predictive_dist,
          num_warmup_steps=5,
          num_samples=5,
          jit_compile=False,
          seed=test_util.test_seed(sampler_type="stateless"),
      )
  
      results_length = shape[0]
      results_shape = shape[1:] + [results_length]
      self.assertAllEqual(
          predictions.observed_time_series.shape, results_shape
      )
      self.assertAllEqual(predictions.mean.shape, results_shape)
      self.assertAllEqual(predictions.lower_limit.shape, results_shape)
      self.assertAllEqual(predictions.upper_limit.shape, results_shape)
      self.assertAllEqual(
          predictions.tail_probabilities.shape, results_shape
      )
      self.assertAllEqual(predictions.is_anomaly.shape, results_shape)
      self.assertLen(predictions.times, results_length)
  
file_path: probability/tensorflow_probability/python/sts/anomaly_detection/anomaly_detection_test.py
imports: from absl.testing import parameterized
  import numpy
  import pandas
  import tensorflow.compat.v2
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.sts import anomaly_detection
label_desc: Use image node_id 2 for calling the AnomalyDetectionTests obj's underlying member method code with example usage: obj.test_returns_expected_shapes(shape, use_gibbs_predictive_dist) without return types