def get_degree_equivalents(seeds, bins, g):

    """
    Get other nodes that match degree as seed
    Adapted from https://github.com/emreg00/toolbox
    Args:
        seeds (list): nodes
        bins (list): bins containing nodes with similar degree
        g (nx.Graph): graph object
    """

    seed_to_nodes = {}
    for seed in seeds:
        d = g.degree(seed)
        for l, h, nodes in bins:
            if l <= d and h >= d:
               mod_nodes = list(nodes)
               mod_nodes.remove(seed)
               seed_to_nodes[seed] = mod_nodes
               break
    return seed_to_nodes