33[ ![ Travis Build Status] ( https://travis-ci.org/bashtage/ng-numpy-randomstate.svg?branch=master )] ( https://travis-ci.org/bashtage/ng-numpy-randomstate )
44[ ![ Appveyor Build Status] ( https://ci.appveyor.com/api/projects/status/odc5c4ukhru5xicl/branch/master?svg=true )] ( https://ci.appveyor.com/project/bashtage/ng-numpy-randomstate/branch/master )
55
6- This is a library and generic interface for alternative random generators
7- in Python and Numpy.
6+ This is a library and generic interface for alternative random
7+ generators in Python and Numpy.
88
99## Features
1010
@@ -30,22 +30,19 @@ import randomstate as rnd
3030w = rnd.standard_normal(10000 , method = ' zig' )
3131```
3232
33- * Preliminary support for 32-bit floating randoms for core generators.
34- Currently only uniforms (` random_sample ` ), exponentials
35- (` standard_exponential ` ) and normals (` standard_normal ` but only
36- using Box-Muller, so ` method='bm' ` is required) have been implemented.
37- Ultimately support should be avialable for:
38-
39- * Uniforms
40- * Exponentials
41- * Standard Gammas (via ` standard_gamma ` )
42- * Normals (currently only implemented using Box-Muller transformation)
33+ * Support for 32-bit floating randoms for core generators.
34+ Currently supported:
35+
36+ * Uniforms (` random_sample ` )
37+ * Exponentials (` standard_exponential ` )
38+ * Normals (` standard_normal ` , both Box-Muller and Ziggurat)
39+ * Standard Gammas (via ` standard_gamma ` )
4340
4441 ** WARNING** : The 32-bit generators are ** experimental** and subjust
4542 to change.
4643
47- ** Note** : There are no plans to extend the alternative precision generation to
48- all random number types.
44+ ** Note** : There are _ no _ plans to extend the alternative precision
45+ generation to all random number types.
4946
5047
5148
@@ -59,11 +56,14 @@ The RNGs include:
5956
6057* [ MT19937] ( https://github.com/numpy/numpy/blob/master/numpy/random/mtrand/ ) ,
6158 the NumPy rng
62- * [ dSFMT] ( http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/SFMT/ ) a SSE2-aware
63- version of the MT19937 generator that is especially fast at generating doubles
64- * [ xorshift128+] ( http://xorshift.di.unimi.it/ ) , [ xoroshiro128+] ( http://xoroshiro.di.unimi.it/ )
65- [ xorshift1024* ] ( http://xorshift.di.unimi.it/ )
66- * [ PCG32] ( http://www.pcg-random.org/ ) and [ PCG64] ( http:w//www.pcg-random.org/ )
59+ * [ dSFMT] ( http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/SFMT/ ) a
60+ SSE2-aware version of the MT19937 generator that is especially fast at
61+ generating doubles
62+ * [ xorshift128+] ( http://xorshift.di.unimi.it/ ) ,
63+ [ xoroshiro128+] ( http://xoroshiro.di.unimi.it/ ) and
64+ [ xorshift1024* ] ( http://xorshift.di.unimi.it/ )
65+ * [ PCG32] ( http://www.pcg-random.org/ ) and
66+ [ PCG64] ( http:w//www.pcg-random.org/ )
6767* [ MRG32K3A] ( http://simul.iro.umontreal.ca/rng )
6868* A multiplicative lagged fibonacci generator (LFG(63, 1279, 861, * ))
6969
@@ -75,8 +75,8 @@ support an additional `method` keyword argument which can be `bm` or
7575` zig ` where ` bm ` corresponds to the current method using the Box-Muller
7676transformation and ` zig ` uses the much faster (100%+) ziggurat method.
7777* ` random_sample ` can produce either single precision (` np.float32 ` ) or
78- double precision (` np.float64 ` , the default) using an the optional keyword
79- argument ` dtype ` .
78+ double precision (` np.float64 ` , the default) using an the optional
79+ keyword argument ` dtype ` .
8080
8181### New Functions
8282
@@ -93,9 +93,9 @@ the RNG._
9393
9494## Status
9595
96- * Complete drop-in replacement for ` numpy.random.RandomState ` . The ` mt19937 `
97- generator is identical to ` numpy.random.RandomState ` , and will produce an
98- identical sequence of random numbers for a given seed.
96+ * Complete drop-in replacement for ` numpy.random.RandomState ` . The
97+ ` mt19937 ` generator is identical to ` numpy.random.RandomState ` , and
98+ will produce an identical sequence of random numbers for a given seed.
9999* Builds and passes all tests on:
100100 * Linux 32/64 bit, Python 2.7, 3.4, 3.5 (should work on 2.6 and 3.3)
101101 * PC-BSD (FreeBSD) 64-bit, Python 2.7
@@ -133,13 +133,16 @@ Testing requires nose (1.3+).
133133** Note:** it might work with other versions but only tested with these
134134versions.
135135
136+ ## Development and Testing
137+
136138All development has been on 64-bit Linux, and it is regularly tested on
137- Travis-CI. The library is occasionally tested on Linux 32-bit, OSX 10.10,
138- PC-BSD 10.2 (should also work on Free BSD) and Windows (Python 2.7/3.5,
139- both 32 and 64-bit).
139+ Travis-CI. The library is occasionally tested on Linux 32-bit,
140+ OSX 10.10, PC-BSD 10.2 (should also work on Free BSD) and Windows
141+ (Python 2.7/3.5, both 32 and 64-bit).
140142
141- Basic tests are in place for all RNGs. The MT19937 is tested against NumPy's
142- implementation for identical results. It also passes NumPy's test suite.
143+ Basic tests are in place for all RNGs. The MT19937 is tested against
144+ NumPy's implementation for identical results. It also passes NumPy's
145+ test suite.
143146
144147## Installing
145148
@@ -179,8 +182,8 @@ rs = randomstate.prng.mt19937.RandomState()
179182rs.random_sample(100 )
180183```
181184
182- Like NumPy, ` randomstate ` also exposes a single instance of the ` mt19937 `
183- generator directly at the module level so that commands like
185+ Like NumPy, ` randomstate ` also exposes a single instance of the
186+ ` mt19937 ` generator directly at the module level so that commands like
184187
185188``` python
186189import randomstate
@@ -194,7 +197,8 @@ will work.
194197Standard NCSA, plus sub licenses for components.
195198
196199## Performance
197- Performance is promising, and even the mt19937 seems to be faster than NumPy's mt19937.
200+ Performance is promising, and even the mt19937 seems to be faster than
201+ NumPy's mt19937.
198202
199203```
200204Speed-up relative to NumPy (Uniform Doubles)
0 commit comments