public void Find3() { //Console.WriteLine("Szukanie tresomow"); Stopwatch sw = new Stopwatch(); sw.Start(); int postep = 0; int poprzednie = 0; int index = 0; foreach (Word w in words_3.Values) { if (poprzednie < postep) { //Console.Clear(); //Console.WriteLine("Ładowanie: " + postep + "%"); poprzednie++; } for (int i = 0; i < w.Fonems.Length; i++) { if (i + 2 < w.Fonems.Length) { Treesome temp = new Treesome(w, new string[] { w.Fonems[i], w.Fonems[i + 1], w.Fonems[i + 2] }); if (!treesome.Keys.Contains(temp.code)) { treesome.Add(temp.code, temp); } else { treesome[temp.code].AddWord(w); } } } if (index % (int)(words_3.Values.Count * 0.01) == 0) { postep += 1; } index++; } //Console.WriteLine(treesome.Values.First().code); sw.Stop(); //Console.WriteLine("Czas ładowania danych: {0}", sw.Elapsed); //Console.WriteLine(treesome.Select(t => t.Value).Where(t => t.words.Count<=1).ToList().Count); UnUsedtreesome = new Dictionary <string, Treesome>(treesome); }
private void MadeTrisomes() { TresomesKeys = Treesome.GetAllTresomeKeysFromWord(this).ToArray(); }