17e2f1fe95e21369e67af90977613b3f0ce82f00,theanolm/commands/score.py,,_score_utterances,#Any#Any#Any#Any#Any#,155

Before Change


    num_unks = 0
    for line_num, line in enumerate(input_file):
        words = line.split()
        if words[0] != "<s>":
            words.insert(0, "<s>")
        if words[-1] != "</s>":
            words.append("</s>")

        word_ids = dictionary.words_to_ids(words)

After Change


    num_unks = 0
    for line_num, line in enumerate(input_file):
        words = utterance_from_line(line)
        if len(words) == 0:
            continue

        word_ids = dictionary.words_to_ids(words)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: senarvi/theanolm
Commit Name: 17e2f1fe95e21369e67af90977613b3f0ce82f00
Time: 2015-11-25
Author: seppo.git@marjaniemi.com
File Name: theanolm/commands/score.py
Class Name:
Method Name: _score_utterances


Project Name: mil-tokyo/webdnn
Commit Name: 76e11372587646d49fc5948814d2694ba53cb476
Time: 2017-06-29
Author: y.kikura@gmail.com
File Name: src/graph_transpiler/webdnn/graph/traverse.py
Class Name:
Method Name: listup_nodes


Project Name: cmu-db/ottertune
Commit Name: 21971e673fabe25d3e7da6712f80222760516113
Time: 2020-02-26
Author: bohanzhang95@gmail.com
File Name: server/website/website/tasks/async_tasks.py
Class Name:
Method Name: clean_metric_data