Пример #1
0
        private void Setup()
        {
            _alpha = _startingAlpha;

            _fileHandler.GetWordDictionaryFromFile(_wordCollection, MaxCodeLength);

            // TODO: refactor the huffman stuff, so we can use it elsewhere
            _wordCollection.RemoveWordsWithCountLessThanMinCount(_minCount);
            var huffmanTree = new HuffmanTree();

            huffmanTree.Create(_wordCollection);

            InitNetwork();

            if (_negativeSamples > 0)
            {
                InitUnigramTable();
            }

            GC.Collect();
        }