Commit f6074f6
committed
Implemented suggestion #10
```
In [1]: import mkl_random
In [2]: rs = mkl_random.RandomState(1234, brng='NONDETERM')
In [3]: rs
Out[3]: <mkl_random.mklrand.RandomState at 0x2ba18d58faf0>
In [4]: rs.get_state()
Out[4]:
('NON_DETERMINISTIC',
b'\x02RNG\x14\x00\x00\x00\x08\x00\x00\x00\x00\x00\x00\x00\x00\x00\xe0\x00\x00\x00\x00\x00\n\x00\x00\x00')
In [6]: rs.seed(126) # brng has not been reset
In [7]: rs.get_state()
Out[7]:
('NON_DETERMINISTIC',
b'\x02RNG\x14\x00\x00\x00\x08\x00\x00\x00\x00\x00\x00\x00\x00\x00\xe0\x00\x00\x00\x00\x00\n\x00\x00\x00')
In [8]: rs.seed(1234, brng='MT2203')
In [9]: rs.get_state()
Out[9]:
('MT2203',
b"\x02RNG\x14\x00\x00\x00(\x01\x00\x00\x00\x00\x00\x00\x00\x00\x90\x00\x00\x00\x00\x80i\xc0w\xa7\x0eF\xd8L\xfbi\rk\xd6[\t\x80F\xa0\xae\xa2as3\x9eQ\xd5f\x9b\x95>\xb9\x0f\xf5\xbe\xb0p\xe7o\xf
e\xe22\xc3\xad\x80D?\xe3X\x14\x86(D\xed(\xb1\xeb\xc6\xc5\xae\x00\xf8m,@\xd8\xd2\xd2\x98\x8b\xe74\x16\xd6\x07\xe3\xa9\x94q\xe5\xf1\xe1\xd8\x94\xf6\xf3\x8e8z\xddYrMym\xd9\x9a\xf1\x1e\xa8v\x97\
x1a\xcdvY\x82\xe9\x086!\xc8\x8db\xe5<\x1aH\xac&\x1c\xf8\x87\xc3\xefm\xc6\x17q\xb9\xda\xdcw\xcd.\xffI!3\xe8\x8e\xd5\x89\x19=\xca\x94\x88\xb2e|\xe5\xa0\xf0\xe3\xe5\xea\x0f\xd7K\xd4\xf4\xe2\x17
_\x1e\x89\x8f\xe7\x9dp\xa8}B\xa22l\x1c\xed\xedvtu6\xf3up\xc2W\xa8\xd9\xcf\xb59\r\xa6@\xce\xc7\x7f\xc2\x05[\xed\xd4y:h&\x8b\xe4\xc9\xcc\xa6\xf9\x07'\xa8g4\xd7\t\x07\xcf#\x94\xe8%\xa6\xa1\xcd\
xc1nd\xcc\x92\x80n\xe1i\x8a\xdc\x0b\x0e|\xc1[\xe2QWX\x98\xc6\x9f\x08\xe3\x1e\x00 W\xd6\xf7\x9c+\x11\xfa\xee\xbf\nH\xe6nmE\x00\x00\x00_\x05\x81\xaf\x80\xef~\xdd\x00\x80\xd7\xef\x08\x01\x0c\x0
2")
```1 parent 762619c commit f6074f6
File tree
5 files changed
+43
-17
lines changed- mkl_random
- src
5 files changed
+43
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | 27 | | |
31 | 28 | | |
32 | 29 | | |
| |||
38 | 35 | | |
39 | 36 | | |
40 | 37 | | |
| 38 | + | |
41 | 39 | | |
42 | 40 | | |
43 | 41 | | |
| |||
83 | 81 | | |
84 | 82 | | |
85 | 83 | | |
| 84 | + | |
86 | 85 | | |
87 | 86 | | |
88 | 87 | | |
| |||
181 | 180 | | |
182 | 181 | | |
183 | 182 | | |
184 | | - | |
185 | | - | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
186 | 186 | | |
187 | 187 | | |
188 | 188 | | |
| |||
888 | 888 | | |
889 | 889 | | |
890 | 890 | | |
891 | | - | |
| 891 | + | |
892 | 892 | | |
893 | 893 | | |
894 | 894 | | |
895 | 895 | | |
896 | 896 | | |
897 | 897 | | |
898 | 898 | | |
899 | | - | |
| 899 | + | |
900 | 900 | | |
901 | 901 | | |
902 | 902 | | |
| |||
946 | 946 | | |
947 | 947 | | |
948 | 948 | | |
949 | | - | |
| 949 | + | |
950 | 950 | | |
951 | 951 | | |
952 | 952 | | |
| |||
1008 | 1008 | | |
1009 | 1009 | | |
1010 | 1010 | | |
1011 | | - | |
| 1011 | + | |
1012 | 1012 | | |
1013 | | - | |
| 1013 | + | |
1014 | 1014 | | |
1015 | 1015 | | |
1016 | 1016 | | |
| |||
1023 | 1023 | | |
1024 | 1024 | | |
1025 | 1025 | | |
1026 | | - | |
| 1026 | + | |
1027 | 1027 | | |
1028 | | - | |
| 1028 | + | |
| 1029 | + | |
1029 | 1030 | | |
1030 | 1031 | | |
1031 | 1032 | | |
| |||
1041 | 1042 | | |
1042 | 1043 | | |
1043 | 1044 | | |
1044 | | - | |
| 1045 | + | |
| 1046 | + | |
| 1047 | + | |
| 1048 | + | |
1045 | 1049 | | |
1046 | 1050 | | |
1047 | 1051 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
133 | 133 | | |
134 | 134 | | |
135 | 135 | | |
136 | | - | |
137 | | - | |
138 | 136 | | |
139 | 137 | | |
140 | 138 | | |
| |||
150 | 148 | | |
151 | 149 | | |
152 | 150 | | |
| 151 | + | |
| 152 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
145 | 145 | | |
146 | 146 | | |
147 | 147 | | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
148 | 169 | | |
149 | 170 | | |
150 | 171 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
| 100 | + | |
100 | 101 | | |
101 | 102 | | |
102 | 103 | | |
| |||
0 commit comments