[issue18900] Add the random.distrib module

2013-09-07 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- stage: -> committed/rejected status: pending -> closed ___ Python tracker ___ ___ Python-bugs-list m

[issue18900] Add the random.distrib module

2013-09-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > In light of Raymond's comments on code bloat in issue18844, perhaps this > module could be added to PyPi to see whether or not there's interest in this > kind of functionality? Agree. At first look there are no module which provides such features on PyPI.

[issue18900] Add the random.distrib module

2013-09-01 Thread Madison May
Madison May added the comment: > ...we can turn current functions in the random module into wrappers > around generators from the distrib module. Makes sense. In light of Raymond's comments on code bloat in issue18844, perhaps this module could be added to PyPi to see whether or not there's i

[issue18900] Add the random.distrib module

2013-09-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Of course if this idea will be accepted we can turn current functions in the random module into wrappers around generators from the distrib module. E.g.: def triangular(self, *args, **kwargs): return next(triangular(*args, random=self, **kwargs))

[issue18900] Add the random.distrib module

2013-09-01 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +tim.peters ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue18900] Add the random.distrib module

2013-09-01 Thread Madison May
Madison May added the comment: I like the core idea of a family of random generators, but it feels like a new module that's nearly identical to random introduces a lot of repeated code. Perhaps adding an additional optional arg ('generator=False', for example) to these functions in the random

[issue18900] Add the random.distrib module

2013-09-01 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : Added file: http://bugs.python.org/file31550/distrib_bench.py ___ Python tracker ___ ___ Python-bugs-list mailin

[issue18900] Add the random.distrib module

2013-09-01 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: In some functions in the random module checking input arguments and precomputation takes a considerable portion of time. Here is a sample implementation of new random.distrib module which provides alternative faster interface to generating of random distri