code: def np_to_creator(data):
      def data_creator(config, batch_size):
          return DataLoader(
              TensorDataset(
                  torch.from_numpy(data[0]).float(),
                  torch.from_numpy(data[1]).float(),
              ),
              batch_size=batch_size,
              shuffle=True,
          )
  
      return data_creator
  
imports: import torch
  import torch.nn
  import warnings
  import random
  import numpy
  from torch.utils.data import TensorDataset, DataLoader
  import numpy
  import multiprocessing
  import warnings
  import math
label_desc: Use image node_id 2 for calling a global function with example usage: np_to_creator(data) and returns: data_creator, DataLoader