@@ -231,10 +231,10 @@ def test_stratified_shuffle_split_iter_no_indices():
231231 y = np .asarray ([0 , 1 , 2 ] * 10 )
232232
233233 sss1 = cval .StratifiedShuffleSplit (y , indices = False , random_state = 0 )
234- train_mask , test_mask = iter (sss1 ). next ( )
234+ train_mask , test_mask = next ( iter (sss1 ))
235235
236236 sss2 = cval .StratifiedShuffleSplit (y , indices = True , random_state = 0 )
237- train_indices , test_indices = iter (sss2 ). next ( )
237+ train_indices , test_indices = next ( iter (sss2 ))
238238
239239 assert_array_equal (sorted (test_indices ), np .where (test_mask )[0 ])
240240
@@ -482,7 +482,7 @@ def test_cross_val_generator_mask_indices_same():
482482 # indices=True and when indices=False
483483 y = np .array ([0 , 0 , 0 , 1 , 1 , 1 , 1 , 1 , 1 , 2 , 2 , 2 , 2 , 2 , 2 ])
484484 labels = np .array ([1 , 1 , 2 , 3 , 3 , 3 , 4 ])
485-
485+
486486 loo_mask = cval .LeaveOneOut (5 , indices = False )
487487 loo_ind = cval .LeaveOneOut (5 , indices = True )
488488 lpo_mask = cval .LeavePOut (10 , 2 , indices = False )
@@ -495,7 +495,7 @@ def test_cross_val_generator_mask_indices_same():
495495 lolo_ind = cval .LeaveOneLabelOut (labels , indices = True )
496496 lopo_mask = cval .LeavePLabelOut (labels , 2 , indices = False )
497497 lopo_ind = cval .LeavePLabelOut (labels , 2 , indices = True )
498-
498+
499499 for cv_mask , cv_ind in [(loo_mask , loo_ind ), (lpo_mask , lpo_ind ),
500500 (kf_mask , kf_ind ), (skf_mask , skf_ind ), (lolo_mask , lolo_ind ),
501501 (lopo_mask , lopo_ind )]:
0 commit comments