code: def test_hmm_behaves_as_expected_on_simple_input():
      """Test HMM is consistent with expected ground truth in simple ex."""
      # define the emission probs for our HMM model:
      centers = [3.5, -5]
      sd = [0.25 for i in centers]
      emi_funcs = [
          (norm.pdf, {"loc": mean, "scale": sd[ind]})
          for ind, mean in enumerate(centers)
      ]
      hmm_est = HMM(emi_funcs, asarray([[0.25, 0.75], [0.666, 0.333]]))
      # generate synthetic data (or of course use your own!)
      obs = asarray([3.7, 3.2, 3.4, 3.6, -5.1, -5.2, -4.9])
      hmm_est = hmm_est.fit(obs)
      labels = hmm_est.predict(obs)
      ground_truth = asarray([0, 0, 0, 0, 1, 1, 1])
      assert array_equal(labels, ground_truth)
  
file_path: sktime/sktime/annotation/tests/test_hmm.py
imports: import numpy
  import pytest
  from numpy import array_equal, asarray
  from scipy.stats import norm
  from sktime.annotation.hmm import HMM
label_desc: Use image node_id 3 for calling a global function with example usage: test_hmm_behaves_as_expected_on_simple_input() without return types