mirror of
https://github.com/Wan-Video/Wan2.1.git
synced 2026-01-11 16:53:34 +00:00
fixed memory leak
This commit is contained in:
parent
9e0354e14f
commit
336e941183
@ -20,7 +20,7 @@ WanGP supports the Wan (and derived models), Hunyuan Video and LTV Video models
|
|||||||
**Follow DeepBeepMeep on Twitter/X to get the Latest News**: https://x.com/deepbeepmeep
|
**Follow DeepBeepMeep on Twitter/X to get the Latest News**: https://x.com/deepbeepmeep
|
||||||
|
|
||||||
## 🔥 Latest Updates :
|
## 🔥 Latest Updates :
|
||||||
### August 29 2025: WanGP v8.2 - Here Goes Your Weekend
|
### August 29 2025: WanGP v8.21 - Here Goes Your Weekend
|
||||||
|
|
||||||
- **InfiniteTalk Video to Video**: this feature can be used for Video Dubbing. Keep in mind that it is a *Sparse Video to Video*, that is internally only image is used by Sliding Window. However thanks to the new *Smooth Transition* mode, each new clip is connected to the previous and all the camera work is done by InfiniteTalk. If you dont get any transition, increase the number of frames of a Sliding Window (81 frames recommended)
|
- **InfiniteTalk Video to Video**: this feature can be used for Video Dubbing. Keep in mind that it is a *Sparse Video to Video*, that is internally only image is used by Sliding Window. However thanks to the new *Smooth Transition* mode, each new clip is connected to the previous and all the camera work is done by InfiniteTalk. If you dont get any transition, increase the number of frames of a Sliding Window (81 frames recommended)
|
||||||
|
|
||||||
|
|||||||
@ -778,13 +778,11 @@ class WanAny2V:
|
|||||||
from preprocessing.face_preprocessor import FaceProcessor
|
from preprocessing.face_preprocessor import FaceProcessor
|
||||||
standin_ref_pos = 1 if "K" in video_prompt_type else 0
|
standin_ref_pos = 1 if "K" in video_prompt_type else 0
|
||||||
if len(original_input_ref_images) < standin_ref_pos + 1:
|
if len(original_input_ref_images) < standin_ref_pos + 1:
|
||||||
if "I" in video_prompt_type:
|
if "I" in video_prompt_type and model_type in ["vace_standin_14B"]:
|
||||||
print("Warning: Missing Standin ref image, make sure 'Inject only People / Objets' is selected or if there is 'Landscape and then People or Objects' there are at least two ref images.")
|
print("Warning: Missing Standin ref image, make sure 'Inject only People / Objets' is selected or if there is 'Landscape and then People or Objects' there are at least two ref images.")
|
||||||
else:
|
else:
|
||||||
standin_ref_pos = -1
|
standin_ref_pos = -1
|
||||||
image_ref = original_input_ref_images[standin_ref_pos]
|
image_ref = original_input_ref_images[standin_ref_pos]
|
||||||
image_ref.save("si.png")
|
|
||||||
# face_processor = FaceProcessor(antelopv2_path="ckpts/antelopev2")
|
|
||||||
face_processor = FaceProcessor()
|
face_processor = FaceProcessor()
|
||||||
standin_ref = face_processor.process(image_ref, remove_bg = model_type in ["vace_standin_14B"])
|
standin_ref = face_processor.process(image_ref, remove_bg = model_type in ["vace_standin_14B"])
|
||||||
face_processor = None
|
face_processor = None
|
||||||
|
|||||||
1
wgp.py
1
wgp.py
@ -81,6 +81,7 @@ def clear_gen_cache():
|
|||||||
|
|
||||||
def release_model():
|
def release_model():
|
||||||
global wan_model, offloadobj, reload_needed
|
global wan_model, offloadobj, reload_needed
|
||||||
|
wan_model = None
|
||||||
clear_gen_cache()
|
clear_gen_cache()
|
||||||
offload.shared_state
|
offload.shared_state
|
||||||
if offloadobj is not None:
|
if offloadobj is not None:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user