mirror of
https://github.com/PaddlePaddle/FastDeploy.git
synced 2025-12-24 13:28:13 +08:00
bug: fix list to List (#4818)
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
|
||||
import copy
|
||||
from dataclasses import dataclass
|
||||
from typing import list
|
||||
from typing import List
|
||||
|
||||
from typing_extensions import Self
|
||||
|
||||
@@ -33,11 +33,11 @@ class KVCacheSpec:
|
||||
block_memory_used: int
|
||||
|
||||
@classmethod
|
||||
def merge(cls, specs: list[Self]) -> Self:
|
||||
def merge(cls, specs: List[Self]) -> Self:
|
||||
"""
|
||||
Merge a list of KVCacheSpec objects into a single KVCacheSpec object.
|
||||
Merge a List of KVCacheSpec objects into a single KVCacheSpec object.
|
||||
"""
|
||||
# check list
|
||||
# check List
|
||||
assert all(
|
||||
(spec.block_size == specs[0].block_size and spec.block_memory_used == specs[0].block_memory_used)
|
||||
for spec in specs[1:]
|
||||
|
||||
Reference in New Issue
Block a user