From 705813ac60b0b9c09ac2968493a70188429d65d5 Mon Sep 17 00:00:00 2001 From: Justin John Date: Thu, 16 Nov 2023 12:26:35 +0530 Subject: [PATCH] Integrated Rerender_A_Video with submodules into animation directory --- .gitmodules | 2 +- animation/Rerender_A_Video/.gitmodules | 16 ++++++++-------- animation/Rerender_A_Video/deps/gmflow | 1 + .../Rerender_A_Video/inference_playground.ipynb | 4 ++-- animation/Rerender_A_Video/rerender.py | 6 +++--- 5 files changed, 15 insertions(+), 14 deletions(-) create mode 160000 animation/Rerender_A_Video/deps/gmflow diff --git a/.gitmodules b/.gitmodules index a0e2572..258dd2a 100644 --- a/.gitmodules +++ b/.gitmodules @@ -6,4 +6,4 @@ url = https://github.com/SingleZombie/ebsynth [submodule "animation/Rerender_A_Video/deps/gmflow"] path = animation/Rerender_A_Video/deps/gmflow - url = https://github.com/haofeixu/gmflow + url = https://github.com/haofeixu/gmflow.git diff --git a/animation/Rerender_A_Video/.gitmodules b/animation/Rerender_A_Video/.gitmodules index 2451636..b6588a1 100644 --- a/animation/Rerender_A_Video/.gitmodules +++ b/animation/Rerender_A_Video/.gitmodules @@ -1,9 +1,9 @@ -[submodule "animation/Rerender_A_Video/deps/ControlNet"] - path = animation/Rerender_A_Video/deps/ControlNet +[submodule "deps/gmflow"] + path = deps/gmflow + url = https://github.com/haofeixu/gmflow.git +[submodule "deps/ControlNet"] + path = deps/ControlNet url = https://github.com/lllyasviel/ControlNet.git -[submodule "animation/Rerender_A_Video/deps/ebsynth"] - path = animation/Rerender_A_Video/deps/ebsynth - url = https://github.com/SingleZombie/ebsynth/ -[submodule "animation/Rerender_A_Video/deps/gmflow"] - path = animation/Rerender_A_Video/deps/gmflow - url = https://github.com/haofeixu/gmflow/ +[submodule "deps/ebsynth"] + path = deps/ebsynth + url = https://github.com/SingleZombie/ebsynth.git diff --git a/animation/Rerender_A_Video/deps/gmflow b/animation/Rerender_A_Video/deps/gmflow new file mode 160000 index 0000000..af2d869 --- /dev/null +++ b/animation/Rerender_A_Video/deps/gmflow @@ -0,0 +1 @@ +Subproject commit af2d869a6fa38b0b076d6f28ab5af1f64beca335 diff --git a/animation/Rerender_A_Video/inference_playground.ipynb b/animation/Rerender_A_Video/inference_playground.ipynb index 52040d5..444d15d 100644 --- a/animation/Rerender_A_Video/inference_playground.ipynb +++ b/animation/Rerender_A_Video/inference_playground.ipynb @@ -1053,8 +1053,8 @@ " else:\n", " noise_rescale = torch.ones_like(mask)\n", " masks = []\n", - " for i in range(ddim_steps):\n", - " if i <= ddim_steps * mask_period[0] or i >= ddim_steps * mask_period[1]:\n", + " for j in range(ddim_steps):\n", + " if j <= ddim_steps * mask_period[0] or j >= ddim_steps * mask_period[1]:\n", " masks += [None]\n", " else:\n", " masks += [mask * mask_strength]\n", diff --git a/animation/Rerender_A_Video/rerender.py b/animation/Rerender_A_Video/rerender.py index cf73162..394d8f4 100644 --- a/animation/Rerender_A_Video/rerender.py +++ b/animation/Rerender_A_Video/rerender.py @@ -331,9 +331,9 @@ def rerender(cfg: RerenderConfig, first_img_only: bool, key_video_path: str): else: noise_rescale = torch.ones_like(mask) masks = [] - for i in range(ddim_steps): - if i <= ddim_steps * mask_period[ - 0] or i >= ddim_steps * mask_period[1]: + for j in range(ddim_steps): + if j <= ddim_steps * mask_period[ + 0] or j >= ddim_steps * mask_period[1]: masks += [None] else: masks += [mask * cfg.mask_strength]