kimpudding commited on
Commit
75aa8ae
ยท
verified ยท
1 Parent(s): 80d4f78

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -14,7 +14,7 @@ base_model_id = "runwayml/stable-diffusion-v1-5"
14
  lora_model_path = "./1211TeeniePing_Taesu-10.safetensors"
15
 
16
  # Stable Diffusion ํŒŒ์ดํ”„๋ผ์ธ ์ดˆ๊ธฐํ™”
17
- pipe = StableDiffusionPipeline.from_pretrained(model_id, torch_dtype=torch.float16)
18
  pipe = pipe.to("cuda")
19
 
20
  # LoRA ๊ฐ€์ค‘์น˜ ๋กœ๋“œ
@@ -23,7 +23,7 @@ def load_lora_weights(pipe, lora_path):
23
  pipe.unet.load_attn_procs(lora_state_dict)
24
 
25
  # LoRA ์ ์šฉ
26
- load_lora_weights(pipe, lora_path)
27
 
28
  # API ํ˜ธ์ถœ ํ•จ์ˆ˜ ์ •์˜
29
  def generate_response(user_prompt):
 
14
  lora_model_path = "./1211TeeniePing_Taesu-10.safetensors"
15
 
16
  # Stable Diffusion ํŒŒ์ดํ”„๋ผ์ธ ์ดˆ๊ธฐํ™”
17
+ pipe = StableDiffusionPipeline.from_pretrained(base_model_id, torch_dtype=torch.float16)
18
  pipe = pipe.to("cuda")
19
 
20
  # LoRA ๊ฐ€์ค‘์น˜ ๋กœ๋“œ
 
23
  pipe.unet.load_attn_procs(lora_state_dict)
24
 
25
  # LoRA ์ ์šฉ
26
+ load_lora_weights(pipe, lora_model_path)
27
 
28
  # API ํ˜ธ์ถœ ํ•จ์ˆ˜ ์ •์˜
29
  def generate_response(user_prompt):