code: def test_get_cpds(self):
      self.network.add_edges_from(
          [
              (("D", 0), ("G", 0)),
              (("I", 0), ("G", 0)),
              (("D", 0), ("D", 1)),
              (("I", 0), ("I", 1)),
          ]
      )
      self.network.add_cpds(
          self.grade_cpd,
          self.d_i_cpd,
          self.diff_cpd,
          self.intel_cpd,
          self.i_i_cpd,
      )
      self.network.initialize_initial_state()
      self.assertEqual(
          {cpd.variable for cpd in self.network.get_cpds()},
          {("I", 1), ("D", 0), ("G", 1), ("I", 0), ("G", 0), ("D", 1)},
      )
      self.assertEqual(
          {
              cpd.variable
              for cpd in self.network.get_cpds(time_slice=[0, 1])
          },
          {("I", 1), ("D", 0), ("G", 1), ("I", 0), ("G", 0), ("D", 1)},
      )
      self.assertEqual(
          set(self.network.get_cpds(time_slice=0)),
          set([self.diff_cpd, self.intel_cpd, self.grade_cpd]),
      )
      self.assertEqual(
          {cpd.variable for cpd in self.network.get_cpds(time_slice=1)},
          {("D", 1), ("I", 1), ("G", 1)},
      )
      self.assertRaises(
          ValueError, self.network.get_cpds, time_slice=-1
      )
      self.assertRaises(
          ValueError, self.network.get_cpds, time_slice=[0, 1.1]
      )
      self.assertRaises(
          ValueError, self.network.get_cpds, time_slice="abc"
      )
  
imports: import unittest
  import numpy
  import numpy.testing
  import pandas
  import pgmpy.tests.help_functions
  from pgmpy.factors.discrete import TabularCPD
  from pgmpy.inference import CausalInference, DBNInference, VariableElimination
  from pgmpy.models import BayesianNetwork
  from pgmpy.models import DynamicBayesianNetwork
label_desc: Use image node_id 9 for calling the TestDynamicBayesianNetworkMethods obj's underlying member method code with example usage: obj.test_get_cpds() without return types