Skip to content

Commit

Permalink
fix default seed
Browse files Browse the repository at this point in the history
  • Loading branch information
galipremsagar committed Oct 12, 2024
1 parent 7087da9 commit 3d35be1
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion python/cudf/cudf/_fuzz_testing/avro.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ def write_data(self, file_name):

def set_rand_params(self, params):
params_dict = {}
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
for param, values in params.items():
if values == ALL_POSSIBLE_VALUES:
if param == "columns":
Expand Down
4 changes: 2 additions & 2 deletions python/cudf/cudf/_fuzz_testing/csv.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def write_data(self, file_name):

def set_rand_params(self, params):
params_dict = {}
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
for param, values in params.items():
if values == ALL_POSSIBLE_VALUES:
if param == "usecols":
Expand Down Expand Up @@ -179,7 +179,7 @@ def write_data(self, file_name):

def set_rand_params(self, params):
params_dict = {}
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
for param, values in params.items():
if values == ALL_POSSIBLE_VALUES:
if param == "columns":
Expand Down
2 changes: 1 addition & 1 deletion python/cudf/cudf/_fuzz_testing/io.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def get_next_regression_params(self):
return dtypes_meta, num_rows, num_cols, seed

def set_rand_params(self, params):
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
params_dict = {
param: rng.choice(values) for param, values in params.items()
}
Expand Down
4 changes: 2 additions & 2 deletions python/cudf/cudf/_fuzz_testing/json.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def write_data(self, file_name):

def set_rand_params(self, params):
params_dict = {}
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
for param, values in params.items():
if param == "dtype" and values == ALL_POSSIBLE_VALUES:
dtype_val = rng.choice(
Expand Down Expand Up @@ -181,7 +181,7 @@ def write_data(self, file_name):

def set_rand_params(self, params):
params_dict = {}
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
for param, values in params.items():
if param == "dtype" and values == ALL_POSSIBLE_VALUES:
dtype_val = rng.choice(
Expand Down
2 changes: 1 addition & 1 deletion python/cudf/cudf/_fuzz_testing/orc.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ def write_data(self, file_name):

def set_rand_params(self, params):
params_dict = {}
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
for param, values in params.items():
if values == ALL_POSSIBLE_VALUES:
if param == "columns":
Expand Down
2 changes: 1 addition & 1 deletion python/cudf/cudf/_fuzz_testing/parquet.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def write_data(self, file_name):

def set_rand_params(self, params):
params_dict = {}
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
for param, values in params.items():
if param == "columns" and values == ALL_POSSIBLE_VALUES:
col_size = self._rand(len(self._df.columns))
Expand Down
2 changes: 1 addition & 1 deletion python/cudf/cudf/tests/test_column.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
@pytest.fixture(params=dtypes, ids=dtypes)
def pandas_input(request):
dtype = request.param
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
size = 100

def random_ints(dtype, size):
Expand Down
2 changes: 1 addition & 1 deletion python/dask_cudf/dask_cudf/tests/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@


def _make_random_frame(nelem, npartitions=2, include_na=False):
rng = np.random.default_rng()
rng = np.random.default_rng(seed=None)
df = pd.DataFrame(
{"x": rng.random(size=nelem), "y": rng.random(size=nelem)}
)
Expand Down

0 comments on commit 3d35be1

Please sign in to comment.