<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def rank_clusters(cluster_dict):
 """ Helper function for clustering that takes a dictionary mapping cluster ids to lists of the binary strings that are part of that cluster and returns a dictionary mapping cluster ids to integers representing their "rank". Ranks provide an ordering for the clusters such that each cluster has its own rank, and clusters are ordered from simplest to most complex. """

    # Figure out the relative rank of each cluster
    cluster_ranks = dict.fromkeys(cluster_dict.keys())
    for key in cluster_dict:
        cluster_ranks[key] = eval(string_avg(cluster_dict[key], binary=True))

    i = len(cluster_ranks)
    for key in sorted(cluster_ranks, key=cluster_ranks.get):
        cluster_ranks[key] = i
        i -= 1

    return cluster_ranks