From 97dbaf2e1408479bcfdc26f00b37aaa915f6581a Mon Sep 17 00:00:00 2001 From: yuyuyzl Date: Wed, 4 May 2022 21:07:25 +0800 Subject: [PATCH] bats --- 00A.Python下载(点击Download Python 3.x.x按钮).url | 5 +++++ 00B.预训练数据下载(需要科学上网).url | 5 +++++ main.py | 2 +- 3 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 00A.Python下载(点击Download Python 3.x.x按钮).url create mode 100644 00B.预训练数据下载(需要科学上网).url diff --git a/00A.Python下载(点击Download Python 3.x.x按钮).url b/00A.Python下载(点击Download Python 3.x.x按钮).url new file mode 100644 index 0000000..8112415 --- /dev/null +++ b/00A.Python下载(点击Download Python 3.x.x按钮).url @@ -0,0 +1,5 @@ +[{000214A0-0000-0000-C000-000000000046}] +Prop3=19,11 +[InternetShortcut] +IDList= +URL=https://www.python.org/downloads/ diff --git a/00B.预训练数据下载(需要科学上网).url b/00B.预训练数据下载(需要科学上网).url new file mode 100644 index 0000000..c833d13 --- /dev/null +++ b/00B.预训练数据下载(需要科学上网).url @@ -0,0 +1,5 @@ +[{000214A0-0000-0000-C000-000000000046}] +Prop3=19,11 +[InternetShortcut] +IDList= +URL=https://www.dropbox.com/s/tsl04y5wvg73ij4/talking-head-anime-2-model.zip?dl=0 diff --git a/main.py b/main.py index 0f06201..4141bce 100644 --- a/main.py +++ b/main.py @@ -154,7 +154,7 @@ def main(): model = model img = Image.open(f"character/{args.character}.png") wRatio = img.size[0] / 256 - img = img.resize((256, img.size[1] / wRatio)) + img = img.resize((256, int(img.size[1] / wRatio))) input_image = preprocessing_image(img.crop((0, 0, 256, 256))).unsqueeze(0) extra_image = None if img.size[1]>256: