diff options
author | tlatorre <tlatorre@uchicago.edu> | 2018-09-13 09:53:47 -0500 |
---|---|---|
committer | tlatorre <tlatorre@uchicago.edu> | 2018-09-13 09:53:47 -0500 |
commit | 8beebac19b9351cdc6108ea31eeda6531d75540b (patch) | |
tree | 977bb6bf8bac38d2c964b5f82a8c22c70a59b159 /src/misc.c | |
parent | fad85fa60a3b6b0e015ad070431f249f87cf77be (diff) | |
download | sddm-8beebac19b9351cdc6108ea31eeda6531d75540b.tar.gz sddm-8beebac19b9351cdc6108ea31eeda6531d75540b.tar.bz2 sddm-8beebac19b9351cdc6108ea31eeda6531d75540b.zip |
speed things up by introducing a minimum ratio between probabilities
Previously to avoid computing P(q,t|n)*P(n|mu) for large n when they were very
unlikely I was using a precomputed maximum n value based only on the expected
number of PE. However, this didn't take into account P(q|n).
This commit updates the likelihood function to dynamically decide when to quit
computing these probabilities when the probability for a given n divided by the
most likely probability is less than some threshold.
This threshold is currently set to 10**(-10) which means we quit calculating
these probabilities when the probability is 10 million times less likely than
the most probable value.
Diffstat (limited to 'src/misc.c')
0 files changed, 0 insertions, 0 deletions