code: def sample_items(bc, dask_client, nRals, **kwargs):
      # example: {csv: {tb1: tb1_csv, ...}, parquet: {tb1: tb1_parquet, ...}}
      dstables = dict(
          (
              ds,
              dict(
                  (t, t + "_" + str(ds).split(".")[1]) for t in tables
              ),
          )
          for ds in data_types
      )
  
      init_tables = kwargs.get("init_tables", False)
      sql_table_filter_map = kwargs.get("sql_table_filter_map", {})
      sql_table_batch_size_map = kwargs.get(
          "sql_table_batch_size_map", {}
      )
      sql = kwargs.get("sql_connection", None)
      dir_data_lc = kwargs.get("dir_data_lc", "")
  
      for fileSchemaType in datasources(dask_client, nRals):
          datasource_tables = dstables[fileSchemaType]
  
          if init_tables:
              print("Creating tables for", str(fileSchemaType))
              table_names = list(datasource_tables.values())
              if isinstance(
                  sql, createSchema.sql_connection
              ):  # create sql tables
                  createSchema.create_tables(
                      bc,
                      "",
                      fileSchemaType,
                      tables=tables,
                      table_names=table_names,
                      sql_table_filter_map=sql_table_filter_map,
                      sql_table_batch_size_map=sql_table_batch_size_map,
                      sql_connection=sql,
                  )
              else:  # create in file tables (parquet, csv, etc)
                  createSchema.create_tables(
                      bc,
                      dir_data_lc,
                      fileSchemaType,
                      tables=tables,
                      table_names=table_names,
                  )
  
              print("All tables were created for", str(fileSchemaType))
  
          for sampleId, sample in samples.items():
              sampleUID = str(fileSchemaType) + "." + sampleId
              yield sampleUID, sampleId, fileSchemaType, datasource_tables
  
file_path: blazingsql/tests/BlazingSQLTest/EndToEndTests/oldScripts/tablesFromSQL.py
imports: from collections import OrderedDict
  from blazingsql import DataType
  from DataBase import createSchema
  from Configuration import ExecutionMode
  from Configuration import Settings
  from Runner import runTest
  from Utils import gpuMemory, skip_test
  from EndToEndTests.oldScripts import tpchQueries
label_desc: Use image node_id 3 for calling a global function with example usage: sample_items(bc, dask_client, nRals) without return types