arnim / HDP

Gibbs sampler 4 the Hierarchical Dirichlet Process
GNU Lesser General Public License v3.0
36 stars 21 forks source link

Fix a bug: tableToTopic mapping should be invalidated, rather than decreased. #7

Open intfloat opened 9 years ago

intfloat commented 9 years ago

When removing an existing table, the mapping relation between table and topic should be invalidated, rather than being decreased as in line 207(HDPGibbsSampler.java).

This is a potential bug, though currently it doesn't affect the correctness of your code as you use DOCState.wordCountByTable to do defragment in line 351, better to fix it.