code: def test_default(tmp_path, dd=data_dict):
      # copy data_dict so values aren't changed
      dd = dd.copy()
  
      # Run the simulation
      gen.generate_data(str(tmp_path), dd)
  
      # Check that there are 32 files where there should be (30 plus label and
      # mask)
      assert (
          len(os.listdir(str(tmp_path))) == 32
      ), "Incorrect file number"
  
      # Check that the data is the right shape
      input_template = dd["template_path"]
      input_shape = input_template.shape
      output_vol = np.load(tmp_path / "rt_000.npy")
      output_shape = output_vol.shape
      assert input_shape == output_shape, "Output shape is incorrect"
  
      # Check the labels have the correct count
      labels = np.load(tmp_path / "labels.npy")
  
      assert np.sum(labels > 0) == 9, "Incorrect number of events"
  
file_path: brainiak/tests/utils/test_fmrisim_real_time.py
imports: import numpy
  from brainiak.utils import fmrisim_real_time_generator
  import pytest
  import os
  import time
  import glob
  from pkg_resources import resource_stream
  from typing import Dict
  from nibabel.nifti1 import Nifti1Image
  import gzip
label_desc: Use image node_id 1 for calling a global function with example usage: test_default(tmp_path, dd) without return types