code: def load_data_numpy(input_dir, prefix):
      train_data = np.load(
          os.path.join(input_dir, prefix + "train.npy"),
          encoding="latin1",
          allow_pickle=True,
      ).tolist()
      dev_data = np.load(
          os.path.join(input_dir, prefix + "valid.npy"),
          encoding="latin1",
          allow_pickle=True,
      ).tolist()
      test_data = np.load(
          os.path.join(input_dir, prefix + "test.npy"),
          encoding="latin1",
          allow_pickle=True,
      ).tolist()
      print("train data size:{}".format(len(train_data)))
      return train_data, dev_data, test_data
  
file_path: texar/examples/transformer/utils/data_utils.py
imports: import os
  import codecs
  import six
  import numpy
label_desc: Use image node_id 1 for calling a global function with example usage: load_data_numpy(input_dir, prefix) and returns: train_data,  dev_data,  test_data