56aba98eb5d8e1402125fe36a92c48306e2a0322,pymc3/tests/test_quadpotential.py,,test_elemwise_velocity,#,24

Before Change


def test_elemwise_velocity():
    scaling = np.array([1, 2, 3])
    x_ = floatX(np.ones_like(scaling))
    x = tt.vector()
    x.tag.test_value = x_
    pot = quadpotential.quad_potential(scaling, True, False)
    v = theano.function([x], pot.velocity(x))
    assert np.allclose(v(x_), scaling)
    pot = quadpotential.quad_potential(scaling, True, True)
    v = theano.function([x], pot.velocity(x))
    assert np.allclose(v(x_), 1. / scaling)


def test_elemwise_energy():

After Change


    pot = quadpotential.quad_potential(scaling, True)
    v = pot.velocity(x)
    npt.assert_allclose(v, scaling)
    assert v.dtype == pot.dtype


def test_elemwise_energy():
    scaling = np.array([1, 2, 3])
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 12

Instances


Project Name: pymc-devs/pymc3
Commit Name: 56aba98eb5d8e1402125fe36a92c48306e2a0322
Time: 2017-07-19
Author: adrian.seyboldt@gmail.com
File Name: pymc3/tests/test_quadpotential.py
Class Name:
Method Name: test_elemwise_velocity


Project Name: pymc-devs/pymc3
Commit Name: 56aba98eb5d8e1402125fe36a92c48306e2a0322
Time: 2017-07-19
Author: adrian.seyboldt@gmail.com
File Name: pymc3/tests/test_quadpotential.py
Class Name:
Method Name: test_equal_diag


Project Name: pymc-devs/pymc3
Commit Name: 56aba98eb5d8e1402125fe36a92c48306e2a0322
Time: 2017-07-19
Author: adrian.seyboldt@gmail.com
File Name: pymc3/tests/test_quadpotential.py
Class Name:
Method Name: test_equal_dense


Project Name: pymc-devs/pymc3
Commit Name: 56aba98eb5d8e1402125fe36a92c48306e2a0322
Time: 2017-07-19
Author: adrian.seyboldt@gmail.com
File Name: pymc3/tests/test_quadpotential.py
Class Name:
Method Name: test_elemwise_velocity


Project Name: pymc-devs/pymc3
Commit Name: 56aba98eb5d8e1402125fe36a92c48306e2a0322
Time: 2017-07-19
Author: adrian.seyboldt@gmail.com
File Name: pymc3/tests/test_quadpotential.py
Class Name:
Method Name: test_elemwise_energy