mirror of
https://github.com/PaddlePaddle/FastDeploy.git
synced 2026-04-23 00:17:25 +08:00
[BugFix] fix cache transfer manager updating/clearing (#5930)
* [fix] fix cache transfer manager updating/clearing * [fix] fix code style * [fix] fix config * [fix] fix engine client * [fix] let worker update kv cache status signal * [fix] update worker process * [fix] fix clear/update for case if comm group is shutdown * [fix] update dynamic weight manager * [fix] fix port * [fix] add num_cpu_blocks arg for async_llm, and remove unnecessary waiting
This commit is contained in:
@@ -1335,6 +1335,7 @@ class CacheConfig:
|
||||
self.disable_chunked_mm_input = False
|
||||
self.kvcache_storage_backend = None
|
||||
self.write_policy = None
|
||||
self.num_cpu_blocks = None
|
||||
|
||||
for key, value in args.items():
|
||||
if hasattr(self, key):
|
||||
@@ -1380,10 +1381,12 @@ class CacheConfig:
|
||||
* byte_size
|
||||
)
|
||||
|
||||
if self.swap_space is None:
|
||||
self.num_cpu_blocks = 0
|
||||
else:
|
||||
self.num_cpu_blocks = int(self.swap_space * 1024**3 / self.bytes_per_block)
|
||||
if self.num_cpu_blocks is None:
|
||||
if self.swap_space is None:
|
||||
self.num_cpu_blocks = 0
|
||||
else:
|
||||
self.num_cpu_blocks = int(self.swap_space * 1024**3 / self.bytes_per_block)
|
||||
|
||||
self._verify_args()
|
||||
|
||||
def metrics_info(self):
|
||||
|
||||
Reference in New Issue
Block a user