diff --git a/prepare_data.py b/prepare_data.py index 7dd5216..9132711 100644 --- a/prepare_data.py +++ b/prepare_data.py @@ -1500,7 +1500,8 @@ class Data: new_predictions = np.zeros(predictions.shape, dtype='float32') for i in range(len(predictions)): word_len = self.count_syllables(words[i][0], vowels) - + if word_len > 10: + word_len = 10 for k in range(word_len): new_predictions[i][k] += predictions[i][word_len - 1 - k] diff --git a/sloleks_accentuation2.py b/sloleks_accentuation2.py index d038c8b..89277a3 100644 --- a/sloleks_accentuation2.py +++ b/sloleks_accentuation2.py @@ -47,7 +47,7 @@ print('Commencing accentuator!') rate = 100000 start_timer = time.time() with open("data/new_sloleks/new_sloleks.tab", "a") as myfile: - for index in range(0, len(new_content), rate): + for index in range(300000, len(new_content), rate): if index+rate >= len(new_content): words = [[el[0], '', el[2], el[0]] for el in new_content][index:len(new_content)] else: