Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compute_pz_b #23

Open
markoarnauto opened this issue Dec 3, 2018 · 1 comment
Open

compute_pz_b #23

markoarnauto opened this issue Dec 3, 2018 · 1 comment

Comments

@markoarnauto
Copy link

markoarnauto commented Dec 3, 2018

First of all, thanks for providing such a great library! The code really helps to understand the paper.
But I am still wondering why the topic probability distribution P(z|B) for the oBTM seems different from the paper?

The paper states that:
bildschirmfoto 2018-12-03 um 14 20 41

But the actual calculation goes:

pw1k = (nwz[k][w1] + beta[k][w1]) / (2 * nb_z[k] + beta_sum[k]);
pw2k = (nwz[k][w2] + beta[k][w2]) / (2 * nb_z[k] + 1 + beta_sum[k]);
pz[k] = (nb_z[k] + alpha[k]) * pw1k * pw2k;

What did I miss?

@sebinsuresh
Copy link

Did you ever figure this issue out?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants