clear-cache on model unload

Signed-off-by: Vladimir Mandic <mandic00@live.com>
This commit is contained in:
Vladimir Mandic
2025-05-07 20:22:27 -04:00
parent b6d2aa7fd8
commit 8433f685e7
2 changed files with 6 additions and 3 deletions
+1
View File
@@ -1086,6 +1086,7 @@ def clear_caches():
def unload_model_weights(op='model'):
clear_caches()
if shared.compiled_model_state is not None:
shared.compiled_model_state.compiled_cache.clear()
shared.compiled_model_state.req_cache.clear()