DiningSystem commited on
Commit
5cd9952
1 Parent(s): 1ede7ab

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -6,7 +6,8 @@ import os
6
  hf.login(token=os.environ['model_token'])
7
  #remember to login with token before loading model
8
  def text_to_hair(prompt, num_inference_steps=200, guidance_scale=9, model_path ="CVH-vn1210/hair-model"):
9
- pipe = StableDiffusionPipeline.from_pretrained("stabilityai/stable-diffusion-2", torch_dtype=torch.float16)
 
10
  pipe.unet.load_attn_procs(model_path)
11
  pipe.to("cuda")
12
  image = pipe(prompt, num_inference_steps=num_inference_steps, guidance_scale=8).images[0]
 
6
  hf.login(token=os.environ['model_token'])
7
  #remember to login with token before loading model
8
  def text_to_hair(prompt, num_inference_steps=200, guidance_scale=9, model_path ="CVH-vn1210/hair-model"):
9
+
10
+ pipe = StableDiffusionPipeline.from_pretrained(os.environ['bmd'], torch_dtype=torch.float16)
11
  pipe.unet.load_attn_procs(model_path)
12
  pipe.to("cuda")
13
  image = pipe(prompt, num_inference_steps=num_inference_steps, guidance_scale=8).images[0]