# Unity Perception

**Unity Perception**（包名 `com.unity.perception`）是[Unity](https://www.edgepedia.org/zh/unity-game-engine)游戏引擎的一款开源工具包，用于生成大规模、自动标注的合成数据集，以训练和验证计算机视觉模型。该工具包由[Unity Technologies](https://www.edgepedia.org/zh/unity-technologies)的计算机视觉团队开发，它将渲染出的相机图像与真值标注（如边界框、分割掩码和关键点）配对，并集成了域随机化功能，使生成的场景在光照、材质和物体摆放上有所变化。<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup><sup> • </sup><sup>[2](https://arxiv.org/abs/2107.04259)</sup>

| 关键事实 | 详情 |
|---|---|
| 用途 | 用于为计算机视觉训练和验证生成大规模合成数据集的工具包，侧重于基于相机的用例<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup> |
| 开发者/许可证 | Unity Technologies（Unity Computer Vision）；Apache License 2.0<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup> |
| 研究论文 | 《Unity Perception: Generate Synthetic Data for Computer Vision》，arXiv:2107.04259（2021）<sup>[2](https://arxiv.org/abs/2107.04259)</sup> |
| 核心组件 | 标注（Labeling）、标签配置（Label Config）、感知相机（Perception Camera）、数据集捕获（Dataset Capture）、随机化（Randomization）和输出端点（Solo、Perception、无输出）<sup>[3](https://github.com/Unity-Technologies/com.unity.perception/blob/main/com.unity.perception/Documentation~/index.md)</sup> |
| 最终版本 | 1.0.0-preview.1，支持Unity Editor 2021.3+和2022.1+；不再支持Unity 2020<sup>[4](https://github.com/Unity-Technologies/com.unity.perception/releases)</sup> |
| 状态 | 已停止维护，Unity不再提供支持；社区支持通过GitHub issues进行<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup> |
| 输出工具 | pysolotools Python包，用于解析SOLO数据集并将其转换为COCO格式<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup> |

## 目的与方法

训练数据是计算机视觉的一项核心成本：随着任务从标注整帧图像转向标注物体和单个像素，每个样本的标注工作量不断增加。Perception工具包通过在模拟3D环境中生成图像来应对这一问题——在该环境中，每个物体的真实位置、类别和姿态都精确已知，因此真值可以自动生成，而无需人工标注。作者将目标描述为：通过易用且高度可定制的工具集，简化和加速合成数据集的生成。<sup>[2](https://arxiv.org/abs/2107.04259)</sup>

该工具包文档强调的第二个优势是可复用性：一次构建的合成环境可以通过不同配置生成多个标注数据集，同一场景几何结构可支持重复实验。<sup>[5](https://sauravdhakad.com/pdfs/unity_perception.pdf)</sup>

## 核心组件

该工具包围绕参考手册中记录的一小组功能进行组织：<sup>[3](https://github.com/Unity-Technologies/com.unity.perception/blob/main/com.unity.perception/Documentation~/index.md)</sup>

- **标注（Labeling）** 将一组标签附加到GameObject及其子物体上，定义标注系统在场景中识别的内容。
- **标签配置（Label Config）** 是一种资产，定义用于真值生成的标签分类体系。
- **感知相机（Perception Camera）** 从Unity Camera捕获RGB图像和真值，使用可插拔的标注器处理特定标注类型，如2D和3D边界框、实例分割和语义分割以及关键点。<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup>
- **数据集捕获（Dataset Capture）** 按配置的速率触发传感器并将结果（包括JSON元数据）写入数据集。
- **随机化（Randomization）** 提供在模拟中应用域随机化原则的工具集。
- **输出端点（Output endpoints）** 将生成的数据交付给用户；支持的端点包括Solo端点（默认）、Perception端点和无输出。<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup>

1.0.0-preview.1版本将默认序列化格式从工具包自有的perception格式改为Solo，并新增了路径追踪的帧累积、3D边界框标注器对SkinnedMeshRenderer的完整支持、元数据标注器、可恢复的数据集生成，以及允许不同相机传感器模型和投影的传感器类型字段等功能。<sup>[4](https://github.com/Unity-Technologies/com.unity.perception/releases)</sup>

## 域随机化

随机化器在生成的帧之间改变场景参数，使基于输出训练的模型能够遇到接近现实的变化。在Unity与Kitech团队提出的制造数字孪生流程中，基于Perception工具包构建的域随机化模型为光照、材质和相机定义了参数范围和采样规则，围绕从点云数据重建的精确对齐基线场景生成逼真的变化。<sup>[6](https://unity.com/resources/kitech-synthetic-data-pipeline-manufacturing-ai)</sup>

随机化器是用户可扩展的C#组件。发布说明显示API随时间演进：随机化工具集在0.7.0-preview.1中移出了Unity的Experimental命名空间，而`GameObjectParameter`等专用参数类后来被弃用，改用泛型的`CategoricalParameter`模板。<sup>[4](https://github.com/Unity-Technologies/com.unity.perception/releases)</sup>

## 示例项目与数据集

Unity发布了多个基于该工具包构建的演示项目：<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup>

- **Synthetic Homes** 提供一个包含10万张图像的标注合成住宅室内数据集，用于训练计算机视觉模型，并附带一个可配置的独立Unity应用程序来生成此类数据集。
- **People Sans People** 是一个以人为中心、保护隐私的合成数据生成器，具有参数化光照和相机系统，可从适用于模拟的3D人体资产生成2D和3D边界框、实例分割和语义分割以及COCO姿态标签。
- **SynthDet** 是一个在合成数据上训练2D物体检测模型的端到端解决方案。
- **机器人物体姿态估计演示** 展示了模拟机械臂的抓取放置，将Perception数据收集与ROS集成、[URDF](https://www.edgepedia.org/zh/urdf)模型导入以及深度学习模型训练和部署相结合。

在机器人演示中，基于Perception生成数据训练的模型仅凭感知数据即可预测立方体的姿态，配备Robotiq 2F-140夹爪的模拟UR3机械臂在Unity模拟测试中以89%的成功率可靠地抓取了立方体。<sup>[7](https://unity.com/blog/industry/teaching-robots-to-see-with-unity)</sup>一个相关的Unity项目使用该工具包通过虚拟OAK-D相机收集合成训练数据，在几分钟内生成了包含自动真值边界框标注的大型3D模型数据集。<sup>[8](https://unity.com/blog/industry/creating-and-training-a-robot-digital-twin)</sup>

## 在研究和工业中的应用

该工具包已被学术和工业流程采用。一个[Roboflow](https://www.edgepedia.org/zh/roboflow)项目使用Perception生成随机电子电路的合成图像，用于训练模型检测面包板上的电阻和导线，报告称所得数据集所需的人工标注远少于全真实方法，而训练出的模型泛化能力足以加速剩余的人工标注工作。<sup>[9](https://roboflow.com/blog/synthetic-data-breadboards)</sup>已发表的研究使用Perception构建以人为中心的合成数据集用于主动机器人视觉<sup>[10](https://www.sciencedirect.com/science/article/abs/pii/S0167865524000205)</sup>，在外科手术场景中实现可复现的合成数据生成并自动标注边界框和实例分割<sup>[11](https://d197for5662m48.cloudfront.net/documents/publicationstatus/253556/preprint_pdf/acb3c8575a893cefbaed2257f816d16e.pdf)</sup>，以及用于基于无人机的车辆检测研究<sup>[12](https://essay.utwente.nl/106610/1/Song_MSc_ITC.pdf)</sup>。

与NVIDIA Omniverse Replicator等替代方案相比，第三方评估认为Perception在快速原型设计方面表现出色，这得益于其基于标注器的标注系统和内置随机化工具。<sup>[13](https://inferensys.com/differences/world-model-and-simulation-platforms-for-agent-risk-testing/sim-to-real-transfer-toolchains/nvidia-replicator-vs-unity-perception-synthetic-data-sdk)</sup>

## 状态

仓库的README声明该项目已停止维护，Unity不再提供支持，并指引用户前往GitHub issues页面寻求社区支持。该仓库仍以Apache 2.0许可证公开可用，在最后一次抓取时约有995个星标、187个复刻和1,439次提交。<sup>[1](https://github.com/Unity-Technologies/com.unity.perception)</sup>最后一个标记版本1.0.0-preview.1仍为预发布版；它取消了对Unity 2020的支持，面向Editor 2021.3+和2022.1+版本。<sup>[4](https://github.com/Unity-Technologies/com.unity.perception/releases)</sup>

## References

1. [Perception Package, Unity-Technologies/com.unity.perception, GitHub](https://github.com/Unity-Technologies/com.unity.perception)
2. [Unity Perception: Generate Synthetic Data for Computer Vision, arXiv:2107.04259](https://arxiv.org/abs/2107.04259)
3. [Perception Package documentation (index.md), GitHub](https://github.com/Unity-Technologies/com.unity.perception/blob/main/com.unity.perception/Documentation~/index.md)
4. [Releases, Unity-Technologies/com.unity.perception, GitHub](https://github.com/Unity-Technologies/com.unity.perception/releases)
5. [Unity Perception paper PDF (S. Dhakad mirror)](https://sauravdhakad.com/pdfs/unity_perception.pdf)
6. [Synthetic data pipeline for manufacturing AI in Unity, Unity](https://unity.com/resources/kitech-synthetic-data-pipeline-manufacturing-ai)
7. [Teaching robots to see with Unity, Unity blog](https://unity.com/blog/industry/teaching-robots-to-see-with-unity)
8. [Made with Unity: Creating and training a robot digital twin, Unity blog](https://unity.com/blog/industry/creating-and-training-a-robot-digital-twin)
9. [How I Used Synthetic Data with Unity Perception to Minimize Annotation Time, Roboflow](https://roboflow.com/blog/synthetic-data-breadboards)
10. [A synthetic human-centric dataset generation pipeline for active robotic vision, ScienceDirect](https://www.sciencedirect.com/science/article/abs/pii/S0167865524000205)
11. [A Reproducible Framework for Synthetic Data Generation (preprint)](https://d197for5662m48.cloudfront.net/documents/publicationstatus/253556/preprint_pdf/acb3c8575a893cefbaed2257f816d16e.pdf)
12. [Using synthetic data to improve UAV-based vehicle detection (MSc thesis, University of Twente)](https://essay.utwente.nl/106610/1/Song_MSc_ITC.pdf)
13. [NVIDIA Replicator vs Unity Perception: Synthetic Data SDK, Inference Systems](https://inferensys.com/differences/world-model-and-simulation-platforms-for-agent-risk-testing/sim-to-real-transfer-toolchains/nvidia-replicator-vs-unity-perception-synthetic-data-sdk)

---
*Initially written Oct 15, 2026*

Topic: 技术与人造世界 › 工程与制造 › 机器人技术与自动化 › Robot software, AI, and methods › Simulation, physics engines, and digital twins

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/unity-perception

English original: https://www.edgepedia.org/unity-perception
