mirror of
https://github.com/explosion/spaCy.git
synced 2024-12-26 18:06:29 +03:00
Fix per-epoch shuffling
This commit is contained in:
parent
d525552979
commit
8c5a88e777
|
@ -320,6 +320,7 @@ def create_train_batches(nlp, corpus, cfg):
|
||||||
yield epoch, batch
|
yield epoch, batch
|
||||||
if max_epochs >= 1 and epoch >= max_epochs:
|
if max_epochs >= 1 and epoch >= max_epochs:
|
||||||
break
|
break
|
||||||
|
random.shuffle(train_examples)
|
||||||
|
|
||||||
|
|
||||||
def create_evaluation_callback(nlp, optimizer, corpus, cfg):
|
def create_evaluation_callback(nlp, optimizer, corpus, cfg):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user