From 00f2e8c34e2fd10c1990f5ae827b28a87eb19b84 Mon Sep 17 00:00:00 2001 From: inisis Date: Mon, 12 Aug 2024 11:51:24 +0000 Subject: [PATCH] add onnxslim support Signed-off-by: inisis --- README.md | 5 ++++- requirements.txt | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 47be2e52..14b7245b 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,10 @@ Users of this software are expected to use this software responsibly while abidi 1. [GFPGANv1.4](https://huggingface.co/hacksider/deep-live-cam/resolve/main/GFPGANv1.4.pth) 2. [inswapper_128_fp16.onnx](https://huggingface.co/hacksider/deep-live-cam/resolve/main/inswapper_128_fp16.onnx) -Then put those 2 files on the "**models**" folder +Then put those 2 files on the "**models**" folder, you can further optimize inswapper_128_fp16.onnx by using [onnxslim](https://github.com/inisis/OnnxSlim) +``` +onnxslim inswapper_128_fp16.onnx inswapper_128_fp16.onnx +``` #### 4. Install dependency We highly recommend to work with a `venv` to avoid issues. diff --git a/requirements.txt b/requirements.txt index 68583131..ef325b1c 100644 --- a/requirements.txt +++ b/requirements.txt @@ -22,3 +22,4 @@ protobuf==4.23.2 tqdm==4.66.4 gfpgan==1.3.8 pyobjc==9.1; sys_platform == 'darwin' +onnxslim