code: def _add_edge_keys(G, betweenness, weight=None):
      r"""Adds the corrected betweenness centrality (BC) values for multigraphs.
  
      Parameters
      ----------
      G : NetworkX graph.
  
      betweenness : dictionary
          Dictionary mapping adjacent node tuples to betweenness centrality values.
  
      weight : string or function
          See `_weight_function` for details. Defaults to `None`.
  
      Returns
      -------
      edges : dictionary
          The parameter `betweenness` including edges with keys and their
          betweenness centrality values.
  
      The BC value is divided among edges of equal weight.
      """
      _weight = _weight_function(G, weight)
  
      edge_bc = dict.fromkeys(G.edges, 0.0)
      for u, v in betweenness:
          d = G[u][v]
          wt = _weight(u, v, d)
          keys = [k for k in d if _weight(u, v, {k: d[k]}) == wt]
          bc = betweenness[(u, v)] / len(keys)
          for k in keys:
              edge_bc[(u, v, k)] = bc
  
      return edge_bc
  
file_path: networkx/networkx/algorithms/centrality/betweenness.py
imports: from collections import deque
  from heapq import heappop, heappush
  from itertools import count
  import networkx
  from networkx.algorithms.shortest_paths.weighted import _weight_function
  from networkx.utils import py_random_state
  from networkx.utils.decorators import not_implemented_for
label_desc: Use image node_id 10 for calling a global function with example usage: _add_edge_keys(G, betweenness, weight) and returns: edge_bc