Spaces:
Running
on
A10G
Running
on
A10G
Zhouyan248
commited on
Commit
•
4d9111b
1
Parent(s):
380224b
Update base/text_to_video/__init__.py
Browse files
base/text_to_video/__init__.py
CHANGED
@@ -22,10 +22,11 @@ args = OmegaConf.load("./base/configs/sample.yaml")
|
|
22 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
23 |
|
24 |
def model_t2v_fun(args):
|
25 |
-
sd_path = args.pretrained_path + "/stable-diffusion-v1-4"
|
|
|
26 |
unet = get_models(args, sd_path).to(device, dtype=torch.float16)
|
27 |
# state_dict = find_model(args.pretrained_path + "/lavie_base.pt")
|
28 |
-
state_dict = find_model("
|
29 |
unet.load_state_dict(state_dict)
|
30 |
|
31 |
vae = AutoencoderKL.from_pretrained(sd_path, subfolder="vae", torch_dtype=torch.float16).to(device)
|
|
|
22 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
23 |
|
24 |
def model_t2v_fun(args):
|
25 |
+
# sd_path = args.pretrained_path + "/stable-diffusion-v1-4"
|
26 |
+
sd_path = args.pretrained_path
|
27 |
unet = get_models(args, sd_path).to(device, dtype=torch.float16)
|
28 |
# state_dict = find_model(args.pretrained_path + "/lavie_base.pt")
|
29 |
+
state_dict = find_model("./pretrained_models/lavie_base.pt")
|
30 |
unet.load_state_dict(state_dict)
|
31 |
|
32 |
vae = AutoencoderKL.from_pretrained(sd_path, subfolder="vae", torch_dtype=torch.float16).to(device)
|