Skip to content
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

Remove GeneralRandom class #2239

Merged
merged 3 commits into from Jun 15, 2019
Merged

Remove GeneralRandom class #2239

merged 3 commits into from Jun 15, 2019

Conversation

@adonath
Copy link
Member

@adonath adonath commented Jun 15, 2019

This PR removes the GeneralRandom class and replaces its use by the new InverseCDFSampler. It adapts the tests in gammapy/astro/population/tests/test_simulate.py. The InverseCDFSampler uses sorting of the PDF values, prior to the computation of the CDF. For this reason the test results changed.

@adonath adonath self-assigned this Jun 15, 2019
@adonath adonath added this to the 0.13 milestone Jun 15, 2019
@adonath adonath merged commit 697fa5c into gammapy:master Jun 15, 2019
9 checks passed
@cdeil
Copy link
Member

@cdeil cdeil commented Jun 16, 2019

Does draw have a unit test that executes it once? Could you please add one?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants