NVIDIA Isaac Sim 6.0 合成数据生成:DMS 训练数据自动化管道详解

NVIDIA Isaac Sim 6.0 合成数据生成:DMS 训练数据自动化管道详解

核心要点

NVIDIA Isaac Sim 6.0 发布全新 Isaacsim.Replicator.Agent (IRA) 扩展:

  • 零代码配置:YAML 文件定义场景、角色、传感器、输出格式
  • GPU 加速:实时生成高质量合成数据
  • SimReady 资产:预置座舱、人体模型、摄像头资产
  • 支持行为树:角色行为可编程化(疲劳、分心、OOP 等场景)
  • 自动标注:2D/3D 边界框、骨骼关键点、语义分割一键输出

IRA 架构概述

1. 核心扩展组合

IRA 由三个扩展协同工作:

扩展 功能 用途
Omni.Metropolis.Pipeline (OMP) 场景管理、导航网格 座舱环境加载
Isaacsim.Replicator.Agent (IRA) 角色(人类/机器人)控制 DMS 场景角色动画
Isaacsim.Anim.Robot.Core (IAR) 机器人动画控制 座舱内机器人测试

2. 数据生成流程

graph LR
    A[YAML配置文件] --> B[加载场景USD]
    B --> C[生成角色+行为]
    C --> D[配置传感器]
    D --> E[运行仿真]
    E --> F[捕获数据]
    F --> G[自动标注]
    G --> H[输出数据集]
    
    subgraph 输出内容
        H1[RGB图像]
        H2[深度图]
        H3[语义分割]
        H4[2D/3D边界框]
        H5[骨骼关键点]
        H6[动作标签]
    end
    
    H --> H1
    H --> H2
    H --> H3
    H --> H4
    H --> H5
    H --> H6

YAML 配置文件详解

1. 配置文件结构

IRA 配置文件采用 YAML 格式,包含以下顶级节点:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# IRA 配置文件示例(用于 DMS 训练数据生成)

# 1. 环境配置
environment:
usd_path: "omniverse://localhost/Projects/cabin_scene.usd"
navmesh:
auto_bake: false

# 2. 角色配置(人类驾驶员)
character:
- name: "driver_normal"
group: "normal_driving"
seed: 42
behaviors:
- type: "Idle"
weight: 0.3
- type: "LookAround"
weight: 0.2
- type: "AdjustSeat"
weight: 0.1

# 3. 传感器配置(DMS 摄像头)
sensor:
- name: "dms_camera"
type: "Camera"
position: [0.0, -0.5, 1.2] # 方向盘上方
rotation: [0.0, 15.0, 0.0] # 朝向驾驶员面部
resolution: [1920, 1080]
fps: 30

# 4. 数据生成配置
replicator:
output_dir: "~/dms_synthetic_data"
duration: 60.0 # 秒
writers:
- type: "IRABasicWriter"
annotators:
- "rgb"
- "distance_to_camera"
- "semantic_segmentation"
- "object_detection"

2. 角色行为配置(核心)

IRA 支持两种行为系统:

Routine-Trigger 系统(稳定版)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
character:
- name: "driver_fatigue"
group: "fatigue_scenario"
seed: 100

# 日常行为(权重随机)
routines:
- behavior: "Idle"
weight: 0.4
- behavior: "LookAround"
weight: 0.3
- behavior: "Blink"
weight: 0.2

# 触发行为(特定场景)
triggers:
- name: "fatigue_yawn"
priority: 1
behaviors:
- "Yawn"
- "CloseEyes"
- "HeadDrop"

# 触发条件:时间 > 30s
condition:
type: "TimeElapsed"
threshold: 30.0

Behavior Tree 系统(实验版)

1
2
3
4
5
6
7
8
9
10
11
12
character:
- name: "driver_distraction"
group: "distraction_scenario"

# 行为树配置
behavior_tree:
file: "behaviors/distraction_tree.json"
overrides:
- node: "CheckPhone"
params:
duration: 5.0
probability: 0.3

DMS 场景生成代码示例

1. 疲劳场景生成

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
"""
使用 Isaac Sim IRA 生成 DMS 疲劳检测训练数据

场景类型:
- 打哈欠(Yawn)
- 闭眼(CloseEyes)
- 头部下垂(HeadDrop)
- 眼神涣散(GazeAversion)
"""

import os
from isaacsim import SimulationApp

# 启动应用(headless 模式)
simulation_app = SimulationApp({"headless": True})

from isaacsim.core.utils.extensions import enable_extension

# 启用 IRA 扩展
enable_extension("isaacsim.replicator.agent.core")
simulation_app.update()

