From 1822c5c908d46b76573df2069653081e31058796 Mon Sep 17 00:00:00 2001 From: "lyuxiang.lx" Date: Mon, 19 Jan 2026 10:48:24 +0800 Subject: [PATCH] fix fm train bug --- cosyvoice/flow/flow_matching.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cosyvoice/flow/flow_matching.py b/cosyvoice/flow/flow_matching.py index a45337a..d3beb9e 100644 --- a/cosyvoice/flow/flow_matching.py +++ b/cosyvoice/flow/flow_matching.py @@ -174,8 +174,7 @@ class ConditionalCFM(BASECFM): # random timestep t = torch.rand([b, 1, 1], device=mu.device, dtype=mu.dtype) - if self.t_scheduler == 'cosine': - t = 1 - torch.cos(t * 0.5 * torch.pi) + # sample noise p(x_0) z = torch.randn_like(x1)