[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-72275":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":17,"stars7d":18,"stars30d":19,"stars90d":16,"forks30d":16,"starsTrendScore":19,"compositeScore":20,"rankGlobal":10,"rankLanguage":10,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":22,"hasPages":22,"topics":24,"createdAt":10,"pushedAt":10,"updatedAt":25,"readmeContent":26,"aiSummary":27,"trendingCount":16,"starSnapshotCount":16,"syncStatus":17,"lastSyncTime":28,"discoverSource":29},72275,"Moore-AnimateAnyone","MooreThreads\u002FMoore-AnimateAnyone","MooreThreads","Character Animation (AnimateAnyone, Face Reenactment)","",null,"Python",3506,296,42,101,0,2,4,6,29.42,"Apache License 2.0",false,"master",[],"2026-06-12 02:03:01","# 🤗 Introduction  \n**update** 🔥🔥🔥 We propose a face reenactment method, based on our AnimateAnyone pipeline: Using the facial landmark of driving video to control the pose of given source image, and keeping the identity of source image. Specially, we disentangle head attitude (including eyes blink) and mouth motion from the landmark of driving video, and it can control the expression and movements of source face precisely. We release our inference codes and pretrained models of face reenactment!!\n\n\n**update** 🏋️🏋️🏋️ We release our training codes!! Now you can train your own AnimateAnyone models. See [here](#train) for more details. Have fun!\n\n**update**：🔥🔥🔥 We launch a HuggingFace Spaces demo of Moore-AnimateAnyone at [here](https:\u002F\u002Fhuggingface.co\u002Fspaces\u002Fxunsong\u002FMoore-AnimateAnyone)!!\n\nThis repository reproduces [AnimateAnyone](https:\u002F\u002Fgithub.com\u002FHumanAIGC\u002FAnimateAnyone). To align the results demonstrated by the original paper, we adopt various approaches and tricks, which may differ somewhat from the paper and another [implementation](https:\u002F\u002Fgithub.com\u002Fguoqincode\u002FOpen-AnimateAnyone). \n\nIt's worth noting that this is a very preliminary version, aiming for approximating the performance (roughly 80% under our test) showed in [AnimateAnyone](https:\u002F\u002Fgithub.com\u002FHumanAIGC\u002FAnimateAnyone). \n\nWe will continue to develop it, and also welcome feedbacks and ideas from the community. The enhanced version will also be launched on our [MoBi MaLiang](https:\u002F\u002Fmaliang.mthreads.com\u002F) AIGC platform, running on our own full-featured GPU S4000 cloud computing platform.\n\n# 📝 Release Plans\n\n- [x] Inference codes and pretrained weights of AnimateAnyone  \n- [x] Training scripts of AnimateAnyone  \n- [x] Inference codes and pretrained weights of face reenactment\n- [ ] Training scripts of face reenactment\n- [ ] Inference scripts of audio driven portrait video generation\n- [ ] Training scripts of audio driven portrait video generation\n# 🎞️ Examples \n\n## AnimateAnyone  \n\nHere are some AnimateAnyone results we generated, with the resolution of 512x768.\n\nhttps:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F138439222\u002Ff0454f30-6726-4ad4-80a7-5b7a15619057\n\nhttps:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F138439222\u002F337ff231-68a3-4760-a9f9-5113654acf48\n\n\u003Ctable class=\"center\">\n    \n\u003Ctr>\n    \u003Ctd width=50% style=\"border: none\">\n        \u003Cvideo controls autoplay loop src=\"https:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F138439222\u002F9c4d852e-0a99-4607-8d63-569a1f67a8d2\" muted=\"false\">\u003C\u002Fvideo>\n    \u003C\u002Ftd>\n    \u003Ctd width=50% style=\"border: none\">\n        \u003Cvideo controls autoplay loop src=\"https:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F138439222\u002F722c6535-2901-4e23-9de9-501b22306ebd\" muted=\"false\">\u003C\u002Fvideo>\n    \u003C\u002Ftd>\n\u003C\u002Ftr>\n\n\u003Ctr>\n    \u003Ctd width=50% style=\"border: none\">\n        \u003Cvideo controls autoplay loop src=\"https:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F138439222\u002F17b907cc-c97e-43cd-af18-b646393c8e8a\" muted=\"false\">\u003C\u002Fvideo>\n    \u003C\u002Ftd>\n    \u003Ctd width=50% style=\"border: none\">\n        \u003Cvideo controls autoplay loop src=\"https:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F138439222\u002F86f2f6d2-df60-4333-b19b-4c5abcd5999d\" muted=\"false\">\u003C\u002Fvideo>\n    \u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003C\u002Ftable>\n\n**Limitation**: We observe following shortcomings in current version:\n1. The background may occur some artifacts, when the reference image has a clean background\n2. Suboptimal results may arise when there is a scale mismatch between the reference image and keypoints. We have yet to implement preprocessing techniques as mentioned in the [paper](https:\u002F\u002Farxiv.org\u002Fpdf\u002F2311.17117.pdf).\n3. Some flickering and jittering may occur when the motion sequence is subtle or the scene is static.\n\n\n\nThese issues will be addressed and improved in the near future. We appreciate your anticipation!\n\n## Face Reenactment\n\nHere are some results we generated, with the resolution of 512x512.  \n\n\u003Ctable class=\"center\">\n    \n\u003Ctr>\n    \u003Ctd width=50% style=\"border: none\">\n        \u003Cvideo controls autoplay loop src=\"https:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F117793823\u002F8cfaddec-fb81-485e-88e9-229c0adb8bf9\" muted=\"false\">\u003C\u002Fvideo>\n    \u003C\u002Ftd>\n    \u003Ctd width=50% style=\"border: none\">\n        \u003Cvideo controls autoplay loop src=\"https:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F117793823\u002Fad06ba29-5bb2-490e-a204-7242c724ba8b\" muted=\"false\">\u003C\u002Fvideo>\n    \u003C\u002Ftd>\n\u003C\u002Ftr>\n\n\u003Ctr>\n    \u003Ctd width=50% style=\"border: none\">\n        \u003Cvideo controls autoplay loop src=\"https:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F117793823\u002F6843cdc0-830b-4f91-87c5-41cd12fbe8c2\" muted=\"false\">\u003C\u002Fvideo>\n    \u003C\u002Ftd>\n    \u003Ctd width=50% style=\"border: none\">\n        \u003Cvideo controls autoplay loop src=\"https:\u002F\u002Fgithub.com\u002FMooreThreads\u002FMoore-AnimateAnyone\u002Fassets\u002F117793823\u002Fbb9b8b74-ba4b-4f62-8fd1-7ebf140acc81\" muted=\"false\">\u003C\u002Fvideo>\n    \u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003C\u002Ftable>\n\n\n# ⚒️ Installation\n\n## Build Environtment\n\nWe Recommend a python version `>=3.10` and cuda version `=11.7`. Then build environment as follows:\n\n```shell\n# [Optional] Create a virtual env\npython -m venv .venv\nsource .venv\u002Fbin\u002Factivate\n# Install with pip:\npip install -r requirements.txt  \n# For face landmark extraction\ngit clone https:\u002F\u002Fgithub.com\u002Femilianavt\u002FOpenSeeFace.git  \n```\n\n## Download weights\n\n**Automatically downloading**: You can run the following command to download weights automatically:\n\n```shell\npython tools\u002Fdownload_weights.py\n```\n\nWeights will be placed under the `.\u002Fpretrained_weights` direcotry. The whole downloading process may take a long time.\n\n**Manually downloading**: You can also download weights manually, which has some steps:\n\n1. Download our AnimateAnyone trained [weights](https:\u002F\u002Fhuggingface.co\u002Fpatrolli\u002FAnimateAnyone\u002Ftree\u002Fmain), which include four parts: `denoising_unet.pth`, `reference_unet.pth`, `pose_guider.pth` and `motion_module.pth`.\n\n2. Download our trained [weights](https:\u002F\u002Fpan.baidu.com\u002Fs\u002F1lS5CynyNfYlDbjowKKfG8g?pwd=crci) of face reenactment, and place these weights under `pretrained_weights`.\n\n3. Download pretrained weight of based models and other components: \n    - [StableDiffusion V1.5](https:\u002F\u002Fhuggingface.co\u002Frunwayml\u002Fstable-diffusion-v1-5)\n    - [sd-vae-ft-mse](https:\u002F\u002Fhuggingface.co\u002Fstabilityai\u002Fsd-vae-ft-mse)\n    - [image_encoder](https:\u002F\u002Fhuggingface.co\u002Flambdalabs\u002Fsd-image-variations-diffusers\u002Ftree\u002Fmain\u002Fimage_encoder)\n\n4. Download dwpose weights (`dw-ll_ucoco_384.onnx`, `yolox_l.onnx`) following [this](https:\u002F\u002Fgithub.com\u002FIDEA-Research\u002FDWPose?tab=readme-ov-file#-dwpose-for-controlnet).\n\nFinally, these weights should be orgnized as follows:\n\n```text\n.\u002Fpretrained_weights\u002F\n|-- DWPose\n|   |-- dw-ll_ucoco_384.onnx\n|   `-- yolox_l.onnx\n|-- image_encoder\n|   |-- config.json\n|   `-- pytorch_model.bin\n|-- denoising_unet.pth\n|-- motion_module.pth\n|-- pose_guider.pth\n|-- reference_unet.pth\n|-- sd-vae-ft-mse\n|   |-- config.json\n|   |-- diffusion_pytorch_model.bin\n|   `-- diffusion_pytorch_model.safetensors\n|-- reenact\n|   |-- denoising_unet.pth\n|   |-- reference_unet.pth\n|   |-- pose_guider1.pth\n|   |-- pose_guider2.pth\n`-- stable-diffusion-v1-5\n    |-- feature_extractor\n    |   `-- preprocessor_config.json\n    |-- model_index.json\n    |-- unet\n    |   |-- config.json\n    |   `-- diffusion_pytorch_model.bin\n    `-- v1-inference.yaml\n```\n\nNote: If you have installed some of the pretrained models, such as `StableDiffusion V1.5`, you can specify their paths in the config file (e.g. `.\u002Fconfig\u002Fprompts\u002Fanimation.yaml`).\n\n# 🚀 Training and Inference \n\n## Inference of AnimateAnyone\n\nHere is the cli command for running inference scripts:\n\n```shell\npython -m scripts.pose2vid --config .\u002Fconfigs\u002Fprompts\u002Fanimation.yaml -W 512 -H 784 -L 64\n```\n\nYou can refer the format of `animation.yaml` to add your own reference images or pose videos. To convert the raw video into a pose video (keypoint sequence), you can run with the following command:\n\n```shell\npython tools\u002Fvid2pose.py --video_path \u002Fpath\u002Fto\u002Fyour\u002Fvideo.mp4\n```\n\n## Inference of Face Reenactment\nHere is the cli command for running inference scripts:\n\n```shell\npython -m scripts.lmks2vid --config .\u002Fconfigs\u002Fprompts\u002Finference_reenact.yaml --driving_video_path YOUR_OWN_DRIVING_VIDEO_PATH --source_image_path YOUR_OWN_SOURCE_IMAGE_PATH  \n```  \nWe provide some face images in `.\u002Fconfig\u002Finference\u002Ftalkinghead_images`, and some face videos in `.\u002Fconfig\u002Finference\u002Ftalkinghead_videos` for inference.  \n\n## \u003Cspan id=\"train\"> Training of AnimateAnyone \u003C\u002Fspan>\n\nNote: package dependencies have been updated, you may upgrade your environment via `pip install -r requirements.txt` before training.\n\n### Data Preparation\n\nExtract keypoints from raw videos: \n\n```shell\npython tools\u002Fextract_dwpose_from_vid.py --video_root \u002Fpath\u002Fto\u002Fyour\u002Fvideo_dir\n```\n\nExtract the meta info of dataset:\n\n```shell\npython tools\u002Fextract_meta_info.py --root_path \u002Fpath\u002Fto\u002Fyour\u002Fvideo_dir --dataset_name anyone \n```\n\nUpdate lines in the training config file: \n\n```yaml\ndata:\n  meta_paths:\n    - \".\u002Fdata\u002Fanyone_meta.json\"\n```\n\n### Stage1\n\nPut [openpose controlnet weights](https:\u002F\u002Fhuggingface.co\u002Flllyasviel\u002Fcontrol_v11p_sd15_openpose\u002Ftree\u002Fmain) under `.\u002Fpretrained_weights`, which is used to initialize the pose_guider.\n\nPut [sd-image-variation](https:\u002F\u002Fhuggingface.co\u002Flambdalabs\u002Fsd-image-variations-diffusers\u002Ftree\u002Fmain) under `.\u002Fpretrained_weights`, which is used to initialize unet weights.\n\nRun command:\n\n```shell\naccelerate launch train_stage_1.py --config configs\u002Ftrain\u002Fstage1.yaml\n```\n\n### Stage2\n\nPut the pretrained motion module weights `mm_sd_v15_v2.ckpt` ([download link](https:\u002F\u002Fhuggingface.co\u002Fguoyww\u002Fanimatediff\u002Fblob\u002Fmain\u002Fmm_sd_v15_v2.ckpt)) under `.\u002Fpretrained_weights`. \n\nSpecify the stage1 training weights in the config file `stage2.yaml`, for example:\n\n```yaml\nstage1_ckpt_dir: '.\u002Fexp_output\u002Fstage1'\nstage1_ckpt_step: 30000 \n```\n\nRun command:\n\n```shell\naccelerate launch train_stage_2.py --config configs\u002Ftrain\u002Fstage2.yaml\n```\n\n# 🎨 Gradio Demo\n\n**HuggingFace Demo**: We launch a quick preview demo of Moore-AnimateAnyone at [HuggingFace Spaces](https:\u002F\u002Fhuggingface.co\u002Fspaces\u002Fxunsong\u002FMoore-AnimateAnyone)!!\nWe appreciate the assistance provided by the HuggingFace team in setting up this demo.\n\nTo reduce waiting time, we limit the size (width, height, and length) and inference steps when generating videos. \n\nIf you have your own GPU resource (>= 16GB vram), you can run a local gradio app via following commands:\n\n`python app.py`\n\n# Community Contributions\n\n- Installation for Windows users: [Moore-AnimateAnyone-for-windows](https:\u002F\u002Fgithub.com\u002Fsdbds\u002FMoore-AnimateAnyone-for-windows)\n\n# 🖌️ Try on Mobi MaLiang\n\nWe will launched this model on our [MoBi MaLiang](https:\u002F\u002Fmaliang.mthreads.com\u002F) AIGC platform, running on our own full-featured GPU S4000 cloud computing platform. Mobi MaLiang has now integrated various AIGC applications and functionalities (e.g. text-to-image, controllable generation...). You can experience it by [clicking this link](https:\u002F\u002Fmaliang.mthreads.com\u002F) or scanning the QR code bellow via WeChat!\n\n\u003Cp align=\"left\">\n  \u003Cimg src=\"assets\u002Fmini_program_maliang.png\" width=\"100\n  \"\u002F>\n\u003C\u002Fp> \n\n# ⚖️ Disclaimer\n\nThis project is intended for academic research, and we explicitly disclaim any responsibility for user-generated content. Users are solely liable for their actions while using the generative model. The project contributors have no legal affiliation with, nor accountability for, users' behaviors. It is imperative to use the generative model responsibly, adhering to both ethical and legal standards.\n\n# 🙏🏻 Acknowledgements\n\nWe first thank the authors of [AnimateAnyone](). Additionally, we would like to thank the contributors to the [majic-animate](https:\u002F\u002Fgithub.com\u002Fmagic-research\u002Fmagic-animate), [animatediff](https:\u002F\u002Fgithub.com\u002Fguoyww\u002FAnimateDiff) and [Open-AnimateAnyone](https:\u002F\u002Fgithub.com\u002Fguoqincode\u002FOpen-AnimateAnyone) repositories, for their open research and exploration. Furthermore, our repo incorporates some codes from [dwpose](https:\u002F\u002Fgithub.com\u002FIDEA-Research\u002FDWPose) and [animatediff-cli-prompt-travel](https:\u002F\u002Fgithub.com\u002Fs9roll7\u002Fanimatediff-cli-prompt-travel\u002F), and we extend our thanks to them as well.\n","Moore-AnimateAnyone 是一个基于面部标志点的面部重演项目，能够通过驱动视频中的面部标志点控制给定源图像的姿态，同时保持源图像的身份特征。该项目的核心功能包括分离头部姿态（包括眨眼）和嘴部动作，并精确控制源图像的表情和动作。技术上，它使用了Python语言实现，并且已经开源了推理代码、预训练模型以及训练代码。适用于需要生成具有特定表情和动作的虚拟人物视频的场景，如动画制作、虚拟主播等领域。此外，项目团队还提供了一个HuggingFace Spaces演示，方便用户在线体验。","2026-06-11 03:41:09","high_star"]