docs: def load_data(directory, num):
      """Load numpy data from the data directory.
  
      The files should stored in ``../data/<dir>`` and named
      ``0.npy, 1.npy, ... <num - 1>.npy``.
  
      Returns:
          list: A list of loaded data, such that ``list[i]`` contains the the
          contents of ``i.npy``.
      """
      root = os.path.abspath(os.path.dirname(__file__))
  
      def get_path(i):  # pylint: disable=missing-docstring
          return os.path.join(root, 'data', directory, str(i) + '.npy')
  
      return [np.load(get_path(i)) for i in range(num)]