Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
LatentDirichletAllocation perplexity method broken in version 0.18.1 #7954
The perplexity method of the LatentDirichletAllocation class appears to have broken during the transition from scikit-learn 0.17.1 to 0.18.1. The values returned by the method are no longer consistent with the values printed during training iterations (verbose=1, evaluate_every=1).
Steps/Code to Reproduce
Gist with reproducible example can be found here: https://gist.github.com/garyForeman/321a10ebe29215a0c1acbcb4b320fb8e
Final perplexity printed during training should equal the value returned by the perplexity method when passed the training data.
Results when using 0.17.1:
Results when using 0.18.1: