From 6c6a34dd2144def8b210b9e50554d60244a9bc9d Mon Sep 17 00:00:00 2001 From: mrq Date: Mon, 7 Apr 2025 23:13:35 -0500 Subject: [PATCH] i can't be assed to test if the prior commit works so being explicit like this should help until i can be bothered to halt training just to test this --- vall_e/models/base_v2.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/vall_e/models/base_v2.py b/vall_e/models/base_v2.py index d848b1c..c5e9759 100644 --- a/vall_e/models/base_v2.py +++ b/vall_e/models/base_v2.py @@ -147,9 +147,8 @@ class FiniteAudioEncoder(nn.Module): else: x = self.proj( x ) - weights = self.level_weights.float() - weights = F.softmax(weights, dim=0).view(1, -1, 1) - x = (x * weights).sum(dim=1).to(xi.dtype) + weights = F.softmax(self.level_weights.float(), dim=0).view(1, -1, 1) + x = (x.float() * weights).sum(dim=1).to(xi.dtype) return x