[Numpy-discussion] Re: Arbitrarily large random integers

2023-08-19 Thread Robert Kern
On Sat, Aug 19, 2023 at 10:49 AM Kevin Sheppard wrote: > The easiest way to do this would to to write a pure python implementation > using Python ints of a masked integer sampler. This way you could draw > unsigned integers and then treat this as a bit pool. You would than take > the number of

[Numpy-discussion] Re: Arbitrarily large random integers

2023-08-19 Thread Kevin Sheppard
The easiest way to do this would to to write a pure python implementation using Python ints of a masked integer sampler. This way you could draw unsigned integers and then treat this as a bit pool. You would than take the number of bits needed for your integer, transform these to be a Python int,