code: def test_from_summaries_inertia(X, w, probs):
      d = ConditionalCategorical(probs, inertia=0.3)
      d.summarize(X[:4])
      d.from_summaries()
      _test_efd_from_summaries(
          d,
          "probs",
          "_log_probs",
          [
              [[0.425, 0.575], [0.621, 0.379]],
              [[0.380, 0.620], [0.440, 0.560], [0.422, 0.578]],
              [[0.805, 0.195], [0.270, 0.730]],
          ],
      )
  
      d.summarize(X[4:])
      d.from_summaries()
      _test_efd_from_summaries(
          d,
          "probs",
          "_log_probs",
          [
              [[0.8275, 0.1725], [0.5363, 0.4637]],
              [
                  [0.464, 0.536],
                  [0.59866667, 0.40133333],
                  [0.4766, 0.5234],
              ],
              [[0.9415, 0.0585], [0.0810, 0.9190]],
          ],
      )
  
      d = ConditionalCategorical(probs, inertia=0.3)
      d.summarize(X)
      d.from_summaries()
      _test_efd_from_summaries(
          d,
          "probs",
          "_log_probs",
          [
              [[0.775, 0.225], [0.56266665, 0.43733335]],
              [[0.38, 0.62], [0.5566667, 0.44333333], [0.422, 0.578]],
              [[0.805, 0.195], [0.270, 0.730]],
          ],
      )
  
imports: import numpy
  import torch
  import pytest
  from pomegranate.distributions import ConditionalCategorical
  from ._utils import _test_initialization_raises_one_parameter
  from ._utils import _test_initialization
  from ._utils import _test_predictions
  from ._utils import _test_raises
  from nose.tools import assert_raises
  from numpy.testing import assert_array_almost_equal
label_desc: Use image node_id 26 for calling a global function with example usage: test_from_summaries_inertia(X, w, probs) without return types