Skip to content

Latest commit

 

History

16 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pyfeat-generator

Runtime for conditional facial-expression editing and face resynthesis — the FaceEditor / LiveEditSession API used by pyfeat-live, built on py-feat 2.0. Model weights are fetched from the py-feat HuggingFace org (py-feat/pyfeat-generator*).

MIT licensed.

Install

pip install pyfeat-generator

Pulls py-feat >= 2.0.3 and torch >= 2.12. Model weights download from the public py-feat HuggingFace org on first use (cached thereafter).

Device support

FaceEditor / LiveEditSession run on NVIDIA CUDA, Apple Silicon (MPS), and CPU. The rasterizer auto-selects a backend for the device; all three are parity-gated to byte-identical output, so results never depend on the machine.

Device Backend Notes
NVIDIA CUDA nvdiffrast Fastest. Optionalpip install nvdiffrast separately (needs the CUDA toolkit). Falls back to torch if absent.
Apple Silicon (MPS) metal Fused torch.mps.compile_shader kernel. Requires torch ≥ 2.12 (this package's floor); older torch falls back to torch.
CPU / other torch Pure-PyTorch, device-agnostic. Always works; slowest.

nvdiffrast is never imported off CUDA (the auto-selector guards it behind torch.cuda.is_available()), so it is not a dependency and is not needed on a Mac. Force a backend with the env var AU_RASTER_BACKEND=nvdiffrast|metal|torch.

About

Conditional facial-expression editing & face resynthesis runtime (FaceEditor / LiveEditSession) on top of py-feat 2.0

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages