public int getValueId ( Clusterable c ) { currentItems ++ ; /* * if(isLeafNode()) { return id; } */ int index = TreeUtils . findNearestNodeIndex ( subNodes , c ) ; if ( index >= 0 ) { KMeansTreeNode node = subNodes . get ( index ) ; return node . getValueId ( c ) ; } return id ; }
Adds a clusterable to the current vocab tree for word creation