diff --git a/spacy/cli/train.py b/spacy/cli/train.py index f3f0649e9..6fbb44d65 100644 --- a/spacy/cli/train.py +++ b/spacy/cli/train.py @@ -320,6 +320,7 @@ def create_train_batches(nlp, corpus, cfg): yield epoch, batch if max_epochs >= 1 and epoch >= max_epochs: break + random.shuffle(train_examples) def create_evaluation_callback(nlp, optimizer, corpus, cfg):