Shivdutta commited on
Commit
629cda4
·
verified ·
1 Parent(s): 1ba38b9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -376,6 +376,7 @@ def blue_loss_variant(images, use_mean=False, alpha=1.0):
376
 
377
  return loss
378
 
 
379
  def generate_with_prompt_style_guidance(prompt, style, seed,num_inference_steps,guidance_scale,loss_function):
380
 
381
  prompt = prompt + ' in style of s'
@@ -386,7 +387,7 @@ def generate_with_prompt_style_guidance(prompt, style, seed,num_inference_steps,
386
  width = 512 # default width of Stable Diffusion
387
  num_inference_steps = num_inference_steps # # Number of denoising steps
388
  guidance_scale = guidance_scale # # Scale for classifier-free guidance
389
- generator = torch.manual_seed(seed) # Seed generator to create the inital latent noise
390
  batch_size = 1
391
 
392
 
 
376
 
377
  return loss
378
 
379
+ @spaces.GPU
380
  def generate_with_prompt_style_guidance(prompt, style, seed,num_inference_steps,guidance_scale,loss_function):
381
 
382
  prompt = prompt + ' in style of s'
 
387
  width = 512 # default width of Stable Diffusion
388
  num_inference_steps = num_inference_steps # # Number of denoising steps
389
  guidance_scale = guidance_scale # # Scale for classifier-free guidance
390
+ generator = torch.manual_seed(seed) # Seed generator to create the initial latent noise
391
  batch_size = 1
392
 
393