code: def load_from_disk(filename: str) -> Any:
      """Load a dataset from file.
  
      Parameters
      ----------
      filename: str
          A filename you want to load data.
  
      Returns
      -------
      Any
          A loaded object from file.
      """
      name = filename
      if os.path.splitext(name)[1] == ".gz":
          name = os.path.splitext(name)[0]
      extension = os.path.splitext(name)[1]
      if extension == ".pkl":
          return load_pickle_file(filename)
      elif extension == ".joblib":
          return joblib.load(filename)
      elif extension == ".csv":
          # First line of user-specified CSV *must* be header.
          df = pd.read_csv(filename, header=0)
          df = df.replace(np.nan, str(""), regex=True)
          return df
      elif extension == ".npy":
          return np.load(filename, allow_pickle=True)
      else:
          raise ValueError("Unrecognized filetype for %s" % filename)
  
imports: import joblib
  import gzip
  import pickle
  import os
  import tempfile
  import tarfile
  import zipfile
  import logging
  from urllib.request import urlretrieve
  from typing import Any, Iterator, List, Optional, Tuple, Union, cast, IO
  import pandas
  import numpy
  import deepchem
label_desc: Use image node_id 15 for calling a global function with example usage: load_from_disk(filename) and returns: load_pickle_file, joblib, df, np