@@ -108,7 +108,7 @@ def test_g123_gwss_with_default_sites(fixture, api: AnophelesG123Analysis):
108
108
g123_params = dict (
109
109
contig = random .choice (api .contigs ),
110
110
sample_sets = [random .choice (all_sample_sets )],
111
- window_size = random . randint (100 , 500 ),
111
+ window_size = rng . integers (100 , 500 ),
112
112
min_cohort_size = 10 ,
113
113
)
114
114
@@ -124,7 +124,7 @@ def test_g123_gwss_with_phased_sites(fixture, api: AnophelesG123Analysis):
124
124
contig = random .choice (api .contigs ),
125
125
sites = random .choice (api .phasing_analysis_ids ),
126
126
sample_sets = [random .choice (all_sample_sets )],
127
- window_size = random . randint (100 , 500 ),
127
+ window_size = rng . integers (100 , 500 ),
128
128
min_cohort_size = 10 ,
129
129
)
130
130
@@ -141,7 +141,7 @@ def test_g123_gwss_with_segregating_sites(fixture, api: AnophelesG123Analysis):
141
141
sites = "segregating" ,
142
142
site_mask = random .choice (api .site_mask_ids ),
143
143
sample_sets = [random .choice (all_sample_sets )],
144
- window_size = random . randint (100 , 500 ),
144
+ window_size = rng . integers (100 , 500 ),
145
145
min_cohort_size = 10 ,
146
146
)
147
147
@@ -158,7 +158,7 @@ def test_g123_gwss_with_all_sites(fixture, api: AnophelesG123Analysis):
158
158
sites = "all" ,
159
159
site_mask = None ,
160
160
sample_sets = [random .choice (all_sample_sets )],
161
- window_size = random . randint (100 , 500 ),
161
+ window_size = rng . integers (100 , 500 ),
162
162
min_cohort_size = 10 ,
163
163
)
164
164
@@ -173,7 +173,7 @@ def test_g123_gwss_with_bad_sites(fixture, api: AnophelesG123Analysis):
173
173
g123_params = dict (
174
174
contig = random .choice (api .contigs ),
175
175
sample_sets = [random .choice (all_sample_sets )],
176
- window_size = random . randint (100 , 500 ),
176
+ window_size = rng . integers (100 , 500 ),
177
177
min_cohort_size = 10 ,
178
178
sites = "foobar" ,
179
179
)
@@ -187,8 +187,8 @@ def test_g123_gwss_with_bad_sites(fixture, api: AnophelesG123Analysis):
187
187
def test_g123_calibration (fixture , api : AnophelesG123Analysis ):
188
188
# Set up test parameters.
189
189
all_sample_sets = api .sample_sets ()["sample_set" ].to_list ()
190
- window_sizes = rng .integers (100 , 500 , size = random . randint (2 , 5 )).tolist ()
191
- window_sizes = sorted ([ int (x ) for x in window_sizes ] )
190
+ window_sizes = rng .integers (100 , 500 , size = rng . integers (2 , 5 )).tolist ()
191
+ window_sizes = sorted (int (window_sizes ) )
192
192
g123_params = dict (
193
193
contig = rng .choice (api .contigs ),
194
194
sites = rng .choice (api .phasing_analysis_ids ),
0 commit comments