Eyalgut commited on
Commit
99044ca
·
verified ·
1 Parent(s): bf3ec4d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -7
app.py CHANGED
@@ -12,15 +12,10 @@ class Dummy():
12
  resolutions = ["1024 1024","1280 768","1344 768","768 1344","768 1280"]
13
 
14
  # Load pipeline
15
- scheduler = EulerAncestralDiscreteScheduler(
16
- beta_start=0.00085,
17
- beta_end=0.012,
18
- beta_schedule="scaled_linear",
19
- num_train_timesteps=1000,
20
- steps_offset=1
21
- )
22
  unet = UNet2DConditionModel.from_pretrained("briaai/BRIA-LCM-2.2", torch_dtype=torch.float16)
23
  pipe = DiffusionPipeline.from_pretrained("briaai/BRIA-2.2", unet=unet, torch_dtype=torch.float16)
 
24
  pipe = to("cuda")
25
  pipe.force_zeros_for_empty_prompt = False
26
 
 
12
  resolutions = ["1024 1024","1280 768","1344 768","768 1344","768 1280"]
13
 
14
  # Load pipeline
15
+
 
 
 
 
 
 
16
  unet = UNet2DConditionModel.from_pretrained("briaai/BRIA-LCM-2.2", torch_dtype=torch.float16)
17
  pipe = DiffusionPipeline.from_pretrained("briaai/BRIA-2.2", unet=unet, torch_dtype=torch.float16)
18
+ pipe.scheduler = LCMScheduler.from_config(pipe.scheduler.config)
19
  pipe = to("cuda")
20
  pipe.force_zeros_for_empty_prompt = False
21