a871536bcbb38b9ca03b0bc777712d8c0a79ad90,matchzoo/data_pack/pack.py,,pack,#Any#,17

Before Change


    df.fillna("missing")  // avoid tokenization exception.

    // Segment input into 3 dataframes.
    relation = df[col_relation]

    left = df[["id_left", "text_left"]].drop_duplicates(["id_left"])
    left.set_index("id_left", inplace=True)
    // Infer the length of the text left

After Change



    // Build Relation
    relation = pd.DataFrame(data={"id_left": id_left, "id_right": id_right})
    for col in df:
        if col not in ["id_left", "id_right", "text_left", "text_right"]:
            relation[col] = df[col]

    // Build Left and Right
    left = _merge(df, id_left, "text_left", "id_left")
    right = _merge(df, id_right, "text_right", "id_right")
    return matchzoo.DataPack(relation, left, right)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

Instances


Project Name: NTMC-Community/MatchZoo
Commit Name: a871536bcbb38b9ca03b0bc777712d8c0a79ad90
Time: 2018-12-13
Author: i@uduse.com
File Name: matchzoo/data_pack/pack.py
Class Name:
Method Name: pack


Project Name: AKSHAYUBHAT/DeepVideoAnalytics
Commit Name: 5cb2c457a72a0edd0b9b79508c2bdea02eea7fa8
Time: 2018-08-04
Author: akshayubhat@gmail.com
File Name: server/dvaui/views.py
Class Name: TEventList
Method Name: get_context_data


Project Name: keras-team/keras
Commit Name: 03a7eb89e27b70f2ca0ac932ef4bace7569d6fab
Time: 2017-02-13
Author: francois.chollet@gmail.com
File Name: keras/layers/advanced_activations.py
Class Name: PReLU
Method Name: build