-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
π DocsImprovements or additions to documentationImprovements or additions to documentation
Description
As a follow-up to #1, it would be cool to have a small example of hit-and-miss (accept-reject) sampling in Python (NumPy). I think the two examples that @H178561 worked out are nice:
-
$\sqrt{1-x^2}$ , where you know the maximum is just 1, and you can apply a uniform sampling strategy. - Some function where (ideally) you do not know what the maximum is, so that you have to use a smart strategy to find that maximum numerically as you are sampling.
It's a bit hard to come up with a simple example where it is hard to find the maximum, but you can also just take two Gaussians and pretend that you don't know the maximum. The idea is the same.
Metadata
Metadata
Assignees
Labels
π DocsImprovements or additions to documentationImprovements or additions to documentation