Skip to content

Commit

Permalink
Lint NPY002
Browse files Browse the repository at this point in the history
  • Loading branch information
Smartappli authored Jul 3, 2024
1 parent f281e10 commit 6d4e2b4
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/syft/tests/syft/code_verification_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,15 @@
@pytest.fixture
def data1() -> ActionObject:
"""Returns an Action Object with a NumPy dataset with values between -1 and 1"""
yield NumpyArrayObject.from_obj(2 * np.random.rand(10, 10) - 1)
rng = np.random.default_rng()
yield NumpyArrayObject.from_obj(2 * rng.random((10, 10)) - 1)


@pytest.fixture
def data2() -> ActionObject:
"""Returns an Action Object with a NumPy dataset with values between -1 and 1"""
yield NumpyArrayObject.from_obj(2 * np.random.rand(10, 10) - 1)
rng = np.random.default_rng()
yield NumpyArrayObject.from_obj(2 * rng.random((10, 10)) - 1)


@pytest.fixture
Expand Down

0 comments on commit 6d4e2b4

Please sign in to comment.