From 372f66c1a8b37b1b55487aaef2bec3d151e2e99f Mon Sep 17 00:00:00 2001 From: FrenchKrab Date: Fri, 18 Mar 2022 09:59:29 +0100 Subject: [PATCH] fix devastating TeacherUpdate mess up (exclusive to branches develop2/3) --- pyannote/audio/tasks/segmentation/unsupervised_segmentation.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pyannote/audio/tasks/segmentation/unsupervised_segmentation.py b/pyannote/audio/tasks/segmentation/unsupervised_segmentation.py index f8ef2d541..65805e548 100644 --- a/pyannote/audio/tasks/segmentation/unsupervised_segmentation.py +++ b/pyannote/audio/tasks/segmentation/unsupervised_segmentation.py @@ -218,6 +218,7 @@ def __init__( def enqueue_teacher(self, teacher: OrderedDict[str, torch.Tensor]): if len(self.last_weights) >= self.average_of: + self.last_weights.pop(0) self.last_weights.append(teacher) def get_updated_weights(