code: def clean_internal_figure_properties(fig):
      """
      Remove all HoloViews internal properties (those with leading underscores) from the
      input figure.
  
      Note: This function mutates the input figure
  
      Parameters
      ----------
      fig: dict
          The figure dictionary to process.
      """
      fig_props = list(fig)
      for prop in fig_props:
          val = fig[prop]
          if prop.startswith("_"):
              fig.pop(prop)
          elif isinstance(val, dict):
              clean_internal_figure_properties(val)
          elif (
              isinstance(val, (list, tuple))
              and val
              and isinstance(val[0], dict)
          ):
              for el in val:
                  clean_internal_figure_properties(el)
  
file_path: holoviews/holoviews/plotting/plotly/util.py
imports: import copy
  import re
  import numpy
  from plotly import colors
  from ...core.util import isfinite, max_range
  from ..util import color_intervals, process_cmap
label_desc: Use image node_id 14 for calling a global function with example usage: clean_internal_figure_properties(fig) without return types