code: def _dfi_contains_categorical_data(dfi: Any) -> bool:
      CATEGORICAL_DTYPE = 23
      return any(
          c.dtype[0] == CATEGORICAL_DTYPE for c in dfi.get_columns()
      )
  
file_path: polars/py-polars/polars/interchange/from_dataframe.py
imports: from __future__ import annotations
  from typing import TYPE_CHECKING, Any
  import polars._reexport
  from polars.convert import from_arrow
  from polars.dependencies import _PYARROW_AVAILABLE
  from polars.dependencies import pyarrow
  from polars.interchange.dataframe import PolarsDataFrame
  from polars.utils.various import parse_version
label_desc: Use image node_id 4 for calling a global function with example usage: _dfi_contains_categorical_data(dfi) and returns: any