YAML:
sceneclassSceneConfig场景配置
以声明式方式描述仿真世界的组成:地基、机器人、物体、传感器和光源。SceneManager 在运行时负责实例化并将实体注入仿真器。
顶层字段8
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
name | string | 可选 | — | 场景名称 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 场景基准位置 [x, y, z](米) |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 场景基准旋转,四元数 [w, x, y, z] ⚠须为单位四元数(归一化),即 w²+x²+y²+z²=1 |
base_config | BaseConfig | 可选 | — | 地基 / 环境配置,通过 stereotype 指定类型 |
robot_cfg_dict | dict[str, RobotConfig] | 可选 | {} | 机器人配置字典,key 为实例名(运行时通过 SceneManager.get_robot(name) 访问) |
object_cfg_dict | dict[str, ObjectConfig] | 可选 | {} | 场景物体配置字典,key 为实例名 |
sensor_cfg_dict | dict[str, SensorConfig] | 可选 | {} | 传感器配置字典,key 为实例名 |
light_cfg_dict | dict[str, LightConfig] | 可选 | {} | 光源配置字典,key 为实例名 |
BaseConfig:地基与环境 (base_config)
每个场景只有一个 Base,定义物理地面或加载完整环境 USD。通过 stereotype 决定具体子类。
class
GroundPlaneBaseConfigstereotypeground_planeextendsBaseConfig, SpawnableConfigfastsim/unisim/bases/models/ground_plane_base.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
ground_plane_size | list[2] | 可选 | [10.0, 10.0] | 地面视觉尺寸 [x, y](米),物理上无限延伸 ⚠每个值须 > 0 |
继承自SpawnableConfig5
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "ground_plane" |
name | string | 必填 | — | 实体名称 ⚠1-100 字符,不可含 / 或 \ |
prim_path | string | 可选 | — | USD prim 路径 ⚠须以 / 开头 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 [x, y, z](米) |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转(四元数 [w, x, y, z]) |
class
UsdBaseConfigstereotypeusdextendsBaseConfig, SpawnableConfigfastsim/unisim/bases/models/usd_base.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
asset_path | string | 必填 | — | 环境 USD 文件路径(支持 root_key:// 协议) |
source | string | 必填 | local | 资产来源 ⚠local / remote / platform |
继承自SpawnableConfig5
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "usd" |
name | string | 必填 | — | 实体名称 |
prim_path | string | 可选 | — | USD prim 路径 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 [x, y, z] |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转(四元数) |
class
EmptyBaseConfigstereotypeemptyextendsBaseConfig, SpawnableConfigfastsim/unisim/bases/models/empty_base.py继承自SpawnableConfig4
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "empty",适合完全自定义物理场景 |
name | string | 必填 | — | 实体名称 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转 |
class
MeshBaseConfigstereotypemeshextendsBaseConfig, SpawnableConfigfastsim/unisim/bases/models/mesh_base.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
asset_path | string | 必填 | — | 网格文件路径(支持 root_key:// 协议) |
source | string | 必填 | local | 资产来源 ⚠local / remote / platform |
scale | list[3] | 可选 | [1.0, 1.0, 1.0] | 网格缩放 [x, y, z] |
enable_collision | bool | 可选 | true | 是否参与碰撞。设为 false 则仅作为视觉背景 |
继承自SpawnableConfig4
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "mesh" |
name | string | 必填 | — | 实体名称 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转 |
ObjectConfig:场景物体 (object_cfg_dict)
class
RigidObjectConfigstereotyperigidextendsObjectConfig, SpawnableConfigfastsim/unisim/objects/models/rigid_object.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
mass | float | 可选 | null | 物体质量(kg),优先于 density |
density | float | 可选 | 1000 | 物体密度(kg/m³),仅在 mass 为 null 时生效 |
disable_gravity | bool | 可选 | false | 是否禁用重力 |
kinematic_enabled | bool | 可选 | false | 是否启用运动学模式(不受力学影响) |
disable_rigid_body | bool | 可选 | false | 是否禁用刚体属性 |
linear_damping | float | 可选 | null | 线性阻尼 |
angular_damping | float | 可选 | null | 角阻尼 |
static_friction | float | 可选 | 0.8 | 静摩擦系数(覆盖 USD 中烘焙的摩擦材质) |
dynamic_friction | float | 可选 | 0.8 | 动摩擦系数(覆盖 USD 中烘焙的摩擦材质) |
restitution | float | 可选 | 0.0 | 弹性恢复系数(0 = 不反弹,1 = 完全弹性) |
enable_collision | bool | 必填 | true | 是否启用碰撞 |
primitive_type | enum | 可选 | — | 几何体类型(source 为 primitive 时必填) ⚠box / sphere / cylinder / cone / capsule / disk |
primitive_radius | float | 可选 | — | 几何体半径(sphere / cylinder / cone / capsule) |
primitive_size | list[3] | 可选 | — | 几何体尺寸 [x, y, z](box) |
primitive_height | float | 可选 | — | 几何体高度(cylinder / cone / capsule) |
primitive_axis | string | 可选 | Z | 几何体轴向(cylinder / cone / capsule) ⚠X / Y / Z |
primitive_color | list[3] | 可选 | null | 几何体漫反射颜色 RGB(每个分量在 [0, 1] 范围) |
继承自ObjectConfig4
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
source | string | 必填 | primitive | 资产来源 ⚠local / remote / platform / primitive |
asset_path | string | 可选 | — | USD 资产路径(source 为 local/remote 时必填) |
scale | list[3] | 可选 | [1, 1, 1] | 缩放比例 [x, y, z] |
axis_y_up | bool | 可选 | false | 资产是否为 Y 轴朝上 |
继承自SpawnableConfig5
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "rigid" |
name | string | 必填 | — | 实体名称 |
prim_path | string | 可选 | — | USD prim 路径 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 [x, y, z] |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转(四元数) |
class
ArticulatedObjectConfigstereotypearticulatedextendsObjectConfig, ArticulationConfig, SpawnableConfigfastsim/unisim/objects/models/articulated_object.py继承自ArticulationConfig3
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
actuator_cfg_dict | dict[str, ActuatorConfig] | 必填 | {} | 执行器配置字典(关节驱动组) |
init_joint_position | dict[str, float] | 可选 | {} | 初始关节位置 |
init_joint_velocity | dict[str, float] | 可选 | {} | 初始关节速度 |
继承自ObjectConfig3
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
source | string | 必填 | local | 资产来源 ⚠local / remote / platform |
asset_path | string | 必填 | — | USD 资产路径 |
scale | list[3] | 可选 | [1, 1, 1] | 缩放比例 |
继承自SpawnableConfig4
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "articulated" |
name | string | 必填 | — | 实体名称 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转 |
class
SoftObjectConfigstereotypesoftextendsObjectConfig, SpawnableConfigfastsim/unisim/objects/models/soft_object.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
mass | float | 必填 | 0.1 | 物体总质量(kg) |
density | float | 必填 | 1000 | 物体密度(kg/m³) |
youngs_modulus | float | 可选 | 10000 | 杨氏模量(Pa),控制体积柔性体的刚度 |
poissons_ratio | float | 可选 | 0.3 | 泊松比,控制横向与纵向变形的比例 ⚠须在 [0, 0.5) 范围内 |
damping | float | 可选 | 0.01 | 全局阻尼系数 |
dynamic_friction | float | 可选 | 0.5 | 动摩擦系数 |
static_friction | float | 可选 | 0.5 | 静摩擦系数 |
stretch_stiffness | float | 可选 | 10000 | 拉伸刚度(N/m),仅布料类型生效 |
shear_stiffness | float | 可选 | 1000 | 剪切刚度(N/m),仅布料类型生效 |
bending_stiffness | float | 可选 | 10.0 | 弯曲刚度(N·m),仅布料类型生效 |
pressure | float | 可选 | 0.0 | 内部压力(Pa),用于充气柔性体,0 表示禁用 |
soft_body_type | enum | 可选 | volumetric | 柔性体类型,提示仿真器使用何种模型 ⚠cloth / volumetric / inflatable |
simulation_hex_mesh | bool | 可选 | false | 是否使用六面体网格进行体积 FEM(默认四面体) |
particle_contact_offset | float | 可选 | 0.02 | 粒子接触检测半径(米) |
solver_position_iterations | int | 可选 | 16 | 每步位置投影迭代次数 ⚠>= 1 |
enable_collision | bool | 必填 | true | 是否启用碰撞 |
self_collision | bool | 可选 | false | 是否启用自碰撞 |
disable_gravity | bool | 可选 | false | 是否禁用重力 |
继承自ObjectConfig4
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
source | string | 必填 | primitive | 资产来源 ⚠local / remote / platform / primitive |
asset_path | string | 可选 | — | USD 资产路径 |
scale | list[3] | 可选 | [1, 1, 1] | 缩放比例 |
axis_y_up | bool | 可选 | false | 资产是否 Y 轴朝上 |
继承自SpawnableConfig5
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "soft" |
name | string | 必填 | — | 实体名称 |
prim_path | string | 可选 | — | USD prim 路径 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转 |
RobotConfig:机器人 (robot_cfg_dict)
PlannerConfig 为嵌套配置,由用户自定义规划器扩展;机器人基础字段在 RobotConfig 中定义,具体子类通过 stereotype 选择。
class
GeneralRobotConfigstereotypegeneral_robotextendsRobotConfig, ArticulationConfig, SpawnableConfigfastsim/unisim/robots/models/general_robot.py继承自RobotConfig4
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
ee_link_name | string | 可选 | — | 末端执行器 link 名称(单臂简写,多臂请用 modules.arms) |
ik_joint_names | list[str] | 可选 | — | 参与 IK 计算的关节名称子集(不设则使用全部可动关节) |
use_planner | bool | 可选 | false | 是否挂载运动规划器(如 CuRobo / OMPL) |
planner_cfg | PlannerConfig | 可选 | — | 规划器详细配置,use_planner 为 true 时生效 |
继承自ArticulationConfig6
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
asset_path | string | 必填 | — | 机器人 USD 资产路径 |
source | string | 必填 | local | 资产来源 ⚠local / remote / platform |
actuator_cfg_dict | dict[str, ActuatorConfig] | 必填 | {} | 执行器配置字典(关节驱动组) |
init_joint_position | dict[str, float] | 可选 | {} | 初始关节位置 |
init_joint_velocity | dict[str, float] | 可选 | {} | 初始关节速度 |
scale | list[3] | 可选 | [1, 1, 1] | 缩放比例 |
继承自SpawnableConfig4
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "general_robot" |
name | string | 必填 | — | 实体名称 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转 |
class
ModularRobotConfigstereotypemodular_robotextendsRobotConfig, ArticulationConfig, SpawnableConfigfastsim/unisim/robots/models/modular_robot.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
base_module | BaseModuleConfig | 可选 | null | 移动底盘模块配置 |
arm_modules | dict[str, ArmModuleConfig] | 可选 | {} | 机械臂模块字典,key 为臂名称(如 left_arm、right_arm) |
extra_modules | dict[str, ExtraModuleConfig] | 可选 | {} | 额外模块字典(如升降柱、头部等) |
继承自ArticulationConfig2
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
asset_path | string | 必填 | — | 机器人 USD 资产路径 |
actuator_cfg_dict | dict[str, ActuatorConfig] | 必填 | {} | 执行器配置字典 |
继承自SpawnableConfig2
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "modular_robot" |
name | string | 必填 | — | 实体名称 |
class
ArmModuleConfigfastsim/unisim/robots/models/modules/arm_module.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
arm_actuator_name | string | 必填 | — | 机械臂执行器组名称(须与 actuator_cfg_dict 中的 key 一致) |
ee_link_name | string | 可选 | — | 末端执行器 link 名称,用于 IK、EE 位姿、规划器 |
ee_type | string | 可选 | none | 末端执行器类型 ⚠gripper / dexterous_hand / none |
ee_actuator_name | string | 可选 | — | 末端执行器(夹爪/灵巧手)对应的执行器组名称 |
planner_cfg | PlannerConfig | 可选 | — | 该臂的独立规划器配置(可覆盖机器人级别配置) |
ee_convention | string | list[4] | 可选 | z | EE 朝向约定。字符串表示 gripper 前向轴(z / -x 等),四元数 [w,x,y,z] 表示灵巧手 |
class
BaseModuleConfigfastsim/unisim/robots/models/modules/base_module.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
base_actuator_name | string | 必填 | — | 底盘执行器组名称 |
base_type | string | 可选 | differential | 底盘运动学类型 ⚠differential / omnidirectional / ackermann / legged |
wheel_separation | float | 可选 | null | 轮间距(米),差速/全向底盘使用 |
wheel_radius | float | 可选 | null | 车轮半径(米) |
locomotion_cfg | dict | 可选 | null | 足式运动控制器配置(base_type 为 legged 时使用),详见 LeggedLocomotionConfig |
planner_cfg | PlannerConfig | 可选 | null | 底盘导航规划器配置(如 A*+DWA / curobo_mpc_nav) |
virtual_base_link_name | string | 可选 | null | 虚拟基座 link 名称(用于在 MPC 等动作中以虚拟基座坐标系做规划,与 BaseActuatorConfig.virtual_base_link_name 配合) |
class
ExtraModuleConfigfastsim/unisim/robots/models/modules/extra_module.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
actuator_name | string | 必填 | — | 该模块对应的执行器组名称(如升降柱、头部云台等) |
class
PlannerConfigfastsim/configs/scene_cfg.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
name | string | 可选 | default_planner_name | 规划器名称 |
stereotype | string | 必填 | — | 规划器类型 ⚠curobo / ompl / 自定义 |
lazy_init | bool | 可选 | false | 是否延迟初始化(首次使用时才加载) |
class
CuroboPlannerConfigstereotypecuroboextendsPlannerConfigfastsim/planner/planners/curobo/curobo_planner_cfg.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
device | string | 可选 | cuda | 计算设备 ⚠cpu / cuda |
robot_config_file | string | 必填 | — | 机器人 URDF/资产路径 |
world_config_file | string | 可选 | — | 碰撞世界配置文件 |
world_config_source | string | 可选 | stage | 碰撞世界来源 ⚠stage / config_file |
world_stage_ignore_substrings | list[str] | 可选 | [] | 从 stage 构建碰撞世界时忽略的路径子串 |
world_stage_only_paths | list[str] | 可选 | ["/World"] | 仅包含这些 stage 路径 |
world_stage_reference_prim_path | string | 可选 | null | stage 参考 prim 路径 ⚠须以 / 开头 |
interpolation_dt | float | 可选 | 0.0167 | 轨迹插值时间步长(秒) |
attach_surface_sphere_radius | float | 可选 | 0.001 | 附着面球体半径 |
collision_activation_distance | float | 可选 | 0.02 | 碰撞激活距离(米) |
use_cuda_graph | bool | 可选 | false | 是否使用 CUDA Graph 加速 |
warmup_enable | bool | 可选 | true | MotionGen 初始化后是否运行 warmup。设为 false 跳过 ~7 次 warmup 规划:首次规划会变慢,但适合一次性数据生成场景;长程多次规划场景仍建议保留 |
warmup_js_trajopt | bool | 可选 | true | 是否包含 3 次关节空间轨迹优化 warmup。仅做笛卡尔规划时可设为 false(FastSim 的 gen_motion_plan 是笛卡尔) |
warmup_graph | bool | 可选 | true | 是否包含 graph-search 与 cartesian-with-graph warmup。从未启用 enable_graph=True 时可设为 false |
class
OmplPlannerConfigstereotypeomplextendsPlannerConfigfastsim/planner/planners/ompl/ompl_planner_cfg.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
robot_urdf_path | string | 必填 | — | 机器人 URDF 文件路径(碰撞模型) |
ee_link_name | string | 可选 | — | 末端执行器 link 名称 |
planning_algorithm | string | 可选 | RRTConnect | 规划算法 ⚠RRTConnect / RRTstar / PRM / BITstar / LazyPRM / KPIECE / EST / SBL |
planning_time | float | 可选 | 5.0 | 规划时间上限(秒) |
interpolation_resolution | float | 可选 | 0.01 | 轨迹插值分辨率 |
collision_check_resolution | float | 可选 | 0.01 | 碰撞检测分辨率 |
range | float | 可选 | 0.0 | RRT 搜索范围(0 表示自动) |
simplify_path | bool | 可选 | true | 是否简化规划路径 |
num_ik_samples | int | 可选 | 100 | IK 采样次数 |
class
AStarDWAPlannerConfigstereotypeastar_dwaextendsNavigationPlannerConfig, PlannerConfigfastsim/planner/planners/astar_dwa/astar_dwa_planner_cfg.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
max_speed | float | 必填 | 0.5 | DWA 最大线速度(m/s) |
min_speed | float | 必填 | -0.2 | DWA 最小线速度(负值表示后退) |
max_yaw_rate | float | 必填 | 1.0 | DWA 最大角速度(rad/s) |
max_accel | float | 必填 | 0.3 | DWA 最大线加速度(m/s²) |
max_delta_yaw_rate | float | 必填 | 1.0 | DWA 最大角速度变化率(rad/s²) |
v_resolution | float | 必填 | 0.02 | 线速度采样分辨率(m/s) |
yaw_rate_resolution | float | 必填 | 0.05 | 角速度采样分辨率(rad/s) |
dt | float | 必填 | 0.1 | DWA 预测时间步长(s) |
predict_time | float | 必填 | 2.0 | DWA 预测时间窗口(s) |
to_goal_cost_gain | float | 必填 | 0.3 | DWA 朝向目标权重 |
speed_cost_gain | float | 必填 | 1.0 | DWA 速度权重 |
obstacle_cost_gain | float | 必填 | 1.0 | DWA 避障权重 |
path_cost_gain | float | 必填 | 0.5 | DWA 全局路径跟随权重 |
goal_pos_tolerance | float | 必填 | 0.1 | 到达目标位置容差(m) |
goal_angle_tolerance | float | 必填 | 0.2 | 到达目标角度容差(rad) |
继承自NavigationPlannerConfig3
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
map_resolution | float | 可选 | 0.05 | 栅格分辨率 |
robot_radius | float | 必填 | 0.2 | 机器人碰撞半径 |
obstacle_ignore_substrings | list[str] | 可选 | [] | 障碍物过滤子串列表 |
SensorConfig:传感器 (sensor_cfg_dict)
class
CameraConfigstereotypecameraextendsSensorConfig, SpawnableConfigfastsim/unisim/sensors/models/camera.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
data_types | list[str] | 必填 | ["rgb"] | 采集数据类型列表 ⚠rgb / depth / semantic_segmentation / instance_segmentation / normals |
width | int | 必填 | 640 | 图像宽度(像素) |
height | int | 必填 | 480 | 图像高度(像素) |
camera_model | enum | 可选 | pinhole | 相机模型类型 ⚠pinhole / fisheye |
fix_camera | bool | 可选 | false | 是否固定相机位姿 |
clip_range | list[2] | 可选 | [0.001, 1000.0] | 深度裁剪范围 [near, far](米) |
focal_length | float | 可选 | 24.0 | 焦距(mm) |
focus_distance | float | 可选 | 400.0 | 对焦距离 |
f_stop | float | 可选 | 0.0 | 光圈值(0 = 禁用景深效果) |
horizontal_aperture | float | 可选 | 20.955 | 水平孔径 |
vertical_aperture | float | 可选 | null | 垂直孔径(null 则自动计算) |
horizontal_aperture_offset | float | 可选 | 0.0 | 水平孔径偏移 |
vertical_aperture_offset | float | 可选 | 0.0 | 垂直孔径偏移 |
attach_to | AttachToConfig | 可选 | — | 挂载配置(挂到某实体或 link 上) |
look_at | LookAtConfig | 可选 | — | 朝向配置(朝向目标实体或坐标) |
convention | enum | 可选 | world | 坐标系约定 ⚠world(+X 前 +Z 上)/ opengl(-Z 前 +Y 上)/ ros(+Z 前 -Y 上) |
继承自SpawnableConfig5
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "camera" |
name | string | 必填 | — | 传感器名称 |
prim_path | string | 可选 | — | USD prim 路径 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 [x, y, z] |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转(四元数) |
LightConfig:光源 (light_cfg_dict)
class
GeneralLightConfigstereotypegeneral_lightextendsLightConfig, SpawnableConfigfastsim/unisim/lights/models/general_light.py| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
light_type | enum | 必填 | — | 光源类型 ⚠distant(平行光)/ sphere(点光源)/ disk(面光源) |
intensity | float | 可选 | 1.0 | 光照强度 ⚠>= 0 |
exposure | float | 可选 | 0.0 | 曝光值 |
color | list[3] | 可选 | [1.0, 1.0, 1.0] | 颜色 [r, g, b],值域 0–1 |
visible | bool | 可选 | true | 光源自身网格是否在渲染中可见 |
enable_color_temperature | bool | 可选 | false | 是否启用色温(启用后 color 字段被覆盖) |
color_temperature | float | 可选 | 6500 | 色温(开尔文 K) |
normalize | bool | 可选 | false | 是否对光照强度做归一化 |
radius | float | 可选 | — | 光源半径(sphere 类型) ⚠> 0 |
angle | float | 可选 | — | 光源角度(distant 类型) |
texture_file | string | 可选 | — | 纹理贴图文件路径 |
继承自SpawnableConfig4
| 字段 | 类型 | 必填 | 默认值 | 说明 / 约束 |
|---|---|---|---|---|
stereotype | string | 必填 | — | "general_light" |
name | string | 必填 | — | 光源名称 |
position | list[3] | 可选 | [0.0, 0.0, 0.0] | 位置 |
rotation | list[4] | 可选 | [1.0, 0.0, 0.0, 0.0] | 旋转 |
配置示例
scene 配置块YAML
scene:
name: pick_and_place_scene
position: [0.0, 0.0, 0.0]
rotation: [1.0, 0.0, 0.0, 0.0]
base_config:
stereotype: ground_plane
ground_plane_size: [10.0, 10.0]
robot_cfg_dict:
arm:
stereotype: modular_robot
asset_path: assets://robots/ur5_with_gripper.usd
use_planner: true
actuator_cfg_dict:
arm:
joint_names_expr: ["joint_*"]
stiffness: 50000.0
damping: 800.0
gripper:
stereotype: gripper
joint_names_expr: ["finger_*"]
arm_modules:
main_arm:
arm_actuator_name: arm
ee_link_name: tool0
ee_type: gripper
ee_actuator_name: gripper
object_cfg_dict:
cube:
stereotype: rigid
asset_path: assets://objects/cube_red.usd
mass: 0.2
enable_gravity: true
cloth:
stereotype: soft
asset_path: assets://objects/cloth.usd
soft_body_type: cloth
mass: 0.05
stretch_stiffness: 8000
bending_stiffness: 5.0
sensor_cfg_dict:
wrist_cam:
stereotype: camera
width: 640
height: 480
data_types: [rgb, depth]
attach_to: arm
convention: ros
light_cfg_dict:
main_light:
stereotype: general_light
light_type: distant
intensity: 3000
color: [1.0, 1.0, 1.0]