Unverified Commit 29052c5d authored by Nikita Titov's avatar Nikita Titov Committed by GitHub
Browse files

[tests] fix deprecation numpy warning (#4439)

parent 26cc160a
...@@ -170,7 +170,7 @@ def test_sequence(tmpdir, sample_count, batch_size, include_0_and_nan, num_seq): ...@@ -170,7 +170,7 @@ def test_sequence(tmpdir, sample_count, batch_size, include_0_and_nan, num_seq):
# Test for validation set. # Test for validation set.
# Select some random rows as valid data. # Select some random rows as valid data.
rng = np.random.default_rng() # Pass integer to set seed when needed. rng = np.random.default_rng() # Pass integer to set seed when needed.
valid_idx = (rng.random(10) * nrow).astype(np.int) valid_idx = (rng.random(10) * nrow).astype(np.int32)
valid_data = data[valid_idx, :] valid_data = data[valid_idx, :]
valid_X = valid_data[:, :-1] valid_X = valid_data[:, :-1]
valid_Y = valid_data[:, -1] valid_Y = valid_data[:, -1]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment