code: def count(tex):
      
  
      # soupify
      soup = TexSoup(tex)
  
      # extract all unique labels
      labels = set(label.string for label in soup.find_all('label'))
  
      # create dictionary mapping label to number of references
      return dict((label, soup.find_all('\ref{%s}' % label)) for label in labels)
docs: Extract all labels, then count the number of times each is referenced in
      the provided file. Does not follow \includes.