Update forge_clip.py

This commit is contained in:
lllyasviel
2024-01-25 06:51:38 -08:00
parent 8e36af0f06
commit e8d0736cb3

View File

@@ -2,7 +2,8 @@ from modules.sd_hijack_clip import FrozenCLIPEmbedderWithCustomWords
class CLIP_SD_15_L(FrozenCLIPEmbedderWithCustomWords):
pass
def encode_with_transformers(self, tokens):
return super().encode_with_transformers(tokens)
class CLIP_SD_21_G(FrozenCLIPEmbedderWithCustomWords):
@@ -13,6 +14,9 @@ class CLIP_SD_21_G(FrozenCLIPEmbedderWithCustomWords):
self.wrapped.layer = "hidden"
self.wrapped.layer_idx = -2
def encode_with_transformers(self, tokens):
return super().encode_with_transformers(tokens)
class CLIP_SD_XL_L(FrozenCLIPEmbedderWithCustomWords):
def __init__(self, wrapped, hijack):