Skip to content

Commit

Permalink
Merge pull request #14 from facefusion/next
Browse files Browse the repository at this point in the history
Next
  • Loading branch information
henryruhs committed Apr 9, 2024
2 parents 626da1f + 6381095 commit 6bdf509
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 31 deletions.
30 changes: 7 additions & 23 deletions install.js
Original file line number Diff line number Diff line change
Expand Up @@ -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 =>
Expand All @@ -31,25 +31,10 @@ 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: '{{ gpu === "nvidia" ? "cu118" : "base" }}'
}
}
},
{
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'
}
},
{
Expand All @@ -58,14 +43,13 @@ module.exports = async kernel =>
{
message: install(kernel),
path: 'facefusion',
venv: 'env',
env:
{
PYTHONNOUSERSITE: 'True'
},
conda:
{
name: '{{ gpu === "nvidia" ? "cu118" : "base" }}'
name: 'facefusion'
}
}
},
Expand Down
5 changes: 2 additions & 3 deletions menu.js
Original file line number Diff line number Diff line change
Expand Up @@ -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');
const hasInstall = await kernel.exists(__dirname, 'facefusion') && !await kernel.running(__dirname, 'install.js');

let menu = [];

if (hasEnv && hasRepo)
if (hasInstall)
{
if (kernel.running(__dirname, 'start.js'))
{
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -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":
{
Expand Down
2 changes: 1 addition & 1 deletion pinokio.js
Original file line number Diff line number Diff line change
@@ -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')
Expand Down
3 changes: 1 addition & 2 deletions start.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,9 @@ module.exports = () =>
{
message: '{{ self.cmd[local.mode] }}',
path: 'facefusion',
venv: 'env',
conda:
{
name: '{{ gpu === "nvidia" ? "cu118" : "base" }}'
name: 'facefusion'
},
on:
[
Expand Down
2 changes: 1 addition & 1 deletion update.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ module.exports = () =>
method: 'shell.run',
params:
{
message: 'git checkout 2.4.1',
message: 'git checkout 2.5.0',
path: 'facefusion'
}
}
Expand Down

0 comments on commit 6bdf509

Please sign in to comment.