Issue with seed, Random and 51.4.0 #458
pkernevez
started this conversation in
General, ojAlgo and related code
Replies: 2 comments 3 replies
-
It's simple to reproduce with this test: @Test
void simpleTestFailing() {
// Given
Normal normal = new Normal();
// When... failed
normal.setSeed(1L);
} |
Beta Was this translation helpful? Give feedback.
1 reply
-
Do you need a ticket ? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi all,
In the version 51.4.0 the implementation of the class RandomNumber changed.
It now uses a instance of ThreadLocalRandom.
In our application we have test using a random Matrix.
To have a reproducible test we set the seed with the following code:
When moving from 51.3.0 to 51.4.0 this code is now failing:
The exception is failing because the new used implementation doesn't support to set the seed:
And the new delegation in RandomNumber
v51.3.0...v51.4.0#diff-017663c363e942692c4ab7d4c26e6b514d4a0c35dbe20480b6c82902b69d4431
How can we set a seed with the new implementation ?
Regards,
Beta Was this translation helpful? Give feedback.
All reactions