code: def from_numpy_dataset(dataset) -> pd.DataFrame:
      """Returns a pandas dataframe from the dataset."""
      col_mapping = {}
      for k, v in dataset.items():
          if len(v.shape) > 1:
              # unstacking, needed for ndarrays of dimension 2 and more
              (*vals,) = v
          else:
              # not unstacking. Needed because otherwise pandas casts types
              # the way it wants, like converting a list of float32 scalats
              # to a column of float64
              vals = v
          col_mapping[k] = vals
      return pd.DataFrame.from_dict(col_mapping)
  
file_path: ludwig/ludwig/utils/dataframe_utils.py
imports: from typing import Dict, List, Optional, Tuple
  import numpy
  import pandas
  from ludwig.api_annotations import DeveloperAPI
  from ludwig.constants import DASK_MODULE_NAME
  from ludwig.data.dataframe.base import DataFrameEngine
  from ludwig.utils.types import DataFrame
label_desc: Use image node_id 7 for calling a global function with example usage: from_numpy_dataset(dataset) and returns: pd