five

MultiID-Bench

收藏
魔搭社区2025-12-05 更新2025-11-03 收录
下载链接:
https://modelscope.cn/datasets/WithAnyone/MultiID-Bench
下载链接
链接失效反馈
官方服务:
资源简介:
# MultiID-Bench in WithAnyone [![arXiv](https://img.shields.io/badge/arXiv-2510.14975-b31b1b.svg)](https://arxiv.org/abs/2510.14975) [![Project Page](https://img.shields.io/badge/Project-Page-blue.svg)](https://doby-xu.github.io/WithAnyone/) [![Code](https://img.shields.io/badge/GitHub-Code-blue.svg)](https://github.com/Doby-Xu/WithAnyone) [![HuggingFace](https://img.shields.io/badge/HuggingFace-Model-yellow.svg)](https://huggingface.co/WithAnyone/WithAnyone) [![MultiID-Bench](https://img.shields.io/badge/MultiID-Bench-Green.svg)](https://huggingface.co/datasets/WithAnyone/MultiID-Bench) [![MultiID-2M](https://img.shields.io/badge/MultiID_2M-Dataset-Green.svg)](https://huggingface.co/datasets/WithAnyone/MultiID-2M) [![Demo](https://img.shields.io/badge/HuggingFace-Demo-Yellow.svg)](https://huggingface.co/spaces/WithAnyone/WithAnyone_demo) The MultiID-Bench dataset is a benchmark introduced in the paper [WithAnyone: Towards Controllable and ID Consistent Image Generation](https://huggingface.co/papers/2510.14975). It is specifically tailored for multi-person scenarios in text-to-image research, providing diverse references for each identity. This dataset aims to quantify "copy-paste" artifacts and evaluate the trade-off between identity fidelity and variation, enabling models like WithAnyone to achieve controllable and identity-consistent image generation. ## Links * **Paper:** [WithAnyone: Towards Controllable and ID Consistent Image Generation](https://huggingface.co/papers/2510.14975) * **Project Page:** https://doby-xu.github.io/WithAnyone/ * **GitHub Repository:** https://github.com/Doby-Xu/WithAnyone * **WithAnyone Model:** https://huggingface.co/WithAnyone/WithAnyone * **WithAnyone Demo:** https://huggingface.co/spaces/WithAnyone/WithAnyone_demo ## Sample Usage This section provides instructions for downloading the MultiID-Bench dataset and preparing it for evaluation. ### Download the Dataset You can download the MultiID-Bench dataset using the Hugging Face CLI: ```bash huggingface-cli download WithAnyone/MultiID-Bench --repo-type dataset --local-dir <path to MultiID-Bench directory> ``` ### Prepare Data for Evaluation After downloading, if your dataset is in a `parquet` file format, you can convert it into a structured directory of images and JSON metadata using the `parquet2bench.py` script provided in the GitHub repository. First, ensure you have cloned the GitHub repository: ```bash git clone https://github.com/Doby-Xu/WithAnyone cd WithAnyone ``` Then, convert the downloaded parquet file: ```bash python MultiID_Bench/parquet2bench.py --parquet <path to downloaded parquet file> --output_dir <root directory to save the processed data> ``` The output directory will contain a structure like this, with subfolders for each ID and `meta.json` files containing prompts: ``` root/ ├── id1/ │ ├── out.jpg │ ├── ori.jpg │ ├── ref_1.jpg │ ├── ref_2.jpg │ ├── ref_3.jpg │ ├── ref_4.jpg │ └── meta.json │ ├── id2/ │ ├── out.jpg │ ├── ori.jpg │ ├── ref_1.jpg │ ├── ref_2.jpg │ ├── ref_3.jpg │ ├── ref_4.jpg │ └── meta.json │ └── ... ``` The `meta.json` file should contain the prompt used to generate the image, in the following format: ```json { "prompt": "a photo of a person with blue hair and glasses" } ``` ### Environment Setup for Evaluation To run the evaluation scripts, you need to install several packages. Besides the `requirements.txt` from the [GitHub repo](https://github.com/Doby-Xu/WithAnyone), install the following: ```bash pip install aesthetic-predictor-v2-5 pip install facexlib pip install colorama pip install pytorch_lightning git clone https://github.com/timesler/facenet-pytorch.git facenet_pytorch # in MultiID_Bench/ mkdir pretrained ``` You will also need the following models to run the evaluation: CLIP, arcface, aesthetic-v2.5, adaface, and facenet. The first three will be automatically downloaded. For `adaface`, download `adaface_ir50_ms1mv2.ckpt` from [this link](https://drive.google.com/file/d/1eUaSHG4pGlIZK7hBkqjyp2fc2epKoBvI/view?usp=sharing) and place it in the `pretrained` directory. ### Run Evaluation You can run the evaluation script as follows, using the prepared data: ```python from eval import BenchEval_Geo def run(): evaler = BenchEval_Geo( target_dir="<root directory mentioned above>", output_dir="<output directory to save the evaluation results>", ori_file_name="ori.jpg", # the name of the ground truth image file output_file_name="out.jpg", # the name of the generated image file ref_1_file_name="ref_1.jpg", # the name of the first reference image file ref_2_file_name="ref_2.jpg", # the name of the second reference image file # ref_2_file_name=None, # if you only have one reference image, set ref_2_file_name to None # ref_3_file_name="ref_3.jpg", # the name of the third reference # ref_4_file_name="ref_4.jpg", # the name of the fourth reference, caption_keyword="prompt", # the keyword to extract the prompt from meta.json names_keyword=None ) evaler() if __name__ == "__main__": run() ``` ## License and Disclaimer The **code** of WithAnyone is released under the [**Apache License 2.0**](https://www.apache.org/licenses/LICENSE-2.0), while the WithAnyone **model and associated datasets** are made available **solely for non-commercial academic research purposes**. - **License Terms:** The WithAnyone model is distributed under the [**FLUX.1 [dev] Non-Commercial License v1.1.1**](https://huggingface.co/black-forest-labs/FLUX.1-dev/blob/main/LICENSE.md). All underlying base models remain governed by their respective original licenses and terms, which shall continue to apply in full. Users must comply with all such applicable licenses when using this project. - **Permitted Use:** This project may be used for lawful academic research, analysis, and non-commercial experimentation only. Any form of commercial use, redistribution for profit, or application that violates applicable laws, regulations, or ethical standards is strictly prohibited. - **User Obligations:** Users are solely responsible for ensuring that their use of the model and dataset complies with all relevant laws, regulations, institutional review policies, and third-party license terms. - **Disclaimer of Liability:** The authors, developers, and contributors make no warranties, express or implied, regarding the accuracy, reliability, or fitness of this project for any particular purpose. They shall not be held liable for any damages, losses, or legal claims arising from the use or misuse of this project, including but not limited to violations of law or ethical standards by end users. - **Acceptance of Terms:** By downloading, accessing, or using this project, you acknowledge and agree to be bound by the applicable license terms and legal requirements, and you assume full responsibility for all consequences resulting from your use. ## Acknowledgement We thank the following prior art for their excellent open source work: - [PuLID](https://github.com/ToTheBeginning/PuLID) - [UNO](https://github.com/bytedance/UNO) - [UniPortrait](https://github.com/junjiehe96/UniPortrait) - [InfiniteYou](https://github.com/bytedance/InfiniteYou) - [DreamO](https://github.com/bytedance/DreamO) - [UMO](https://github.com/bytedance/UMO) ## Citation If you find this project useful in your research, please consider citing: ```bibtex @article{xu2025withanyone, title={WithAnyone: Towards Controllable and ID-Consistent Image Generation}, author={Hengyuan Xu and Wei Cheng and Peng Xing and Yixiao Fang and Shuhan Wu and Rui Wang and Xianfang Zeng and Gang Yu and Xinjun Ma and Yu-Gang Jiang}, journal={arXiv preprint arxiv:2510.14975}, year={2025} } ```

# MultiID-Bench in WithAnyone [![arXiv论文](https://img.shields.io/badge/arXiv-2510.14975-b31b1b.svg)](https://arxiv.org/abs/2510.14975) [![项目主页](https://img.shields.io/badge/Project-Page-blue.svg)](https://doby-xu.github.io/WithAnyone/) [![GitHub代码](https://img.shields.io/badge/GitHub-Code-blue.svg)](https://github.com/Doby-Xu/WithAnyone) [![HuggingFace模型](https://img.shields.io/badge/HuggingFace-Model-yellow.svg)](https://huggingface.co/WithAnyone/WithAnyone) [![MultiID-Bench](https://img.shields.io/badge/MultiID-Bench-Green.svg)](https://huggingface.co/datasets/WithAnyone/MultiID-Bench) [![MultiID-2M数据集](https://img.shields.io/badge/MultiID_2M-Dataset-Green.svg)](https://huggingface.co/datasets/WithAnyone/MultiID-2M) [![HuggingFace演示](https://img.shields.io/badge/HuggingFace-Demo-Yellow.svg)](https://huggingface.co/spaces/WithAnyone/WithAnyone_demo) MultiID-Bench数据集是论文《WithAnyone:面向可控且身份一致的图像生成》(WithAnyone: Towards Controllable and ID Consistent Image Generation)中提出的基准测试集。本数据集专为文本到图像研究中的多人场景定制,为每个身份提供多样化参考样本,旨在量化"复制粘贴"伪影(copy-paste artifacts),并评估身份保真度与多样性之间的权衡,助力WithAnyone等模型实现可控且身份一致的图像生成。 ## 链接 * **论文:** [WithAnyone:面向可控且身份一致的图像生成](https://huggingface.co/papers/2510.14975) * **项目主页:** https://doby-xu.github.io/WithAnyone/ * **GitHub代码仓库:** https://github.com/Doby-Xu/WithAnyone * **WithAnyone模型:** https://huggingface.co/WithAnyone/WithAnyone * **WithAnyone演示页面:** https://huggingface.co/spaces/WithAnyone/WithAnyone_demo ## 样本使用指南 ### 下载数据集 本章节提供MultiID-Bench数据集的下载与评估准备指南。 你可以通过Hugging Face命令行工具下载MultiID-Bench数据集: bash huggingface-cli download WithAnyone/MultiID-Bench --repo-type dataset --local-dir <MultiID-Bench数据集目录路径> ### 准备评估用数据 下载完成后,若数据集为`parquet`文件格式,可使用GitHub仓库中提供的`parquet2bench.py`脚本将其转换为结构化的图像目录与JSON元数据文件。 首先,请确保已克隆GitHub仓库: bash git clone https://github.com/Doby-Xu/WithAnyone cd WithAnyone 随后执行以下命令转换下载得到的parquet文件: bash python MultiID_Bench/parquet2bench.py --parquet <下载的parquet文件路径> --output_dir <保存处理后数据的根目录> 输出目录将包含如下结构,每个身份对应一个子文件夹,以及存储提示词的`meta.json`文件: root/ ├── id1/ │ ├── out.jpg │ ├── ori.jpg │ ├── ref_1.jpg │ ├── ref_2.jpg │ ├── ref_3.jpg │ ├── ref_4.jpg │ └── meta.json │ ├── id2/ │ ├── out.jpg │ ├── ori.jpg │ ├── ref_1.jpg │ ├── ref_2.jpg │ ├── ref_3.jpg │ ├── ref_4.jpg │ └── meta.json │ └── ... `meta.json`文件应包含生成图像所用的提示词,格式如下: json { "prompt": "蓝发戴眼镜的人物照片" } ### 评估环境配置 若要运行评估脚本,需安装多个依赖包。除GitHub仓库中`requirements.txt`指定的依赖外,还需安装以下包: bash pip install aesthetic-predictor-v2-5 pip install facexlib pip install colorama pip install pytorch_lightning git clone https://github.com/timesler/facenet-pytorch.git facenet_pytorch # 进入MultiID_Bench目录 mkdir pretrained 运行评估还需以下模型:CLIP、arcface、aesthetic-v2.5、adaface与facenet。其中前三者将自动下载。对于`adaface`模型,请从[该链接](https://drive.google.com/file/d/1eUaSHG4pGlIZK7hBkqjyp2fc2epKoBvI/view?usp=sharing)下载`adaface_ir50_ms1mv2.ckpt`,并将其放置于`pretrained`目录中。 ### 运行评估 你可通过如下方式运行评估脚本,使用预处理完成的数据: python from eval import BenchEval_Geo def run(): evaler = BenchEval_Geo( target_dir="<前文提及的根目录路径>", output_dir="<保存评估结果的输出目录>", ori_file_name="ori.jpg", # 基准图像文件的文件名 output_file_name="out.jpg", # 生成图像文件的文件名 ref_1_file_name="ref_1.jpg", # 第一幅参考图像文件的文件名 ref_2_file_name="ref_2.jpg", # 第二幅参考图像文件的文件名 # ref_2_file_name=None, # 若仅拥有一幅参考图像,可将ref_2_file_name设为None # ref_3_file_name="ref_3.jpg", # 第三幅参考图像的文件名 # ref_4_file_name="ref_4.jpg", # 第四幅参考图像的文件名 caption_keyword="prompt", # 从meta.json中提取提示词的关键字 names_keyword=None ) evaler() if __name__ == "__main__": run() ## 许可协议与免责声明 WithAnyone的**代码**采用[**Apache许可证2.0**](https://www.apache.org/licenses/LICENSE-2.0)协议发布,而WithAnyone的**模型及相关数据集**仅可用于非商业性学术研究。 - **许可条款:** WithAnyone模型采用[**FLUX.1 [dev] 非商业许可v1.1.1**](https://huggingface.co/black-forest-labs/FLUX.1-dev/blob/main/LICENSE.md)协议分发。所有底层基础模型仍受其各自原始许可条款约束,需一并遵守。使用本项目时,用户必须遵守所有适用的许可协议。 - **允许使用范围:** 本项目仅可用于合法的学术研究、分析与非商业性实验。任何形式的商业使用、为获利而进行的再分发,或违反适用法律、法规及伦理标准的应用均严格禁止。 - **用户义务:** 用户需自行确保其对模型与数据集的使用符合所有相关法律、法规、机构审查政策及第三方许可条款。 - **责任免责声明:** 作者、开发者及贡献者不对本项目在任何特定用途下的准确性、可靠性或适用性作出任何明示或暗示的保证。对于因使用或不当使用本项目而产生的任何损害、损失或法律索赔(包括但不限于终端用户违反法律或伦理标准的行为),其均不承担责任。 - **条款接受:** 通过下载、访问或使用本项目,即表示您承认并同意受适用许可条款与法律要求的约束,并为您的使用所产生的所有后果承担全部责任。 ## 致谢 感谢以下开源项目的优秀工作: - [PuLID](https://github.com/ToTheBeginning/PuLID) - [UNO](https://github.com/bytedance/UNO) - [UniPortrait](https://github.com/junjiehe96/UniPortrait) - [InfiniteYou](https://github.com/bytedance/InfiniteYou) - [DreamO](https://github.com/bytedance/DreamO) - [UMO](https://github.com/bytedance/UMO) ## 引用 若本项目对您的研究有所帮助,请引用如下文献: bibtex @article{xu2025withanyone, title={WithAnyone: Towards Controllable and ID-Consistent Image Generation}, author={Hengyuan Xu and Wei Cheng and Peng Xing and Yixiao Fang and Shuhan Wu and Rui Wang and Xianfang Zeng and Gang Yu and Xinjun Ma and Yu-Gang Jiang}, journal={arXiv preprint arxiv:2510.14975}, year={2025} }
提供机构:
maas
创建时间:
2025-10-21
5,000+
优质数据集
54 个
任务类型
进入经典数据集
二维码
社区交流群

面向社区/商业的数据集话题

二维码
科研交流群

面向高校/科研机构的开源数据集话题

数据驱动未来

携手共赢发展

商业合作