安装准备: 1、下载模型(百度云链接: https://pan.baidu.com/s/1-OKeUq57JDiLQj0fxRY9NA 提取码: ncmr,或者到源项目下载),放到ComfyUI/models/liveportrait,目录结构如下:
├── liveportrait
├── animals
│ ├── base_models
│ │ ├── spade_generator.pth
│ │ ├── warping_module.pth
│ │ ├── appearance_feature_extractor.pth
│ │ ├── motion_extractor.pth
│ ├── xpose.pth
├── landmark.onnx
├── insightface
│ ├── models
│ │ ├── buffalo_l
│ │ │ ├── 2d106det.onnx
│ │ │ ├── det_10g.onnx
│ │ │ ├── genderage.onnx
│ │ │ ├── w600k_r50.onnx
│ │ │ ├── 1k3d68.onnx
│ │ ├── buffalo_l.zip
├── base_models
│ ├── spade_generator.pth
│ ├── warping_module.pth
│ ├── appearance_feature_extractor.pth
│ ├── motion_extractor.pth
2、执行如下命令安装相关依赖包:
pip install -r requirements.txt
#
注:如果需要驱动动物,则需要到ComfyUI-liveportrait-fg/liveportrait/src/utils/dependencies/XPose/models/UniPose/ops目录下执行编译命令(这里有一点需要特别注意,gcc和g++版本需要<=13,否则编译异常):
# gcc<=13、g++<=13
python setup.py build install
# 安装gcc-13、g++-13请看gcc_install.txt(看需要选择)
如果是linux系统,cuda12.6+python 3.11的,可以通过目录下的multiscaledeformableattention-1.0-cp311-cp311-linux_x86_64.whl安装,本人测试环境使用的。