from isaacsim.replicator.agent.core import api as IRA

# 配置疲劳场景
fatigue_config = {
"environment": {
"usd_path": "/path/to/cabin_interior.usd"
},
"character": [
{
"name": "driver_fatigue",
"group": "fatigue_test",
"seed": 42,
"behaviors": [
{
"type": "Idle",
"weight": 0.3,
"params": {"duration_range": [2.0, 5.0]}
},
{
"type": "Yawn",
"weight": 0.2,
"params": {"intensity": "medium"}
},
{
"type": "CloseEyes",
"weight": 0.15,
"params": {"duration_range": [1.0, 3.0]}
},
{
"type": "HeadDrop",
"weight": 0.1,
"params": {"angle_range": [15.0, 30.0]}
},
{
"type": "Blink",
"weight": 0.15,
"params": {"rate_range": [10, 20]} # 次/分钟
}
]
}
],
"sensor": [
{
"name": "dms_rgb_ir",
"type": "Camera",
"position": [0.0, -0.5, 1.2],
"rotation": [0.0, 15.0, 0.0],
"resolution": [1920, 1080],
"fps": 30,
"modalities": ["rgb", "infrared"] # RGB + 红外
}
],
"replicator": {
"output_dir": "~/dms_fatigue_dataset",
"duration": 120.0,
"writers": [
{
"type": "IRABasicWriter",
"annotators": [
"rgb",
"instance_segmentation",
"object_detection",
"skeleton_2d",
"skeleton_3d"
]
}
]
}
}

async def generate_fatigue_dataset():
"""生成疲劳检测训练数据集"""

# 加载配置
IRA.set_config(fatigue_config)

# 设置仿真
await IRA.setup_simulation()

# 运行数据生成
await IRA.start_data_generation_async(will_wait_until_complete=True)

print("疲劳数据集生成完成!")
print(f"输出位置: {fatigue_config['replicator']['output_dir']}")

# 运行
import omni.kit.app
simulation_app.run_coroutine(generate_fatigue_dataset())
simulation_app.close()

2. 分心场景生成

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
"""
使用 Isaac Sim IRA 生成 DMS 分心检测训练数据

场景类型:
- 手机使用(PhoneUse)
- 侧向看(LookSide)
- 调整收音机(AdjustRadio)
- 喝水(DrinkWater)
"""

distraction_config = {
"character": [
{
"name": "driver_distraction",
"group": "distraction_test",
"seed": 100,
"behaviors": [
{
"type": "PhoneUse",
"weight": 0.25,
"params": {
"action": "texting", # 打字/通话/浏览
"hand": "right",
"duration_range": [3.0, 10.0]
}
},
{
"type": "LookSide",
"weight": 0.2,
"params": {
"direction": "right", # 左/右/后视镜
"duration_range": [2.0, 5.0]
}
},
{
"type": "AdjustRadio",
"weight": 0.15,
"params": {
"hand": "right",
"duration_range": [1.0, 3.0]
}
},
{
"type": "DrinkWater",
"weight": 0.1,
"params": {
"hand": "right",
"duration_range": [2.0, 5.0]
}
}
]
}
],
"sensor": [
{
"name": "dms_camera",
"type": "Camera",
"position": [0.0, -0.5, 1.2],
"resolution": [1920, 1080],
"fps": 30
}
],
"replicator": {
"output_dir": "~/dms_distraction_dataset",
"duration": 180.0,
"writers": [
{
"type": "IRABasicWriter",
"annotators": [
"rgb",
"object_detection",
"skeleton_2d",
"skeleton_3d",
"action_label" # 动作标签
]
}
]
}
}

3. OOP(异常姿态)场景生成

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
"""
使用 Isaac Sim IRA 生成 OOP 异常姿态检测训练数据

场景类型:
- 脚踩仪表板(FeetOnDashboard)
- 座椅过度后仰(SeatRecline)
- 侧向躺卧(SideLying)
- 儿童站立(ChildStanding)
"""

