Spaces:
vilarin
/
Running on Zero

vilarin commited on
Commit
8401c4c
1 Parent(s): 6e49f50

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -3,7 +3,7 @@ import gradio as gr
3
  import torch
4
  import numpy as np
5
  import random
6
- from diffusers import StableDiffusion3Pipeline, AutoencoderKL, SD3Transformer2DModel, FlowMatchEulerDiscreteScheduler, StableDiffusion3Img2ImgPipeline
7
  import spaces
8
  from diffusers.utils import load_image
9
  from PIL import Image
@@ -66,8 +66,6 @@ if torch.cuda.is_available():
66
  pipe = StableDiffusion3Pipeline.from_pretrained(repo, vae=vae, transformer=transformer, tokenizer_3=tokenizer_3, text_encoder_3=text_encoder_3, torch_dtype=torch.float16).to("cuda")
67
  pipe2 = StableDiffusion3Img2ImgPipeline.from_pretrained(repo, vae=vae, transformer=transformer, tokenizer_3=tokenizer_3, text_encoder_3=text_encoder_3, torch_dtype=torch.float16).to("cuda")
68
 
69
- pipe.scheduler = FlowMatchEulerDiscreteScheduler.from_config(pipe.scheduler.config)
70
- pipe2.scheduler = FlowMatchEulerDiscreteScheduler.from_config(pipe.scheduler.config)
71
 
72
  # Function
73
  @spaces.GPU()
 
3
  import torch
4
  import numpy as np
5
  import random
6
+ from diffusers import StableDiffusion3Pipeline, AutoencoderKL, SD3Transformer2DModel, StableDiffusion3Img2ImgPipeline
7
  import spaces
8
  from diffusers.utils import load_image
9
  from PIL import Image
 
66
  pipe = StableDiffusion3Pipeline.from_pretrained(repo, vae=vae, transformer=transformer, tokenizer_3=tokenizer_3, text_encoder_3=text_encoder_3, torch_dtype=torch.float16).to("cuda")
67
  pipe2 = StableDiffusion3Img2ImgPipeline.from_pretrained(repo, vae=vae, transformer=transformer, tokenizer_3=tokenizer_3, text_encoder_3=text_encoder_3, torch_dtype=torch.float16).to("cuda")
68
 
 
 
69
 
70
  # Function
71
  @spaces.GPU()