Skip to main content

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.

Preview

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.3.tar.gz (33.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

facefusionlib-1.1.3-py3-none-any.whl (45.5 kB view details)

Uploaded Python 3

File details

Details for the file facefusionlib-1.1.3.tar.gz.

File metadata

  • Download URL: facefusionlib-1.1.3.tar.gz
  • Upload date:
  • Size: 33.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.6

File hashes

Hashes for facefusionlib-1.1.3.tar.gz
Algorithm Hash digest
SHA256 51d4690a657f5aa80ac2c9e57f8d2a882bfcde894bc2fb66650796f2472f1d5f
MD5 7a2d70a44ddc0447e16fb164abc8ff79
BLAKE2b-256 05a706de1c3939770d1c556f5fead95ed0f4be09211e49f12459091790511002

See more details on using hashes here.

File details

Details for the file facefusionlib-1.1.3-py3-none-any.whl.

File metadata

  • Download URL: facefusionlib-1.1.3-py3-none-any.whl
  • Upload date:
  • Size: 45.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.6

File hashes

Hashes for facefusionlib-1.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 27c66fdec4627066fca9ff3ffc18e59b604a6637a8a70e49dfec4383add12800
MD5 3ae8ffc0382dfe5d9665f8fa314ced2d
BLAKE2b-256 38c1c4ae721b34c49b31617f42c050acc443090c9c91c946469963d266cd9269

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page