From 089636424b41c638aa09972eecded254d4fc1b22 Mon Sep 17 00:00:00 2001 From: ChasonJiang <46401978+ChasonJiang@users.noreply.github.com> Date: Fri, 16 Aug 2024 16:26:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=BE=E5=BC=83=E4=BA=86=E5=9C=A8t2s?= =?UTF-8?q?=E6=A8=A1=E5=9E=8B=E4=B8=AD=E4=BD=BF=E7=94=A8@torch.jit.script?= =?UTF-8?q?=EF=BC=8C=E7=A1=AE=E4=BF=9Dpytorch=E7=8E=AF=E5=A2=83=E4=B9=8B?= =?UTF-8?q?=E9=97=B4=E7=9A=84=E5=85=BC=E5=AE=B9=E6=80=A7=20(#1488)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- GPT_SoVITS/AR/models/t2s_model.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/GPT_SoVITS/AR/models/t2s_model.py b/GPT_SoVITS/AR/models/t2s_model.py index cb952e6..56dca94 100644 --- a/GPT_SoVITS/AR/models/t2s_model.py +++ b/GPT_SoVITS/AR/models/t2s_model.py @@ -39,7 +39,7 @@ default_config = { "EOS": 1024, } -@torch.jit.script +# @torch.jit.script # Efficient implementation equivalent to the following: def scaled_dot_product_attention(query:torch.Tensor, key:torch.Tensor, value:torch.Tensor, attn_mask:Optional[torch.Tensor]=None, scale:Optional[torch.Tensor]=None) -> torch.Tensor: B, H, L, S =query.size(0), query.size(1), query.size(-2), key.size(-2) @@ -82,7 +82,7 @@ class T2SMLP: return x -@torch.jit.script +# @torch.jit.script class T2SBlock: def __init__( self, @@ -218,7 +218,7 @@ class T2SBlock: return x, k_cache, v_cache -@torch.jit.script +# @torch.jit.script class T2STransformer: def __init__(self, num_blocks : int, blocks: List[T2SBlock]): self.num_blocks : int = num_blocks