Deal with deprecations in python networkx 3.1.
edge_betweenness() became edge_betweenness_centrality(), and is_string_like() became isinstance(obj, str).
edge_betweenness() became edge_betweenness_centrality(), and is_string_like() became isinstance(obj, str).