From 8fc9b6c270e55c220ce5ab4c1189bab8e9edab31 Mon Sep 17 00:00:00 2001 From: henryruhs Date: Tue, 9 Apr 2024 18:53:09 +0200 Subject: [PATCH 1/7] Prepare 2.5.0 using conda only --- install.js | 7 +++---- menu.js | 3 +-- package.json | 2 +- pinokio.js | 2 +- start.js | 3 +-- update.js | 2 +- 6 files changed, 8 insertions(+), 11 deletions(-) diff --git a/install.js b/install.js index 1e14708..7829839 100644 --- a/install.js +++ b/install.js @@ -41,7 +41,7 @@ module.exports = async kernel => ], conda: { - name: '{{ gpu === "nvidia" ? "cu118" : "base" }}' + name: 'facefusion-pinokio' } } }, @@ -49,7 +49,7 @@ module.exports = async kernel => method: 'shell.run', params: { - message: 'git clone https://github.com/facefusion/facefusion --branch 2.4.1 --single-branch' + message: 'git clone https://github.com/facefusion/facefusion --branch 2.5.0 --single-branch' } }, { @@ -58,14 +58,13 @@ module.exports = async kernel => { message: install(kernel), path: 'facefusion', - venv: 'env', env: { PYTHONNOUSERSITE: 'True' }, conda: { - name: '{{ gpu === "nvidia" ? "cu118" : "base" }}' + name: 'facefusion-pinokio' } } }, diff --git a/menu.js b/menu.js index ca78d55..76cf394 100644 --- a/menu.js +++ b/menu.js @@ -2,12 +2,11 @@ const path = require('path'); module.exports = async kernel => { - const hasEnv = await kernel.exists(__dirname, 'facefusion', 'env'); const hasRepo = await kernel.exists(__dirname, 'facefusion'); let menu = []; - if (hasEnv && hasRepo) + if (hasRepo) { if (kernel.running(__dirname, 'start.js')) { diff --git a/package.json b/package.json index e475219..ee29f52 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "facefusion-pinokio", "description": "Next generation face swapper and enhancer", - "version": "2.4.1", + "version": "2.5.0", "license": "MIT", "devDependencies": { diff --git a/pinokio.js b/pinokio.js index ff7e2d4..3961018 100644 --- a/pinokio.js +++ b/pinokio.js @@ -1,7 +1,7 @@ module.exports = { version: '1.4', - title: 'FaceFusion 2.4.1', + title: 'FaceFusion 2.5.0', description: 'Next generation face swapper and enhancer', icon: 'icon.png', menu: require(__dirname + '/menu.js') diff --git a/start.js b/start.js index 8076a64..dc593c7 100644 --- a/start.js +++ b/start.js @@ -24,10 +24,9 @@ module.exports = () => { message: '{{ self.cmd[local.mode] }}', path: 'facefusion', - venv: 'env', conda: { - name: '{{ gpu === "nvidia" ? "cu118" : "base" }}' + name: 'facefusion-pinokio' }, on: [ diff --git a/update.js b/update.js index 5edf482..5a89187 100644 --- a/update.js +++ b/update.js @@ -23,7 +23,7 @@ module.exports = () => method: 'shell.run', params: { - message: 'git checkout 2.4.1', + message: 'git checkout 2.5.0', path: 'facefusion' } } From 1743574eb1ddf1d7c110c33e8223982f0881de17 Mon Sep 17 00:00:00 2001 From: henryruhs Date: Tue, 9 Apr 2024 19:06:02 +0200 Subject: [PATCH 2/7] Remove custom cuda install --- install.js | 25 +++++-------------------- 1 file changed, 5 insertions(+), 20 deletions(-) diff --git a/install.js b/install.js index 7829839..f25156a 100644 --- a/install.js +++ b/install.js @@ -4,24 +4,24 @@ function install(kernel) if (platform === 'darwin') { - return 'python install.py --onnxruntime default --skip-venv'; + return 'python install.py --onnxruntime default'; } if ([ 'linux', 'win32' ].includes(platform) && gpu === 'nvidia') { - return 'python install.py --onnxruntime cuda-11.8 --skip-venv'; + return 'python install.py --onnxruntime cuda-12.2'; } if (gpu === 'amd') { if (platform === 'linux') { - return 'python install.py --onnxruntime rocm-5.4.2 --skip-venv'; + return 'python install.py --onnxruntime rocm-5.4.2'; } if (platform === 'win32') { - return 'python install.py --onnxruntime directml --skip-venv'; + return 'python install.py --onnxruntime directml'; } } - return 'python install.py --onnxruntime default --skip-venv'; + return 'python install.py --onnxruntime default'; } module.exports = async kernel => @@ -30,21 +30,6 @@ module.exports = async kernel => { run: [ - { - when: '{{ gpu === "nvidia" }}', - method: 'shell.run', - params: - { - message: - [ - 'conda install cudatoolkit=11.8 cudnn=8.9.2.26 -y' - ], - conda: - { - name: 'facefusion-pinokio' - } - } - }, { method: 'shell.run', params: From c43fdeb6c0782e867ffc87136b98faa2b03afa3a Mon Sep 17 00:00:00 2001 From: henryruhs Date: Tue, 9 Apr 2024 19:17:11 +0200 Subject: [PATCH 3/7] Detect install --- menu.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/menu.js b/menu.js index 76cf394..318bf89 100644 --- a/menu.js +++ b/menu.js @@ -2,11 +2,11 @@ const path = require('path'); module.exports = async kernel => { - const hasRepo = await kernel.exists(__dirname, 'facefusion'); + const hasInstall = await kernel.exists(__dirname, 'facefusion', '.assets'); let menu = []; - if (hasRepo) + if (hasInstall) { if (kernel.running(__dirname, 'start.js')) { From 8b7d7aada007793145bf86d37cf7c011c65b0456 Mon Sep 17 00:00:00 2001 From: henryruhs Date: Tue, 9 Apr 2024 19:22:01 +0200 Subject: [PATCH 4/7] Detect install --- menu.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/menu.js b/menu.js index 318bf89..3806a92 100644 --- a/menu.js +++ b/menu.js @@ -2,7 +2,7 @@ const path = require('path'); module.exports = async kernel => { - const hasInstall = await kernel.exists(__dirname, 'facefusion', '.assets'); + const hasInstall = await kernel.exists(__dirname, 'facefusion'); let menu = []; From 2bbb1ba78863ea47a65f5a0a3af35305225bd750 Mon Sep 17 00:00:00 2001 From: henryruhs Date: Tue, 9 Apr 2024 19:27:22 +0200 Subject: [PATCH 5/7] Okay to name it facefusion as of local scope --- install.js | 2 +- start.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/install.js b/install.js index f25156a..4d8f004 100644 --- a/install.js +++ b/install.js @@ -49,7 +49,7 @@ module.exports = async kernel => }, conda: { - name: 'facefusion-pinokio' + name: 'facefusion' } } }, diff --git a/start.js b/start.js index dc593c7..b53e346 100644 --- a/start.js +++ b/start.js @@ -26,7 +26,7 @@ module.exports = () => path: 'facefusion', conda: { - name: 'facefusion-pinokio' + name: 'facefusion' }, on: [ From 1bb08e6b57fcb108113b44c5e6cdb9aa7a05fb35 Mon Sep 17 00:00:00 2001 From: henryruhs Date: Tue, 9 Apr 2024 19:34:31 +0200 Subject: [PATCH 6/7] Okay to name it facefusion as of local scope --- menu.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/menu.js b/menu.js index 3806a92..91973ba 100644 --- a/menu.js +++ b/menu.js @@ -2,7 +2,7 @@ const path = require('path'); module.exports = async kernel => { - const hasInstall = await kernel.exists(__dirname, 'facefusion'); + const hasInstall = await kernel.exists(__dirname, 'facefusion') && !await kernel.running(__dirname, 'install.js') let menu = []; From 638109510ecf4884a2fd83a5867eb54797cf22ad Mon Sep 17 00:00:00 2001 From: henryruhs Date: Tue, 9 Apr 2024 19:35:42 +0200 Subject: [PATCH 7/7] Okay to name it facefusion as of local scope --- menu.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/menu.js b/menu.js index 91973ba..5b086a0 100644 --- a/menu.js +++ b/menu.js @@ -2,7 +2,7 @@ const path = require('path'); module.exports = async kernel => { - const hasInstall = await kernel.exists(__dirname, 'facefusion') && !await kernel.running(__dirname, 'install.js') + const hasInstall = await kernel.exists(__dirname, 'facefusion') && !await kernel.running(__dirname, 'install.js'); let menu = [];