code: def test_scipy_sparse_tensors(self):
      def generate_scipy():
          for i in range(4):
              x = scipy.sparse.coo_matrix(
                  ([1.0, 2.0], ([0, 1], [0, 2])), shape=[2, 4]
              )
              y = scipy.sparse.coo_matrix(
                  ([3.0, 4.0], ([0, 1], [0, 1])), shape=[2, 2]
              )
              yield x, y
  
      adapter = generator_data_adapter.GeneratorDataAdapter(
          generate_scipy()
      )
      ds = adapter.get_tf_dataset()
      for batch in ds:
          self.assertEqual(len(batch), 2)
          bx, by = batch
          self.assertIsInstance(bx, tf.SparseTensor)
          self.assertIsInstance(by, tf.SparseTensor)
          self.assertEqual(bx.shape, (2, 4))
          self.assertEqual(by.shape, (2, 2))
  
file_path: keras/keras/trainers/data_adapters/generator_data_adapter_test.py
imports: import math
  import numpy
  import scipy
  import tensorflow
  from absl.testing import parameterized
  from keras import testing
  from keras.trainers.data_adapters import generator_data_adapter
label_desc: Use image node_id 3 for calling the GeneratorDataAdapterTest obj's underlying member method code with example usage: obj.test_scipy_sparse_tensors() without return types