From cb698ff1fb2d6d55470fece8abf886a927afe72c Mon Sep 17 00:00:00 2001 From: Ryan Dick Date: Fri, 15 Dec 2023 17:56:49 -0500 Subject: [PATCH] Update model_probe to work with diffuser-format SD TI embeddings. --- invokeai/backend/model_management/model_probe.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/invokeai/backend/model_management/model_probe.py b/invokeai/backend/model_management/model_probe.py index f0af93294f..d312c6a0b4 100644 --- a/invokeai/backend/model_management/model_probe.py +++ b/invokeai/backend/model_management/model_probe.py @@ -389,7 +389,7 @@ class TextualInversionCheckpointProbe(CheckpointProbeBase): elif "clip_g" in checkpoint: token_dim = checkpoint["clip_g"].shape[-1] else: - token_dim = list(checkpoint.values())[0].shape[0] + token_dim = list(checkpoint.values())[0].shape[-1] if token_dim == 768: return BaseModelType.StableDiffusion1 elif token_dim == 1024: