Skip to content

Commit

Permalink
Merge pull request #71 from kohya-ss/dev
Browse files Browse the repository at this point in the history
Fix negative prompt not working when token>75
  • Loading branch information
kohya-ss authored Jan 15, 2023
2 parents 60e5793 + 48110bc commit c2c1261
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gen_img_diffusers.py
Original file line number Diff line number Diff line change
Expand Up @@ -705,7 +705,7 @@ def __call__(
if negative_scale is not None:
_, real_uncond_embeddings, _ = get_weighted_text_embeddings(
pipe=self,
prompt=[""]*batch_size,
prompt=prompt, # こちらのトークン長に合わせてuncondを作るので75トークン超で必須
uncond_prompt=[""]*batch_size,
max_embeddings_multiples=max_embeddings_multiples,
clip_skip=self.clip_skip,
Expand Down

0 comments on commit c2c1261

Please sign in to comment.