mirror of
https://git.datalinker.icu/kijai/ComfyUI-CogVideoXWrapper.git
synced 2026-05-01 23:12:25 +08:00
error out if trying to use I2V model with other frame counts than 49
This commit is contained in:
parent
3dcf92fe52
commit
e1a784d92b
7
nodes.py
7
nodes.py
@ -419,7 +419,8 @@ class DownloadAndLoadCogVideoModel:
|
|||||||
"base_path": base_path,
|
"base_path": base_path,
|
||||||
"onediff": True if compile == "onediff" else False,
|
"onediff": True if compile == "onediff" else False,
|
||||||
"cpu_offloading": enable_sequential_cpu_offload,
|
"cpu_offloading": enable_sequential_cpu_offload,
|
||||||
"scheduler_config": scheduler_config
|
"scheduler_config": scheduler_config,
|
||||||
|
"model_name": model
|
||||||
}
|
}
|
||||||
|
|
||||||
return (pipeline,)
|
return (pipeline,)
|
||||||
@ -588,7 +589,8 @@ class DownloadAndLoadCogVideoGGUFModel:
|
|||||||
"base_path": model,
|
"base_path": model,
|
||||||
"onediff": True if compile == "onediff" else False,
|
"onediff": True if compile == "onediff" else False,
|
||||||
"cpu_offloading": enable_sequential_cpu_offload,
|
"cpu_offloading": enable_sequential_cpu_offload,
|
||||||
"scheduler_config": scheduler_config
|
"scheduler_config": scheduler_config,
|
||||||
|
"model_name": model
|
||||||
}
|
}
|
||||||
|
|
||||||
return (pipeline,)
|
return (pipeline,)
|
||||||
@ -868,6 +870,7 @@ class CogVideoSampler:
|
|||||||
base_path = pipeline["base_path"]
|
base_path = pipeline["base_path"]
|
||||||
|
|
||||||
assert "fun" not in base_path.lower(), "'Fun' models not supported in 'CogVideoSampler', use the 'CogVideoXFunSampler'"
|
assert "fun" not in base_path.lower(), "'Fun' models not supported in 'CogVideoSampler', use the 'CogVideoXFunSampler'"
|
||||||
|
assert ("I2V" not in pipeline["model_name"] or num_frames == 49 or context_options is not None), "I2V model can only do 49 frames"
|
||||||
|
|
||||||
device = mm.get_torch_device()
|
device = mm.get_torch_device()
|
||||||
offload_device = mm.unet_offload_device()
|
offload_device = mm.unet_offload_device()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user