oop_config = {
"character": [
{
"name": "passenger_oop",
"group": "oop_test",
"seed": 200,
"behaviors": [
{
"type": "FeetOnDashboard",
"weight": 0.3,
"params": {
"duration_range": [5.0, 15.0]
}
},
{
"type": "SeatRecline",
"weight": 0.25,
"params": {
"angle_range": [30.0, 60.0], # 后仰角度
"duration_range": [10.0, 30.0]
}
},
{
"type": "SideLying",
"weight": 0.2,
"params": {
"side": "right",
"duration_range": [10.0, 60.0]
}
}
]
}
],
"sensor": [
{
"name": "oms_camera",
"type": "Camera",
"position": [0.0, 0.5, 1.5], # 前排乘客位置
"rotation": [0.0, -15.0, 0.0], # 朝向乘客
"resolution": [1920, 1080],
"fps": 30
}
],
"replicator": {
"output_dir": "~/oms_oop_dataset",
"duration": 300.0,
"writers": [
{
"type": "IRABasicWriter",
"annotators": [
"rgb",
"depth",
"semantic_segmentation",
"object_detection",
"skeleton_3d",
"pose_label" # 姿态标签
]
}
]
}
}

输出数据格式

IRA 默认输出结构:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
~/dms_synthetic_data/
├── dms_camera/
│ ├── rgb/
│ │ ├── rgb_0000.png
│ │ ├── rgb_0001.png
│ │ └── ...
│ ├── depth/
│ │ ├── depth_0000.png
│ │ └── ...
│ ├── semantic_segmentation/
│ │ ├── semantic_0000.png
│ │ └── ...
│ ├── camera_params/
│ │ ├── camera_params_0000.json
│ │ └── ...
│ ├── object_detection.json # 边界框 + 骨骼 + 动作
│ └── metadata.json

object_detection.json 格式

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
{
"frames": [
{
"frame_id": 30,
"timestamp": 1.0,
"actors": [
{
"name": "driver_fatigue",
"group": "fatigue_test",
"bbox_2d": [512, 384, 1024, 768],
"bbox_3d": {
"center": [0.0, -0.5, 0.8],
"size": [0.4, 0.3, 0.6]
},
"skeleton_2d": [
{"name": "head", "position": [768, 400], "confidence": 0.95},
{"name": "left_eye", "position": [730, 380], "confidence": 0.90},
{"name": "right_eye", "position": [806, 380], "confidence": 0.90},
// ... 17 个关键点
],
"skeleton_3d": [
{"name": "head", "position": [0.0, -0.3, 1.1], "confidence": 0.92},
// ... 17 个关键点
],
"action": {
"name": "Yawn",
"duration": 2.5,
"intensity": 0.8
}
}
]
}
]
}

与 Anyverse/SkyEngine 对比

特性 NVIDIA Isaac Sim IRA Anyverse SkyEngine
开源 ✅ 免费 ❌ 商业 ❌ 商业
座舱资产 ✅ SimReady 资产库 ✅ 预置资产 ✅ 预置资产
行为树 ✅ 支持 ⚠️ 有限 ⚠️ 有限
GPU加速 ✅ RTX渲染
自动标注 ✅ 多种标注
SDK ✅ Python API ⚠️ 有限
成本 免费 高(年费) 高(年费)

IMS 开发优先级

任务 Isaac Sim 支持 IMS优先级 开发周期
疲劳场景数据生成 ✅ 完整支持 P0 1-2周
分心场景数据生成 ✅ 完整支持 P0 1-2周
OOP场景数据生成 ✅ 完整支持 P1 2-4周
CPD儿童场景 ⚠️ 需定制资产 P1 4-6周
安全带误用场景 ⚠️ 需定制行为 P2 4-8周

数据来源


IMS 开发启示

  1. 零代码数据生成: IRA 的 YAML 配置方式大幅降低数据生成门槛,IMS 开发者无需编程即可生成训练数据
  2. 行为树灵活性: 支持复杂场景(疲劳、分心、OOP)的行为编程,比传统随机采样更可控
  3. 自动标注完整性: 2D/3D 边界框、骨骼关键点、动作标签自动生成,节省标注成本 >90%
  4. SimReady 资产库: NVIDIA 提供预置座舱、人体模型,加速场景搭建
  5. 免费开源: 相比 Anyverse/SkyEngine 年费,Isaac Sim 完全免费,降低 IMS 开发成本

总结: NVIDIA Isaac Sim 6.0 的 IRA 扩展提供了完整的 DMS/OMS 合成数据生成管道,零代码 YAML 配置、GPU 加速渲染、自动标注、行为树支持,为 IMS 开发提供了高质量、低成本、高效率的训练数据生成方案。相比商业方案(Anyverse/SkyEngine),IRA 完全免费且开源,IMS 开发应优先采用 Isaac Sim 数据合成方案。


NVIDIA Isaac Sim 6.0 合成数据生成:DMS 训练数据自动化管道详解
https://dapalm.com/2026/07/10/2026-07-10-nvidia-isaac-sim-synthetic-data-generation-dms-training-pipeline/
作者
Mars
发布于
2026年7月10日
许可协议