Commit 7be52df7 rédigé par withal's avatar withal
Parcourir les fichiers

Refactor CountingProbDist:

 * Use weighted_sampler() for the sampling.
 * By not using a defaultdict, keep n_obs always up to date.
 * Don't inherit from ProbDist, at least for now, since we don't
   use anything from the superclass, and if we did it would break
   (e.g. __setitem__).
 * Remove __len__ since nobody uses it.
 * Use heapq.nlargest.

Also separate random doctests from others, and tweak docs.
parent 2cf81dcb
Prend en charge le Markdown
0% ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message !
Veuillez vous inscrire ou vous pour commenter