From 476dc3f30c014e0d2ebdc46ce0283ddbfe63eeb8 Mon Sep 17 00:00:00 2001 From: VirtuosoQ <2416050435@qq.com> Date: 星期日, 28 四月 2024 16:37:54 +0800 Subject: [PATCH] 16:37 java_http_client --- funasr/models/rwkv_bat/rwkv_attention.py | 15 ++++++--------- 1 files changed, 6 insertions(+), 9 deletions(-) diff --git a/funasr/models/rwkv_bat/rwkv_attention.py b/funasr/models/rwkv_bat/rwkv_attention.py index 5384fb9..c085874 100644 --- a/funasr/models/rwkv_bat/rwkv_attention.py +++ b/funasr/models/rwkv_bat/rwkv_attention.py @@ -1,17 +1,14 @@ -"""Attention (time mixing) modules for RWKV block. - -Based/Modified from https://github.com/BlinkDL/RWKV-LM/blob/main/RWKV-v4/src/model.py. - -Some variables are renamed according to https://github.com/huggingface/transformers/blob/main/src/transformers/models/rwkv/modeling_rwkv.py. - -""" # noqa +#!/usr/bin/env python3 +# -*- encoding: utf-8 -*- +# Copyright FunASR (https://github.com/alibaba-damo-academy/FunASR). All Rights Reserved. +# MIT License (https://opensource.org/licenses/MIT) import math -from importlib.util import find_spec +import torch from pathlib import Path +from importlib.util import find_spec from typing import List, Optional, Tuple, Union -import torch wkv_kernel_encoder = None wkv_kernel_decoder = None -- Gitblit v1.9.1