Spaces:
Running
Running
Commit
·
bea4d2e
1
Parent(s):
2f1fa52
update
Browse files
options/Banner_Model/Image2Image_2.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
import torch
|
2 |
from controlnet_aux import LineartDetector
|
3 |
-
from diffusers import ControlNetModel,UniPCMultistepScheduler,
|
4 |
from PIL import Image
|
5 |
|
6 |
device= "cuda" if torch.cuda.is_available() else "cpu"
|
@@ -9,7 +9,7 @@ processor = LineartDetector.from_pretrained("lllyasviel/Annotators")
|
|
9 |
|
10 |
checkpoint = "ControlNet-1-1-preview/control_v11p_sd15_lineart"
|
11 |
controlnet = ControlNetModel.from_pretrained(checkpoint, torch_dtype=torch.float16).to(device)
|
12 |
-
pipe =
|
13 |
"benjamin-paine/stable-diffusion-v1-5", controlnet=controlnet, torch_dtype=torch.float16
|
14 |
).to(device)
|
15 |
pipe.scheduler = UniPCMultistepScheduler.from_config(pipe.scheduler.config)
|
|
|
1 |
import torch
|
2 |
from controlnet_aux import LineartDetector
|
3 |
+
from diffusers import ControlNetModel,UniPCMultistepScheduler,StableVideoDiffusionPipeline
|
4 |
from PIL import Image
|
5 |
|
6 |
device= "cuda" if torch.cuda.is_available() else "cpu"
|
|
|
9 |
|
10 |
checkpoint = "ControlNet-1-1-preview/control_v11p_sd15_lineart"
|
11 |
controlnet = ControlNetModel.from_pretrained(checkpoint, torch_dtype=torch.float16).to(device)
|
12 |
+
pipe = StableVideoDiffusionPipeline.from_pretrained(
|
13 |
"benjamin-paine/stable-diffusion-v1-5", controlnet=controlnet, torch_dtype=torch.float16
|
14 |
).to(device)
|
15 |
pipe.scheduler = UniPCMultistepScheduler.from_config(pipe.scheduler.config)
|
options/Banner_Model/__pycache__/Image2Image_2.cpython-310.pyc
CHANGED
Binary files a/options/Banner_Model/__pycache__/Image2Image_2.cpython-310.pyc and b/options/Banner_Model/__pycache__/Image2Image_2.cpython-310.pyc differ
|
|