()
| 8 | |
| 9 | |
| 10 | def test_fill_(): |
| 11 | x = tensor(np.zeros((2, 3, 4)), dtype=np.float32) |
| 12 | fill_(x, 5.0) |
| 13 | |
| 14 | np.testing.assert_array_equal( |
| 15 | x.numpy(), np.full(shape=(2, 3, 4), fill_value=5.0, dtype=np.float32) |
| 16 | ) |
| 17 | |
| 18 | |
| 19 | def test_calculate_fan_in_and_fan_out(): |