mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-08-04 11:12:35 +00:00
switched the token counter to use hidden buttons instead of api call
This commit is contained in:
@@ -273,8 +273,7 @@ class StableDiffusionModelHijack:
|
||||
def tokenize(self, text):
|
||||
max_length = self.clip.max_length - 2
|
||||
_, remade_batch_tokens, _, _, _, token_count = self.clip.process_text([text])
|
||||
return {"tokens": remade_batch_tokens[0], "token_count":token_count, "max_length":max_length}
|
||||
|
||||
return remade_batch_tokens[0], token_count, max_length
|
||||
|
||||
class FrozenCLIPEmbedderWithCustomWords(torch.nn.Module):
|
||||
def __init__(self, wrapped, hijack):
|
||||
|
Reference in New Issue
Block a user