mirror of
https://github.com/facefusion/facefusion-pinokio.git
synced 2026-06-04 01:17:59 +02:00
@@ -1,7 +1,7 @@
|
||||
FaceFusion Pinokio
|
||||
==================
|
||||
|
||||
> Next generation face swapper and enhancer.
|
||||
> Industry leading face manipulation platform.
|
||||
|
||||
[](https://github.com/facefusion/facefusion-pinokio/actions?query=workflow:ci)
|
||||
[](https://pinokio.computer/item?uri=https://github.com/facefusion/facefusion-pinokio)
|
||||
|
||||
Executable
BIN
Binary file not shown.
|
After Width: | Height: | Size: 264 KiB |
+25
-13
@@ -2,25 +2,25 @@ function install(kernel)
|
||||
{
|
||||
const { platform, gpu } = kernel;
|
||||
|
||||
if (platform === 'darwin')
|
||||
{
|
||||
return 'python install.py --onnxruntime default';
|
||||
}
|
||||
if ([ 'linux', 'win32' ].includes(platform) && gpu === 'nvidia')
|
||||
{
|
||||
return 'python install.py --onnxruntime cuda-11.8';
|
||||
}
|
||||
if (gpu === 'amd')
|
||||
{
|
||||
if (platform === 'linux')
|
||||
{
|
||||
return 'python install.py --onnxruntime rocm-5.4.2';
|
||||
return 'python install.py --onnxruntime rocm';
|
||||
}
|
||||
if (platform === 'win32')
|
||||
{
|
||||
return 'python install.py --onnxruntime directml';
|
||||
}
|
||||
}
|
||||
if (gpu === 'intel')
|
||||
{
|
||||
return 'python install.py --onnxruntime openvino';
|
||||
}
|
||||
if (gpu === 'nvidia')
|
||||
{
|
||||
return 'python install.py --onnxruntime cuda';
|
||||
}
|
||||
return 'python install.py --onnxruntime default';
|
||||
}
|
||||
|
||||
@@ -34,7 +34,19 @@ module.exports = async kernel =>
|
||||
method: 'shell.run',
|
||||
params:
|
||||
{
|
||||
message: 'git clone https://github.com/facefusion/facefusion --branch 2.6.1 --single-branch'
|
||||
message: 'git clone https://github.com/facefusion/facefusion --branch 3.0.0 --single-branch'
|
||||
}
|
||||
},
|
||||
{
|
||||
when: '{{ gpu === "intel" }}',
|
||||
method: 'shell.run',
|
||||
params:
|
||||
{
|
||||
message: 'conda install conda-forge::openvino=2024.3.0 --yes',
|
||||
conda:
|
||||
{
|
||||
name: 'facefusion'
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -42,7 +54,7 @@ module.exports = async kernel =>
|
||||
method: 'shell.run',
|
||||
params:
|
||||
{
|
||||
message: 'conda install cudatoolkit=11.8 cudnn=8.9.2.26 conda-forge::gputil=1.4.0 --yes',
|
||||
message: 'conda install conda-forge::cuda-runtime=12.4.1 cudnn=9.2.1.18 --yes',
|
||||
conda:
|
||||
{
|
||||
name: 'facefusion'
|
||||
@@ -69,8 +81,8 @@ module.exports = async kernel =>
|
||||
method: 'input',
|
||||
params:
|
||||
{
|
||||
title: 'Install complete',
|
||||
description: 'Go back to the dashboard to launch the application.'
|
||||
title: 'Installation completed',
|
||||
description: 'Return to the dashboard to start FaceFusion.'
|
||||
}
|
||||
},
|
||||
{
|
||||
|
||||
@@ -2,141 +2,100 @@ const path = require('path');
|
||||
|
||||
module.exports = async kernel =>
|
||||
{
|
||||
const hasInstall = await kernel.exists(__dirname, 'facefusion') && !await kernel.running(__dirname, 'install.js');
|
||||
const menu = [];
|
||||
|
||||
let menu = [];
|
||||
|
||||
if (hasInstall)
|
||||
if (!await kernel.exists(__dirname, 'facefusion', '.git'))
|
||||
{
|
||||
if (kernel.running(__dirname, 'start.js'))
|
||||
menu.push(
|
||||
{
|
||||
const memory = kernel.memory.local[path.resolve(__dirname, 'start.js')];
|
||||
icon: 'fa-solid fa-plug',
|
||||
text: 'Install',
|
||||
href: 'install.js',
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true
|
||||
}
|
||||
});
|
||||
|
||||
if (memory && memory.url && memory.mode)
|
||||
{
|
||||
menu =
|
||||
[
|
||||
{
|
||||
icon: 'fa-solid fa-rocket',
|
||||
text: 'Open session',
|
||||
href: memory.url,
|
||||
target: '_blank'
|
||||
},
|
||||
{
|
||||
icon: 'fa-solid fa-desktop',
|
||||
text: 'Server (' + memory.mode + ')',
|
||||
href: 'start.js',
|
||||
params:
|
||||
{
|
||||
fullscreen: true
|
||||
}
|
||||
}
|
||||
];
|
||||
}
|
||||
else
|
||||
{
|
||||
menu =
|
||||
[
|
||||
{
|
||||
icon: 'fa-solid fa-desktop',
|
||||
text: 'Server',
|
||||
href: 'start.js',
|
||||
params:
|
||||
{
|
||||
fullscreen: true
|
||||
}
|
||||
}
|
||||
];
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
menu =
|
||||
[
|
||||
{
|
||||
icon: 'fa-solid fa-power-off',
|
||||
text: 'Launch default',
|
||||
href: 'start.js',
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true,
|
||||
mode: 'Default'
|
||||
}
|
||||
},
|
||||
{
|
||||
icon: 'fa-solid fa-gauge',
|
||||
text: 'Launch benchmark',
|
||||
href: 'start.js',
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true,
|
||||
mode: 'Benchmark'
|
||||
}
|
||||
},
|
||||
{
|
||||
icon: 'fa-solid fa-camera',
|
||||
text: 'Launch webcam',
|
||||
href: 'start.js',
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true,
|
||||
mode: 'Webcam'
|
||||
}
|
||||
}
|
||||
];
|
||||
}
|
||||
menu = menu.concat(
|
||||
return menu;
|
||||
}
|
||||
|
||||
if (!await kernel.running(__dirname, 'run.js') && !await kernel.running(__dirname, 'install.js') && !await kernel.running(__dirname, 'update.js') && !await kernel.running(__dirname, 'reset.js'))
|
||||
{
|
||||
[
|
||||
[ 'fa-solid fa-power-off', 'Run Default', 'Default' ],
|
||||
[ 'fa-solid fa-gauge', 'Run Benchmark', 'Benchmark' ],
|
||||
[ 'fa-solid fa-robot', 'Run Jobs', 'Jobs' ],
|
||||
[ 'fa-solid fa-camera', 'Run Webcam', 'Webcam' ]
|
||||
]
|
||||
.forEach(([ icon, text, mode ]) =>
|
||||
{
|
||||
menu.push(
|
||||
{
|
||||
icon: 'fa-solid fa-rotate',
|
||||
text: 'Update',
|
||||
href: 'update.js',
|
||||
icon,
|
||||
text,
|
||||
href: 'run.js',
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true,
|
||||
mode
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
if (await kernel.running(__dirname, 'run.js'))
|
||||
{
|
||||
const memory = await kernel.memory.local[path.resolve(__dirname, 'run.js')];
|
||||
|
||||
if (memory && memory.url && memory.mode)
|
||||
{
|
||||
menu.push(
|
||||
{
|
||||
icon: 'fa-solid fa-rocket',
|
||||
text: 'UI (' + memory.mode + ')',
|
||||
href: memory.url,
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
menu.push(
|
||||
{
|
||||
icon: 'fa-solid fa-desktop',
|
||||
text: 'CLI',
|
||||
href: 'run.js',
|
||||
params:
|
||||
{
|
||||
icon: 'fa-solid fa-plug',
|
||||
text: 'Install',
|
||||
href: 'install.js',
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true
|
||||
}
|
||||
},
|
||||
{
|
||||
icon: 'fa-regular fa-circle-xmark',
|
||||
text: 'Reset',
|
||||
href: 'reset.js',
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true
|
||||
}
|
||||
run: true,
|
||||
fullscreen: true
|
||||
}
|
||||
]);
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
menu =
|
||||
[
|
||||
[ 'fa-solid fa-plug', 'Install', 'install.js' ],
|
||||
[ 'fa-solid fa-rotate', 'Update', 'update.js' ],
|
||||
[ 'fa-regular fa-circle-xmark', 'Reset', 'reset.js' ]
|
||||
]
|
||||
.forEach(([ icon, text, href ]) =>
|
||||
{
|
||||
menu.push(
|
||||
{
|
||||
icon: 'fa-solid fa-plug',
|
||||
text: 'Install',
|
||||
href: 'install.js',
|
||||
icon,
|
||||
text,
|
||||
href,
|
||||
params:
|
||||
{
|
||||
run: true,
|
||||
fullscreen: true
|
||||
}
|
||||
}
|
||||
];
|
||||
});
|
||||
});
|
||||
}
|
||||
return menu;
|
||||
};
|
||||
|
||||
+3
-3
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "facefusion-pinokio",
|
||||
"description": "Next generation face swapper and enhancer",
|
||||
"version": "2.6.1",
|
||||
"description": "Industry leading face manipulation platform",
|
||||
"version": "3.0.0",
|
||||
"license": "MIT",
|
||||
"devDependencies":
|
||||
{
|
||||
"@isnotdefined/eslint-config": "9.8.0",
|
||||
"eslint": "8.56.0"
|
||||
"eslint": "8.57.1"
|
||||
},
|
||||
"scripts":
|
||||
{
|
||||
|
||||
+3
-3
@@ -1,8 +1,8 @@
|
||||
module.exports =
|
||||
{
|
||||
version: '1.5',
|
||||
title: 'FaceFusion 2.6.1',
|
||||
description: 'Next generation face swapper and enhancer',
|
||||
icon: 'icon.png',
|
||||
title: 'FaceFusion 3.0.0',
|
||||
description: 'Industry leading face manipulation platform',
|
||||
icon: 'facefusion.png',
|
||||
menu: require(__dirname + '/menu.js')
|
||||
};
|
||||
|
||||
+4
-3
@@ -5,9 +5,10 @@ module.exports = () =>
|
||||
daemon: true,
|
||||
cmd:
|
||||
{
|
||||
Default: 'python run.py',
|
||||
Benchmark: 'python run.py --ui-layouts benchmark',
|
||||
Webcam: 'python run.py --ui-layouts webcam'
|
||||
Default: 'python facefusion.py run',
|
||||
Benchmark: 'python facefusion.py run --ui-layouts benchmark',
|
||||
Jobs: 'python facefusion.py run --ui-layouts jobs',
|
||||
Webcam: 'python facefusion.py run --ui-layouts webcam'
|
||||
},
|
||||
run:
|
||||
[
|
||||
Reference in New Issue
Block a user