[ 
https://issues.apache.org/jira/browse/MAHOUT-676?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13040750#comment-13040750
 ] 

Ted Dunning commented on MAHOUT-676:
------------------------------------

This is a bit of an odd use of a slice sampler.

Normally slice samplers are used in the sense that Radford Neal proposed in his 
2003 (I think) paper.  That is,
they are used to sample from a distribution that is contained in R^n and were 
you know the PDF times a possibly
unknown constant.  The simplest case is the univariate case where you start 
with some x in the domain of the 
distribution, sample y ~ Uniform[0, p(x)] and then sample uniformly from X = {x 
st p(x) < y}.  For unimodel p, this
is very nice.

For sampling from a finite set the sampling from X involves some kind of search 
which makes slice sampling not much
better than other fast multinomial samples.  For instance, you can build a 
Huffman or arithmetic encoder for the 
different symbols to be sampled.  Then you just decode random bits until you 
have a unique result.  This gives you
log(n) speed for sampling.  Similarly (and effectively the same), you can use 
bisection until you get a unique result.

What is the need being satisfied here?

> Random samplers in a modular library
> ------------------------------------
>
>                 Key: MAHOUT-676
>                 URL: https://issues.apache.org/jira/browse/MAHOUT-676
>             Project: Mahout
>          Issue Type: New Feature
>          Components: Math
>            Reporter: Lance Norskog
>            Priority: Minor
>         Attachments: MAHOUT-676.patch, Sampler.patch
>
>
> This is a modular suite of samplers.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to