

def test_average_pooling(self):
    input_data = theano.shared(asfloat(np.array([[1, 2, 3, (- 1)], [4, (- 6), 3, 1], [0, 0, 1, 0], [0, (- 1), 0, 0]])))
    expected_output = asfloat(np.array([[(1 / 4.0), (6 / 4.0)], [((- 1) / 4.0), (1 / 4.0)]]))
    average_pool_layer = layers.AveragePooling((2, 2))
    actual_output = average_pool_layer.output(average_pool_layer).eval()
    np.testing.assert_array_almost_equal(actual_output, expected_output)

dataset/ETHPy150Open itdxer/neupy/tests/layers/test_conv_layers.py ConvLayersTestCase.test_average_pooling/VarMisuse@138/162 `input_data`->`average_pool_layer`