Skip to content

Commit

Permalink
first make groups, then randomize on init
Browse files Browse the repository at this point in the history
  • Loading branch information
bw4sz committed Dec 6, 2018
1 parent 3530bc0 commit 0bab4b2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions keras_retinanet/preprocessing/generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,13 @@ def __init__(
self.preprocess_image = preprocess_image
self.config = config

#Define groups
self.group_images()

#Shuffle when initializing
if self.shuffle_groups:
self.on_epoch_end()

#Define groups
self.group_images()

def on_epoch_end(self):
random.shuffle(self.groups)

Expand Down

0 comments on commit 0bab4b2

Please sign in to comment.