code: def _community_optimal_modularity(graph, *args, **kwds):
      """Calculates the optimal modularity score of the graph and the
      corresponding community structure.
  
      This function uses the GNU Linear Programming Kit to solve a large
      integer optimization problem in order to find the optimal modularity
      score and the corresponding community structure, therefore it is
      unlikely to work for graphs larger than a few (less than a hundred)
      vertices. Consider using one of the heuristic approaches instead if
      you have such a large graph.
  
      @return: the calculated membership vector and the corresponding
        modularity in a tuple."""
      membership, modularity = GraphBase.community_optimal_modularity(
          graph, *args, **kwds
      )
      return VertexClustering(graph, membership, modularity)
  
file_path: python-igraph/src/igraph/community.py
imports: from igraph._igraph import GraphBase
  from igraph.clustering import VertexDendrogram, VertexClustering
  from igraph.utils import deprecated
  from typing import List, Sequence, Tuple
label_desc: Use image node_id 6 for calling a global function with example usage: _community_optimal_modularity(graph) and returns: VertexClustering