Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -79,7 +79,7 @@ HF_TOKEN = os.getenv("HF_TOKEN")
|
|
79 |
|
80 |
device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu")
|
81 |
|
82 |
-
def scheduler_swap_callback(pipeline, step_index, timestep):
|
83 |
# adjust the batch_size of prompt_embeds according to guidance_scale
|
84 |
if step_index == int(pipeline.num_timesteps * 0.1):
|
85 |
print("-- swapping scheduler --")
|
|
|
79 |
|
80 |
device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu")
|
81 |
|
82 |
+
def scheduler_swap_callback(pipeline, step_index, timestep, callback_kwargs):
|
83 |
# adjust the batch_size of prompt_embeds according to guidance_scale
|
84 |
if step_index == int(pipeline.num_timesteps * 0.1):
|
85 |
print("-- swapping scheduler --")
|