@not_implemented_for('directed')
def efficiency(G, u, v):
    return 1 / nx.shortest_path_length(G, u, v)
Returns the efficiency of a pair of nodes in a graph.
dataset/ETHPy150Open networkx/networkx/networkx/algorithms/efficiency.py/efficiency