3 ms·
Regarding special note 1: If you change the sizes of the segments so that they instead cover equal amounts of probability mass, then you'd be able to sample aga
by im3w1l 11y ago
Regarding special note 1: If you change the sizes of the segments so that they instead cover equal amounts of probability mass, then you'd be able to sample again from the same segment instead of starting over from the beginning.
But I guess this slows down the fast path a little, so with sufficiently low rejection probability it is not worth it.
- redcalx 11y agoYeh, I think there are probably a few different ways you could 'slice' up the body of the pdff. E.g. I mention using sloped ends to the segments to reduce the amount of pdf area outside of the segments, which would reduce the expensive path by a lot, but it also introduces a division into the fast path. Then again, that division is by a fixed value, so really it's a multiplication (by 1/x), so it might actually be a pretty good solution. It would be interesting to explore these options further.