public static Trial ReadTrialItems(TextAsset asset, bool logComments = true) { using (StreamReader reader = new StreamReader(asset.IntoMemoryStream())) { return(ReadTrialItems(reader, logComments)); } }
// Takes a frequency dictionary and the word/frequency separator and initializes it public void InitDictionary(TextAsset frequencyDict, char separator) { trie = new PruningRadixTrie(); using (Stream corpusStream = frequencyDict.IntoMemoryStream()) { trie.ReadTermsFromStream(corpusStream, separator); } Debug.LogWarning($"Trie Loaded! ({trie.termCountLoaded} nodes)"); }