Face swapper and enhancer
Project description
FaceFuison Python Lib
FaceFusion is a very nice face swapper and enhancer.
Requirements
python: >=3.9
Installation
CPU support:
pip install facefusionlib
GPU support:
First of all, you need to check if your system supports the onnxruntime-gpu
.
Go to https://onnxruntime.ai and check the installation matrix.
If yes, just run:
pip install facefusionlib[gpu]
Usage
from facefusionlib import swapper
from facefusionlib.swapper import DeviceProvider
input_path = 'input.png'
target_path = 'target.png'
result = swapper.swap_face(
source_paths=[input_path],
target_path=target_path,
provider=DeviceProvider.CPU,
detector_score=0.65,
mask_blur=0.7,
skip_nsfw=True,
landmarker_score=0.5
)
print(result)
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
facefusionlib-1.1.1.tar.gz
(33.5 kB
view hashes)
Built Distribution
Close
Hashes for facefusionlib-1.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 951d84215d35a71eab0158a48b93c39d198a3d793baaeb8135205f36dfa13289 |
|
MD5 | fa9455181ab756d74b995e9971244dea |
|
BLAKE2b-256 | b5c6849abb51eeb5c7641df5c0a4abbcd33fd6c8d9cf9aeb9e58ce349eb086a4 |