-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create an RNG test suite #1391
Comments
This pairs well with #915, I think. It's not a hard dependency, but it would allow this to be a part of the standard (though not precommit) tests, since RNG goodness can become a metric tracked with the evolution of the codebase rather than a pass/fail. |
Agreed. At this point, I think the RNG's have two continuous metrics we can track over time:
|
Sketched out the type of thing we might do: https://github.com/johnmyleswhite/rng_tests.jl The Gamma and Exponential results seem broken. Not yet sure whether I'm doing the math wrong or whether there's a bug in their RNG's. |
Also see this: We should have a completely separate repository for all RNG testing that use external libraries. This can be hosted under juliaLang. The basic statistical tests that can be written as pure julia code for unit/sanity testing should certainly be in the julia tests. We also have the potential new issue of the collision test with randn(). |
Some comments: Julia's random normals passed all tests in Crush, so the Collision problem that Doornik wrote about didn't apply for my specific run. When I am back at work tomorrow I'll run the BigCrush with a new seed. The SmallCrush has a version that works for a file of random numbers. We could use that to test the different distribution generated within Julia. For example for the cases where the error is in the julia code and a pure C test does not apply. I guess this is the easiest and safest as the tests are standard and well tested. Also, I think it would be a good choice to use the Rmath cdfs to convert the numbers to uniformly distributed variables. They should be thoroughly tested. |
I think that https://github.com/andreasnoackjensen/RNGTest.jl/ sufficiently addresses this. |
We have come across several bugs in our RNG's lately:
randg()
was broken when the input parameter was1.0
, whilerandexp()
is broken without any input parameters. To verify the quality of RNG's, we need to set up a probabilistic test suite that will be very compute-intensive.At an abstract level, the suite will just contain null hypothesis tests. For example,
In practice, this can be broken into two parts:
This test suite cannot become part of the main tests, because occasionally failures will happen. We can minimize the chance of failures by using very large sample sizes, but that will require that the tests run for a long time.
The text was updated successfully, but these errors were encountered: