Change total_words count from an iteration over all vocab items to a simple addition.  This speeds things up a lot when processing billions of total words.