popsynth.utils.rejection_sample module

popsynth.utils.rejection_sample.rejection_sample(size, ymax, xmax, func)[source]

Rejection sample func up to ymax and xmax.

Parameters:
  • size – Number of samples
  • ymax – Maximum value of y
  • xmax – Maximum value of x
  • func – Function