code: def test_predict_proba_simple(X_masked, distributions):
      d1, d2, d3, d4, d12, d22, d32, d13 = distributions
  
      model = BayesianNetwork(
          [d1, d22, d13, d4], [(d1, d22), (d22, d13), (d4, d13)]
      )
      y_hat = model.predict_proba(X_masked)
  
      assert_array_almost_equal(
          y_hat[0],
          [
              [0.9412, 0.0588],
              [1.0000, 0.0000],
              [0.8889, 0.1111],
              [0.0000, 1.0000],
              [0.6667, 0.3333],
              [1.0000, 0.0000],
              [0.8889, 0.1111],
              [0.0000, 1.0000],
              [0.0000, 1.0000],
              [1.0000, 0.0000],
              [1.0000, 0.0000],
          ],
          4,
      )
  
      assert_array_almost_equal(
          y_hat[1],
          [
              [0.0000, 0.0000, 1.0000],
              [1.0000, 0.0000, 0.0000],
              [0.6778, 0.1333, 0.1889],
              [0.0000, 0.0000, 1.0000],
              [0.0000, 1.0000, 0.0000],
              [0.0000, 1.0000, 0.0000],
              [0.6778, 0.1333, 0.1889],
              [0.5147, 0.4706, 0.0147],
              [0.0000, 1.0000, 0.0000],
              [0.0000, 0.0000, 1.0000],
              [0.6121, 0.0650, 0.3229],
          ],
          4,
      )
  
      assert_array_almost_equal(
          y_hat[2],
          [
              [1.0000, 0.0000],
              [0.3900, 0.6100],
              [0.5300, 0.4700],
              [0.0000, 1.0000],
              [0.2900, 0.7100],
              [1.0000, 0.0000],
              [0.5300, 0.4700],
              [0.0000, 1.0000],
              [1.0000, 0.0000],
              [0.0000, 1.0000],
              [1.0000, 0.0000],
          ],
          4,
      )
  
      assert_array_almost_equal(
          y_hat[3],
          [
              [1.0000, 0.0000],
              [0.3000, 0.7000],
              [1.0000, 0.0000],
              [0.0000, 1.0000],
              [0.3000, 0.7000],
              [0.5172, 0.4828],
              [1.0000, 0.0000],
              [0.0000, 1.0000],
              [0.5172, 0.4828],
              [1.0000, 0.0000],
              [0.3565, 0.6435],
          ],
          4,
      )
  
imports: import numpy
  import torch
  import pytest
  from pomegranate.bayesian_network import BayesianNetwork
  from pomegranate.distributions import Exponential
  from pomegranate.distributions import Categorical
  from pomegranate.distributions import ConditionalCategorical
  from nose.tools import assert_raises
  from numpy.testing import assert_array_equal
  from numpy.testing import assert_array_almost_equal
label_desc: Use image node_id 19 for calling a global function with example usage: test_predict_proba_simple(X_masked, distributions) without return types