075f154b507e7b87384ccd0956566e6af37417a0,examples/reading_comprehension/utils.py,,create_squad_training,#Any#Any#Any#Any#Any#,69

Before Change


    
    f_para = open(paras_file)
    f_ques = open(ques_file)
    f_ans = open(answer_file)
    f_vocab = open(vocab_file)
    para_list = []
    ques_list = []
    ans_list = []
    vocab_list = []
    for ele in f_para:
        para_list.append(list(map(int, ele.strip().split())))
    for ele in f_ques:
        ques_list.append(list(map(int, ele.strip().split())))

    for ele in f_ans:
        ans_list.append(list(map(int, ele.strip().split())))

    for ele in f_vocab:
        vocab_list.append(ele.strip().split())

    data_train = []

After Change


        for ele in f_ques:
            ques_list.append(list(map(int, ele.strip().split())))

    with open(answer_file) as f_ans:
        for ele in f_ans:
            ans_list.append(list(map(int, ele.strip().split())))

    with open(vocab_file) as f_vocab:
        for ele in f_vocab:
            vocab_list.append(ele.strip().split())
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 8

Instances


Project Name: NervanaSystems/nlp-architect
Commit Name: 075f154b507e7b87384ccd0956566e6af37417a0
Time: 2018-05-15
Author: 32893314+danielkorat@users.noreply.github.com
File Name: examples/reading_comprehension/utils.py
Class Name:
Method Name: create_squad_training


Project Name: NervanaSystems/nlp-architect
Commit Name: 5bb1355742085384c4c5ccbbd9a774b06e774e32
Time: 2018-07-18
Author: sharath.nittur.sridhar@intel.com
File Name: examples/reading_comprehension/utils.py
Class Name:
Method Name: create_squad_training


Project Name: NervanaSystems/nlp-architect
Commit Name: 4b674552c6755a5b154927b0cf86aa4812729ec4
Time: 2018-05-14
Author: daniel.korat@intel.com
File Name: examples/most_common_word_sense/prepare_data.py
Class Name:
Method Name: read_inference_input_examples_file