From bb1b8ceaa8de08809e56db4e866890410c30a882 Mon Sep 17 00:00:00 2001 From: Lincoln Stein Date: Wed, 16 Aug 2023 08:48:44 -0400 Subject: [PATCH] Update invokeai/backend/model_management/model_cache.py Co-authored-by: StAlKeR7779 --- invokeai/backend/model_management/model_cache.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/invokeai/backend/model_management/model_cache.py b/invokeai/backend/model_management/model_cache.py index e83fd68102..a11e0a8a8f 100644 --- a/invokeai/backend/model_management/model_cache.py +++ b/invokeai/backend/model_management/model_cache.py @@ -226,7 +226,7 @@ class ModelCache(object): self.stats.high_watermark = max(self.stats.high_watermark, self._cache_size()) self.stats.in_cache = len(self._cached_models) self.stats.loaded_model_sizes[key] = max( - self.stats.loaded_model_sizes.get("key", 0), model_info.get_size(submodel) + self.stats.loaded_model_sizes.get(key, 0), model_info.get_size(submodel) ) with suppress(Exception):