code: def test_flow_batch_size(barbell, batch_size):
      scales = (0.1, 2, 3, 4)
      generator = GraphWaveGenerator(barbell, scales=scales, degree=10)
      sample_points = np.linspace(0, 100, 25)
  
      expected_embed_dim = len(sample_points) * len(scales) * 2
  
      for i, x in enumerate(
          generator.flow(
              barbell.nodes(),
              sample_points=sample_points,
              batch_size=batch_size,
              repeat=False,
          )
      ):
          # all batches except maybe last will have a batch size of batch_size
          if i < barbell.number_of_nodes() // batch_size:
              assert x.shape == (batch_size, expected_embed_dim)
          else:
              assert x.shape == (
                  barbell.number_of_nodes() % batch_size,
                  expected_embed_dim,
              )
  
file_path: stellargraph/tests/mapper/test_graphwave_generator.py
imports: from stellargraph.core.graph import *
  from stellargraph.mapper.graphwave_generator import GraphWaveGenerator, _empirical_characteristic_function
  from ..test_utils.graphs import barbell
  import numpy
  import pytest
  import scipy.sparse
  import tensorflow
label_desc: Use image node_id 8 for calling a global function with example usage: test_flow_batch_size(barbell, batch_size) without return types