KingNish commited on
Commit
0b3f980
1 Parent(s): f710012

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -8,9 +8,10 @@ import spaces
8
  device = "cuda"
9
 
10
  torch.cuda.max_memory_allocated(device=device)
11
- pipe = DiffusionPipeline.from_pretrained("sd-community/sdxl-flash", torch_dtype=torch.float16, use_safetensors=True)
12
  pipe.enable_xformers_memory_efficient_attention()
13
  pipe = pipe.to(device)
 
14
 
15
  MAX_SEED = np.iinfo(np.int32).max
16
  MAX_IMAGE_SIZE = 1024
 
8
  device = "cuda"
9
 
10
  torch.cuda.max_memory_allocated(device=device)
11
+ pipe = StableDiffusionXLPipeline.from_pretrained("sd-community/sdxl-flash")
12
  pipe.enable_xformers_memory_efficient_attention()
13
  pipe = pipe.to(device)
14
+ pipe.scheduler = DPMSolverSinglestepScheduler.from_config(pipe.scheduler.config, timestep_spacing="trailing")
15
 
16
  MAX_SEED = np.iinfo(np.int32).max
17
  MAX_IMAGE_SIZE = 1024