code: def copy_or_convert_data(
      input_path,
      output_path,
      input_format,
      output_format="numpy",
      in_memory=True,
      is_feature=False,
  ):
      """Copy or convert the data from input_path to output_path."""
      assert (
          output_format == "numpy"
      ), "The output format of the data should be numpy."
      os.makedirs(os.path.dirname(output_path), exist_ok=True)
      # If the original format is numpy, just copy the file.
      if input_format == "numpy":
          # If dim of the data is 1, reshape it to n * 1 and save it to output_path.
          if is_feature and get_npy_dim(input_path) == 1:
              data = read_data(input_path, input_format, in_memory)
              data = data.reshape(-1, 1)
              save_data(data, output_path, output_format)
          else:
              shutil.copyfile(input_path, output_path)
      else:
          # If the original format is not numpy, convert it to numpy.
          data = read_data(input_path, input_format, in_memory)
          if is_feature and data.dim() == 1:
              data = data.reshape(-1, 1)
          save_data(data, output_path, output_format)
  
file_path: dgl/python/dgl/graphbolt/internal/utils.py
imports: import hashlib
  import json
  import os
  import shutil
  from typing import List, Union
  import numpy
  import pandas
  import torch
  from numpy.lib.format import read_array_header_1_0, read_array_header_2_0
label_desc: Use image node_id 6 for calling a global function with example usage: copy_or_convert_data(input_path, output_path, input_format, output_format, in_memory, is_feature) without return types