(self)
| 969 | class TestGradient: |
| 970 | |
| 971 | def test_basic(self): |
| 972 | v = [[1, 1], [3, 4]] |
| 973 | x = np.array(v) |
| 974 | dx = [np.array([[2., 3.], [2., 3.]]), |
| 975 | np.array([[0., 0.], [1., 1.]])] |
| 976 | assert_array_equal(gradient(x), dx) |
| 977 | assert_array_equal(gradient(v), dx) |
| 978 | |
| 979 | def test_args(self): |
| 980 | dx = np.cumsum(np.ones(5)) |
nothing calls this directly
no test coverage detected