Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If the keyword is long "Needed to truncate input" A phrase appears. is this normal? #108

Open
inhyoe opened this issue Jan 19, 2023 · 5 comments

Comments

@inhyoe
Copy link

inhyoe commented Jan 19, 2023

when i use prompt like that " swift run StableDiffusionSample --resource-path models/coreml-stable-diffusion-v1-4_original_compiled --compute-units all "personification of Halloween holiday in the form of a cute girl with short hair and a villain's smile, cute hats, cute cheeks, unreal engine, highly detailed, artgerm digital illustration, woo tooth, studio ghibli, deviantart, sharp focus, artstation, by Alexei Vinogradov bakery, sweets, emerald eyes " "

the prompt appear " Needed to truncate input "

but However, the execution is normal, but the output is different from the suggested word.

is it normal??

And is there any way to rename the output?
The title appears as the name of the suggestion word of the result, but if the suggestion word is long, the name with the suggestion word truncated appears.

@l2gakuen
Copy link

yes,
(Stable Diffusion Infos Explained : https://github.com/Maks-s/sd-akashic#general-information-toc)
quote : Your prompt must be 75 tokens or less, anything above will result in "prompt truncated after tokenization"

anything higher is ignored, that's why the execution is normal, but the output is different from the suggested word.

@gavtron2000
Copy link

Automatic supports longer prompts. Is it possible to add this support to the repo? Apologies if this is a noob question! 😄

@jgranie
Copy link

jgranie commented Jun 19, 2023

'(' & ')' are counted as token, does it mean we can't weight a token this way (maybe it's a feature inherent to A1111), can someone confirm ?
Same as above, recent versions of A1111 allows more tokens, how did they achieve this ?

EDIT: Reply : huggingface/diffusers#2136

@jrittvo
Copy link

jrittvo commented Jun 19, 2023

The Apple implementation doesn't support token weigting like (this) or ((this)). It also has a hard coded limit. And some words count as more than 1 of the 75 tokens. ml-stable-diffusion has its own rules different from diffusers.

@NoahKamara
Copy link

Do you know if Apple's implementation supports weighting at all?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants