code: def test_RelationalGraphConvolution_sparse():
      G, features = create_graph_features()
      n_edge_types = len(G.edge_types)
  
      # We need to specify the batch shape as one for the GraphConvolutional logic to work
      n_nodes = features.shape[0]
      n_feat = features.shape[1]
  
      # Inputs for features
      x_t = Input(batch_shape=(1, n_nodes, n_feat))
  
      # Create inputs for sparse or dense matrices
  
      # Placeholders for the sparse adjacency matrix
      As_indices = [
          Input(batch_shape=(1, None, 2), dtype="int64")
          for i in range(n_edge_types)
      ]
      As_values = [
          Input(batch_shape=(1, None)) for i in range(n_edge_types)
      ]
      A_placeholders = As_indices + As_values
  
      Ainput = [
          SqueezedSparseConversion(
              shape=(n_nodes, n_nodes), dtype=As_values[i].dtype
          )([As_indices[i], As_values[i]])
          for i in range(n_edge_types)
      ]
  
      x_inp_model = [x_t] + A_placeholders
      x_inp_conv = [x_t] + Ainput
  
      out = RelationalGraphConvolution(
          2, num_relationships=n_edge_types
      )(x_inp_conv)
  
      # Note we add a batch dimension of 1 to model inputs
      As = [A.tocoo() for A in get_As(G)]
  
      A_indices = [
          np.expand_dims(
              np.hstack((A.row[:, None], A.col[:, None])).astype(
                  np.int64
              ),
              0,
          )
          for A in As
      ]
      A_values = [np.expand_dims(A.data, 0) for A in As]
  
      out_indices = np.array([[0, 1]], dtype="int32")
      x = features[None, :, :]
  
      model = keras.Model(inputs=x_inp_model, outputs=out)
      preds = model.predict([x] + A_indices + A_values, batch_size=1)
      assert preds.shape == (1, 3, 2)
  
imports: import numpy
  from stellargraph.layer.rgcn import RelationalGraphConvolution, RGCN
  from stellargraph.mapper.full_batch_generators import RelationalFullBatchNodeGenerator
  import pytest
  from scipy import sparse
  from stellargraph.core.utils import normalize_adj
  import tensorflow
  from tensorflow import keras
  from tensorflow.keras import backend
  from tensorflow.keras.layers import Input, Lambda
  from stellargraph import StellarDiGraph, StellarGraph
  from stellargraph.layer.misc import SqueezedSparseConversion
  import pandas
  from ..test_utils.graphs import relational_create_graph_features
  from ..None import test_utils
label_desc: Use image node_id 3 for calling a global function with example usage: test_RelationalGraphConvolution_sparse() without return types