import-carla-prop
它能做什么
这项技能把三维模型文件导入 CARLA,作为道具使用。道具是指长椅、护栏和路牌等物体。适合想在模拟街道中添加自定义物品的人。
适用场景
- ✓当你有街道物体的三维模型,并想把它们放进 CARLA 的时候。
- ✓当你想让新的长椅或标志牌在测试中出现在模拟器里时。
- ✓当你想确认导入的道具能在运行中的模拟里放置的时候。
技能链接
https://github.com/carla-simulator/carla/blob/ue58-dev/Skills/ue4/import-carla-prop/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请帮我把文件夹中的 FBX 长椅模型导入 CARLA 作为道具,并检查我能否放置它们。”
每周 5 个新技能,1 分钟读完。
工作原理
智能体会把每个模型导入 CARLA,用其所在子文件夹的名称为它加上标签,然后进行注册,使其能像内置道具一样生成。之后它会放置一个测试副本,以确认道具可以正常使用。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Import a prop into CARLA
Paths.
scripts/…andreferences/…below are relative to the directory holding this SKILL.md. Your working directory is the user's project, not that directory, so prefix them with its absolute path or the command is not found.
# a directory — each subdirectory names the semantic tag for what is inside
python3 scripts/import_prop.py ~/meshes/props
# a single file — state its tag
python3 scripts/import_prop.py ~/meshes/Windmill.fbx --tag Building
Each mesh is imported into /Game/Carla/Static/<Tag>/<Name>, registered in
Content/Carla/Config/Default.Package.json, and added to PropFactory — after
which it spawns exactly like a native CARLA prop:
barrier_bp = bp_lib.find('static.prop.policebarrier')
for spawn_loc in spawn_locations:
world.spawn_actor(barrier_bp, spawn_loc)
Pipeline detail, schema and the P-lessons:
references/props.md.
Instructions
Prop Import Progress:
- [ ] Step 1: Check prerequisites — hand off to build-carla-ue4 on a build FAIL
- [ ] Step 2: Import (one command, one editor boot)
- [ ] Step 3: Verify the props spawn on a running server
- [ ] (opt-in) Export as a standalone package
Step 1: Check prerequisites
bash scripts/check_env.sh
What must exist is a runnable editor for this project: UE4_ROOT, the
checkout, a built CarlaUE4Editor, and PythonScriptPlugin.
This skill never builds. On a FAIL naming UE4, CarlaUE4Editor or missing
content, stop and run [[build-carla-ue4]] against that checkout, then come back.
The check also reports whether Content/Carla is a symlink to a shared content
clone — if so, everything below lands in a tree every other checkout sees.
--package NAME keeps an import out of it.
Step 2: Import
The directory form takes each prop's tag from the first level below the path you give — the same shape as the destination:
~/meshes/props/
├── Building/Windmill.fbx
├── Static/Bench_Modern.fbx
└── Dynamic/Crate.fbx
Any directory works. An FBX loose in the root, or under a directory that is not a tag, is an error before the editor boots.
size is measured, not asked. EPropSize is defined by physical scale, so
the importer reads the mesh's bounding box and reports it:
[import] OK static.prop.windmill 3.2 x 3.1 x 12.4 m size=huge (measured) 412 KB
Read the dimensions: a mesh exported at the wrong scale shows up here. --size
overrides.
tag cannot be measured and is never defaulted. It sets the semantic
segmentation label, and a wrong one is labelled None with nothing raised. When
filling it in from a request rather than from directory names:
| the object is… | tag |
|---|---|
| bolted-down street furniture — bench, ATM, bus stop, fountain, mailbox, vending machine | Static |
| portable or knockable — bin, box, bag, cone, chair, cart, barrier | Dynamic |
| a structure with mass — kiosk, shed, windmill, tower | Building |
| a plant | Vegetation |
| a post — street light, sign post, bollard | Pole |
| road-surface debris | Other |
Say which tag you chose and why in one line, so the user can correct it before anything is written. When the object is ambiguous, ask.
Other flags:
| flag | why |
|---|---|
--name |
prop name for a single file; defaults to the FBX stem |
--package NAME |
import into its own /Game/NAME/ tree — self-contained, exportable, touches no shared content, no factory entry |
--no-factory |
skip PropFactory; the registry entry alone still makes the prop spawnable |
--mesh |
nominate one mesh when a multi-mesh FBX yields several |
--verbose |
stream the editor log instead of capturing it |
The importer stats every .uasset at the path it registered and fails if one is
missing or too small to hold geometry.
Step 3: Verify they spawn
Start a server ([[run-carla-server]] — the default -nullrhi mode is enough,
props need no rendering to spawn):
bash ../run-carla-server/scripts/run_server.sh Town10HD 2000 >/tmp/carla_server.log 2>&1 &
until nc -z 127.0.0.1 2000; do sleep 1; done
python3 scripts/verify_prop.py --name Windmill
pkill -x UE4Editor # clean stop — never pkill -f (run-carla-server S3)
verify_prop.py filters, finds, spawns and destroys each prop. Blueprint ids are
lowercase: static.prop.windmill.
Add --keep to leave the props standing, paired with a windowed server.
**This is whe
常见问题
如何给道具加标签?
每个子文件夹的名称会成为其中模型的标签,例如 Building。
可以只导入一个文件吗?
可以。你可以直接为单个文件指定标签。
能把道具打包分享吗?
可以。道具可以导出为独立的软件包,供他人导入。
详情
作者的原始描述
Imports FBX meshes into a CARLA source build as spawnable static.prop.* blueprints — pass a directory whose subdirectories name the semantic tags, or a single FBX with its tag, and the props are imported into content, registered, added to the prop factory and verified by spawning. Use when the user asks to "add a prop to CARLA", "import an FBX as a prop", "add street furniture/benches/signs", or needs a custom mesh spawnable from the Python API.
repo: carla-simulator/carla
热度
- GitHub 星标
- 15k
- 排名
- #11123
- 许可证
- MIT
- 更新时间
- 2026/11/2
评论
- …
同一仓库的更多技能
create-leaderboard-route
15k帮你的智能体通过在模拟器视角中放置路径点和场景触发器,构建 CARLA Leaderboard 路线文件,并对其进行检查和排序。
package-leaderboard-agent
15k帮你的智能体把驾驶智能体打包成 Docker 镜像,用于提交 CARLA Leaderboard,并检查文件夹结构,测试镜像能否加载它。
read-leaderboard-results
15k帮你的智能体阅读 CARLA Leaderboard 结果文件,解释每条路线的得分和违规情况,并按另一规则版本重新计分。
run-leaderboard-evaluation
15k帮你的智能体用你的驾驶智能体在一组路线上运行 CARLA Leaderboard 评估器,先检查设置,并保存可以恢复的检查点。