word2vec: Change total_words count from a function to a count

This speeds things up a lot when processing billions of total words.  The function was getting called every 10,000 tokens and iterates over every vocabulary item.  This change provides an equivalent calculation without the iteration over the vocab.