code: def _func_name(func, cls=None):
      """Get the name."""
      parts = []
      if cls is not None:
          module = inspect.getmodule(cls)
      else:
          module = inspect.getmodule(func)
      if module:
          parts.append(module.__name__)
      if cls is not None:
          parts.append(cls.__name__)
      parts.append(func.__name__)
      return ".".join(parts)
  
file_path: vispy/vispy/util/tests/test_docstring_parameters.py
imports: import re
  import inspect
  import pytest
  import vispy.scene.cameras.magnify
  from vispy.testing import run_tests_if_main, requires_numpydoc
label_desc: Use image node_id 1 for calling a global function with example usage: _func_name(func, cls) and returns: str