6fe058037c6126c5806c34debf86b3cf302219be,basic/model.py,,bi_attention,#Any#Any#Any#Any#Any#Any#Any#Any#,17

Before Change


    :return: [N, M, d], [N, M, JX, d]
    
    with tf.variable_scope(scope or "bi_attention"):
        N, M, JX, JQ, d = config.batch_size, config.max_num_sents, config.max_sent_size, config.max_ques_size, config.hidden_size
        JX = tf.shape(h)[2]
        M = tf.shape(h)[1]
        JQ = tf.shape(u)[1]

After Change



        if tensor_dict is not None:
            a_u = tf.nn.softmax(u_logits)  // [N, M, JX, JQ]
            a_h = tf.nn.softmax(tf.reduce_max(u_logits, 3))
            tensor_dict["a_u"] = a_u
            tensor_dict["a_h"] = a_h

        return u_a, h_a

Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: wenwei202/iss-rnns
Commit Name: 6fe058037c6126c5806c34debf86b3cf302219be
Time: 2016-11-01
Author: seominjoon@gmail.com
File Name: basic/model.py
Class Name:
Method Name: bi_attention


Project Name: dpressel/mead-baseline
Commit Name: 509453992838a524f6442d4e0f07a034390ae1f7
Time: 2020-02-13
Author: dpressel@gmail.com
File Name: layers/eight_mile/tf/layers.py
Class Name: BiLSTMEncoderAll1
Method Name: call


Project Name: NVIDIA/OpenSeq2Seq
Commit Name: 6313ad3830b5fc05926168eeb5faea1afe8e19f3
Time: 2018-06-20
Author: jasoli@nvidia.com
File Name: open_seq2seq/decoders/tacotron2_decoder.py
Class Name: Tacotron2Decoder
Method Name: _decode