code: def make_rev_dict_unique(cdict):
      
      rev_dict = {}
      for k, v in cdict.items():
          if k in rev_dict:
              rev_dict[k][k] = True
          else:
              rev_dict[k] = {k: True}
          for vv in v.keys():
              if vv in rev_dict:
                  rev_dict[vv][k] = True
              else:
                  rev_dict[vv] = {k: True}
      return rev_dict
docs: Make a reverse dictionary
  
      Parameters
      ----------
      in_dict : dict(int:dict(int:True))    
         A dictionary of clusters.  Each cluster is a source index and
         the dictionary of other sources in the cluster.
  
      Returns
      -------
      rev_dict : dict(int:dict(int:True))    
         A dictionary pointing from source index to the clusters it is
         included in.