code: def _convert_col_names_to_str(data):
      """
      Convert column names to string.
      """
      # There's no generic way to rename columns across tabular object types.
      # `columns` could refer to anything else on the object, e.g. a dim
      # on an xarray DataArray. So this may need to be stricter.
      if not hasattr(data, "columns") or not hasattr(data, "rename"):
          return data
      renamed = {
          c: str(c)
          for c in data.columns
          if not isinstance(c, str) and isinstance(c, Hashable)
      }
      if renamed:
          data = data.rename(columns=renamed)
      return data
  
imports: import sys
  from collections.abc import Hashable
  from functools import wraps
  from packaging.version import Version
  from types import FunctionType
  import bokeh
  import numpy
  import pandas
  import param
  import holoviews
label_desc: Use image node_id 27 for calling a global function with example usage: _convert_col_names_to_str(data) and returns: data, data