multimodalart HF staff commited on
Commit
c53e4d0
1 Parent(s): c126311

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -2
app.py CHANGED
@@ -50,7 +50,6 @@ def update_selection(evt: gr.SelectData):
50
  @spaces.GPU(duration=80)
51
  def generate_image(prompt, trigger_word, steps, seed, cfg_scale, width, height, lora_scale, progress):
52
  pipe.to("cuda")
53
-
54
  generator = torch.Generator(device="cuda").manual_seed(seed)
55
 
56
  with calculateDuration("Generating image"):
@@ -75,7 +74,7 @@ def run_lora(prompt, cfg_scale, steps, selected_index, randomize_seed, seed, wid
75
  trigger_word = selected_lora["trigger_word"]
76
 
77
  # Load LoRA weights
78
- with calculateDuration(f"Loading LoRA weights for {selected_lora}"):
79
  if "weights" in selected_lora:
80
  pipe.load_lora_weights(lora_path, weight_name=selected_lora["weights"])
81
  else:
 
50
  @spaces.GPU(duration=80)
51
  def generate_image(prompt, trigger_word, steps, seed, cfg_scale, width, height, lora_scale, progress):
52
  pipe.to("cuda")
 
53
  generator = torch.Generator(device="cuda").manual_seed(seed)
54
 
55
  with calculateDuration("Generating image"):
 
74
  trigger_word = selected_lora["trigger_word"]
75
 
76
  # Load LoRA weights
77
+ with calculateDuration(f"Loading LoRA weights for {selected_lora["title"]}"):
78
  if "weights" in selected_lora:
79
  pipe.load_lora_weights(lora_path, weight_name=selected_lora["weights"])
80
  else: