From fce4e1d1b48f23cd8332e60afce3df8d6209a6a7 Mon Sep 17 00:00:00 2001 From: gaochangfeng <54253717+gaochangfeng@users.noreply.github.com> Date: 星期四, 11 四月 2024 14:59:22 +0800 Subject: [PATCH] SenseVoice对富文本解码的参数 (#1608) --- funasr/models/ct_transformer_streaming/attention.py | 18 +++--------------- 1 files changed, 3 insertions(+), 15 deletions(-) diff --git a/funasr/models/ct_transformer_streaming/attention.py b/funasr/models/ct_transformer_streaming/attention.py index 382334e..3177eca 100644 --- a/funasr/models/ct_transformer_streaming/attention.py +++ b/funasr/models/ct_transformer_streaming/attention.py @@ -1,22 +1,10 @@ #!/usr/bin/env python3 -# -*- coding: utf-8 -*- +# -*- encoding: utf-8 -*- +# Copyright FunASR (https://github.com/alibaba-damo-academy/FunASR). All Rights Reserved. +# MIT License (https://opensource.org/licenses/MIT) -# Copyright 2019 Shigeki Karita -# Apache 2.0 (http://www.apache.org/licenses/LICENSE-2.0) - -"""Multi-Head Attention layer definition.""" - -import math - -import numpy import torch -from torch import nn -import torch.nn.functional as F -from typing import Optional, Tuple - from funasr.models.sanm.attention import MultiHeadedAttentionSANM - - class MultiHeadedAttentionSANMwithMask(MultiHeadedAttentionSANM): -- Gitblit v1.9.1