Remove bucket iterator shuffle warning.
* Remove bucket iterator shuffle warning.
From discussion here: Let me know if I should remove the code instead of commenting it.
* Remove the warning and add comment instead.
* Add a period.
@@ -126,10 +126,9 @@ class BucketIterator(DataIterator):
last_batch = batches.pop()
penultimate_batch = batches.pop()
if shuffle:
+ # NOTE: if shuffle is false, the data will still be in a different order
+ # because of the bucket sorting.
random.shuffle(batches)
- else:
- logger.warning("shuffle parameter is set to False,"
- " while bucket iterators by definition change the order of your data.")
if move_to_front:
batches.insert(0, penultimate_batch)
batches.insert(0, last_batch)
