code: def train_data_discrete_marginals(train_data_discrete_cpds):
      return create_marginals(
          train_data_discrete_cpds,
          {
              "a": ["a", "b", "c", "d"],
              "b": ["x", "y", "z"],
              "c": [0, 1, 2, 3, 4],
              "d": [False, True],
              "e": [False, True],
          },
      )
  
imports: import itertools
  from typing import Dict
  import numpy
  import pandas
  import pytest
  from pgmpy.models import BayesianNetwork
  from sklearn.datasets import load_iris
  from causalnex.discretiser import Discretiser
  from causalnex.network import BayesianNetwork
  from causalnex.structure import StructureModel
  from causalnex.structure.notears import from_pandas
label_desc: Use image node_id 11 for calling a global function with example usage: train_data_discrete_marginals(train_data_discrete_cpds) and returns: create_marginals