()
| 401 | |
| 402 | |
| 403 | def test_scale_1d(): |
| 404 | # 1-d inputs |
| 405 | X_list = [1.0, 3.0, 5.0, 0.0] |
| 406 | X_arr = np.array(X_list) |
| 407 | |
| 408 | for X in [X_list, X_arr]: |
| 409 | X_scaled = scale(X) |
| 410 | assert_array_almost_equal(X_scaled.mean(), 0.0) |
| 411 | assert_array_almost_equal(X_scaled.std(), 1.0) |
| 412 | assert_array_equal(scale(X, with_mean=False, with_std=False), X) |
| 413 | |
| 414 | |
| 415 | @skip_if_32bit |
nothing calls this directly
no test coverage detected
searching dependent graphs…