56e6adb2773497506875c7cbd7a1fe6b5c59fb4c,tests/layer/test_gcn.py,,test_GraphConvolution_dense,#,60

Before Change


    // Check for errors with batch size != 1
    // We need to specify the batch shape as one for the GraphConvolutional logic to work
    x_t = Input(batch_shape=(2,) + features.shape)
    output_indices_t = Input(batch_shape=(2, None), dtype="int32")
    with pytest.raises(ValueError):
        out = GraphConvolution(2)([x_t, A_t, output_indices_t])

After Change



    // batch dimension > 1 should work with a dense matrix
    x_t = Input(batch_shape=(10,) + features.shape)
    A_t = Input(batch_shape=(10, 3, 3))
    input_data = [np.broadcast_to(x, x_t.shape), np.broadcast_to(adj, A_t.shape)]

    out = GraphConvolution(2)([x_t, A_t])
    model = keras.Model(inputs=[x_t, A_t], outputs=out)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: stellargraph/stellargraph
Commit Name: 56e6adb2773497506875c7cbd7a1fe6b5c59fb4c
Time: 2020-04-19
Author: Huon.Wilson@data61.csiro.au
File Name: tests/layer/test_gcn.py
Class Name:
Method Name: test_GraphConvolution_dense


Project Name: tensorflow/transform
Commit Name: f73cdc286a3e125cf7019336621cb10370ebfd52
Time: 2019-04-25
Author: askerryryan@google.com
File Name: tensorflow_transform/tf_utils.py
Class Name:
Method Name: _reduce_vocabulary_inputs


Project Name: pfnet-research/chainer-chemistry
Commit Name: 327ffc711693f1d0fe9ef6c40f086a33a9231019
Time: 2018-08-19
Author: mottodora@gmail.com
File Name: chainer_chemistry/models/gat.py
Class Name: GraphAttentionNetworks
Method Name: update