Closed 143f86b6-91b7-47e4-808b-18779e22f2dd closed 2 years ago
This is documented in the README already:
You can see that pww_load_tools
takes a hf_model_path
and/or local_model_path
here:
pww_load_tools
is called by paint_with_words
, which can also be passed hf_model_path
and/or local_model_path
, with hf_model_path
defaulting to "CompVis/stable-diffusion-v1-4"
So it looks like it may be even easier than the README suggests, and you should just be able to pass "runwayml/stable-diffusion-v1-5"
directly into the hf_model_path
parameter of paint_with_words
as it's called in the 'Basic Usage' section:
Something like this would presumably work:
img = paint_with_words(
color_context=color_context,
color_map_image=color_map_image,
input_prompt=input_prompt,
num_inference_steps=30,
guidance_scale=7.5,
device="cuda:0",
+ hf_model_path="runwayml/stable-diffusion-v1-5"
)
I made a simple colab example just now, you can try it out here: paint-with-words colab
Originally posted by @shreydan in https://github.com/cloneofsimo/paint-with-words-sd/issues/4#issuecomment-1312768401
You can confirm the above hf_model_path
change on the colab mentioned here by editing the cell that has the img = paint_with_words(
(first cell after the 'Run Model' heading)
We can also explicitly set the seed
parameter here as well, to make comparisons between the 2 models easier.
You can see that
pww_load_tools
takes ahf_model_path
and/orlocal_model_path
here:
One advantage of this method that you can also change the scheduler, which might be desirable for performance or quality issues. (I found recently that the model I'm using often has blatant graphical issues even with a large step count on LMS, but EulerAncestralDiscreteScheduler or EulerDiscreteScheduler do much better. Just don't forget to import your scheduler of choice from diffusers. (Something the example currently doesn't show.)
Nice note @hiss-remi , ill add this feature as well.
Is it possible to use this in v1.5 instead of v1.4?