code: def _export_vertex_dataframe(graph):
      """Export vertices with attributes to pandas.DataFrame
  
      If you want to use vertex names as index, you can do:
  
      >>> from string import ascii_letters
      >>> graph = Graph.GRG(25, 0.4)
      >>> graph.vs["name"] = ascii_letters[:graph.vcount()]
      >>> df = graph.get_vertex_dataframe()
      >>> df.set_index('name', inplace=True)
  
      @return: a pandas.DataFrame representing vertices and their attributes.
        The index uses vertex IDs, from 0 to N - 1 where N is the number of
        vertices.
      """
      try:
          import pandas as pd
      except ImportError:
          raise ImportError(
              "You should install pandas in order to use this function"
          ) from None
  
      df = pd.DataFrame(
          {attr: graph.vs[attr] for attr in graph.vertex_attributes()},
          index=list(range(graph.vcount())),
      )
      df.index.name = "vertex ID"
  
      return df
  
file_path: python-igraph/src/igraph/io/objects.py
imports: from typing import Union, Sequence
  from collections import defaultdict
  from itertools import repeat
  from warnings import warn
  from igraph.datatypes import UniqueIdGenerator
label_desc: Use image node_id 10 for calling a global function with example usage: _export_vertex_dataframe(graph) and returns: df