高性能物理启用的3D模拟器,并支持:
栖息地的设计理念是将模拟速度优先于模拟功能的广度。从MatterPort3D数据集呈现场景时,Habot-SIM每秒达到数千帧(FPS)单线读取,并在单个GPU上达到10,000 fps多进程。 Habitat-Sim simulates a Fetch robot interacting in ReplicaCAD scenes at over 8,000 steps per second (SPS), where each 'step' involves rendering 1 RGBD observation (128×128 pixels) and rigid-body dynamics for 1/30sec.
Habitat-Sim is typically used with Habitat-Lab, a modular high-level library for end-to-end experiments in embodied AI -- defining embodied AI tasks (eg navigation, instruction following, question answering), training agents (via imitation or reinforcement learning, or no learning at all as in classical SensePlanAct pipelines), and benchmarking their performance on the defined tasks using standard metrics.
如果您在研究中使用栖息地平台,请引用栖息地1.0,栖息地2.0和栖息地3.0论文:
@misc{puig2023habitat3,
title = {Habitat 3.0: A Co-Habitat for Humans, Avatars and Robots},
author = {Xavi Puig and Eric Undersander and Andrew Szot and Mikael Dallaire Cote and Ruslan Partsey and Jimmy Yang and Ruta Desai and Alexander William Clegg and Michal Hlavac and Tiffany Min and Theo Gervet and Vladimír Vondruš and Vincent-Pierre Berges and John Turner and Oleksandr Maksymets and Zsolt Kira and Mrinal Kalakrishnan and Jitendra Malik and Devendra Singh Chaplot and Unnat Jain and Dhruv Batra and Akshara Rai and Roozbeh Mottaghi},
year={2023},
archivePrefix={arXiv},
}
@inproceedings{szot2021habitat,
title = {Habitat 2.0: Training Home Assistants to Rearrange their Habitat},
author = {Andrew Szot and Alex Clegg and Eric Undersander and Erik Wijmans and Yili Zhao and John Turner and Noah Maestre and Mustafa Mukadam and Devendra Chaplot and Oleksandr Maksymets and Aaron Gokaslan and Vladimir Vondrus and Sameer Dharur and Franziska Meier and Wojciech Galuba and Angel Chang and Zsolt Kira and Vladlen Koltun and Jitendra Malik and Manolis Savva and Dhruv Batra},
booktitle = {Advances in Neural Information Processing Systems (NeurIPS)},
year = {2021}
}
@inproceedings{habitat19iccv,
title = {Habitat: {A} {P}latform for {E}mbodied {AI} {R}esearch},
author = {Manolis Savva and Abhishek Kadian and Oleksandr Maksymets and Yili Zhao and Erik Wijmans and Bhavana Jain and Julian Straub and Jia Liu and Vladlen Koltun and Jitendra Malik and Devi Parikh and Dhruv Batra},
booktitle = {Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV)},
year = {2019}
}
栖息地-SIM也建立在其他人贡献的基础上。如果您使用贡献的方法/模型,请引用他们的作品。有关外部贡献和相应的工作/引用的列表,请参见“外部贡献”部分。
Habitat-Sim can be installed in 3 ways:
pip install .用子弹编译最新的无头版本。阅读构建说明和常见的构建问题。栖息地正在积极发展,我们建议用户限制自己进行稳定的版本。从v0.1.4开始,我们为每个版本提供Conda软件包。
准备Conda Env
假设您已经安装了Conda,让我们准备一个conda env:
# We require python>=3.9 and cmake>=3.10
conda create -n habitat python=3.9 cmake=3.14.0
conda activate habitatconda安装栖息地-SIM
根据您的系统/需求选择以下选项之一:
在带有附件显示的机器上安装:
conda install habitat-sim -c conda-forge -c aihabitatTo install on headless machines (ie without an attached display, eg in a cluster) and machines with multiple GPUs (this parameter relies on EGL and thus does not work on MacOS):
conda install habitat-sim headless -c conda-forge -c aihabitat
[最常见的情况]用子弹物理安装栖息地-SIM
conda install habitat-sim withbullet -c conda-forge -c aihabitat
注意:构建参数可以链接在一起。例如,在无头机器上安装带有物理的栖息地-SIM:
conda install habitat-sim withbullet headless -c conda-forge -c aihabitat
Conda packages for older versions can installed by explicitly specifying the version, eg conda install habitat-sim=0.1.6 -c conda-forge -c aihabitat .
我们还为主分支提供了每晚的Conda构建。但是,仅当您需要最新版本版本中尚未使用特定功能时,才应使用此功能。为了每晚构建最新的主体,只需将-c aihabitat换成-c aihabitat-nightly 。
让我们使用Python数据下载一些3D资产下载实用程序:
下载(测试)3D场景
python -m habitat_sim.utils.datasets_download --uids habitat_test_scenes --data-path /path/to/data/请注意,这些测试场景不提供语义注释。如果您想通过example.py测试语义传感器,请使用MatterPort3D数据集中的数据(请参阅数据集)。
下载示例对象
python -m habitat_sim.utils.datasets_download --uids habitat_example_objects --data-path /path/to/data/交互式测试:使用C ++或Python中的栖息地SIM随附的交互式查看器:
# C++
# ./build/viewer if compiling locally
habitat-viewer /path/to/data/scene_datasets/habitat-test-scenes/skokloster-castle.glb
# Python
# NOTE: depending on your choice of installation, you may need to add '/path/to/habitat-sim' to your PYTHONPATH.
# e.g. from 'habitat-sim/' directory run 'export PYTHONPATH=$(pwd)'
python examples/viewer.py --scene /path/to/data/scene_datasets/habitat-test-scenes/skokloster-castle.glb您应该能够在此测试场景中控制代理。使用w/a/s/d键向前/左/向后/向后/右和箭头键或鼠标(左键单击)以控制凝视方向(查找/向上/向下/左/右)。尝试找到一个被花圈包围的女人的照片。玩得开心!
物理相互作用:栖息地-SIM通过与子弹物理学的整合提供了刚性且明显的动力学模拟。 Try it out now with our interactive viewer functionality in C++ or python.
首先,下载我们的完全互动复制品公寓数据集(140 MB):
# NOTE: by default, data will be downloaded into habitat-sim/data/. Optionally modify the data path by adding: `--data-path /path/to/data/`
# with conda install
python -m habitat_sim.utils.datasets_download --uids replica_cad_dataset
# with source (from inside habitat_sim/)
python src_python/habitat_sim/utils/datasets_download.py --uids replica_cad_dataset--uids replica_cad_baked_lighting (480 MB)获得105个带有预烘焙照明的场景变化。然后在Viewer应用程序中加载复制品场景,并启用了物理。如果修改了上面的数据路径,也会在下面的查看器调用中对其进行修改。
# C++
# ./build/viewer if compiling locally
habitat-viewer --enable-physics --dataset data/replica_cad/replicaCAD.scene_dataset_config.json -- apt_1
# python
# NOTE: habitat-sim/ directory must be on your `PYTHONPATH`
python examples/viewer.py --dataset data/replica_cad/replicaCAD.scene_dataset_config.json --scene apt_1--dataset data/replica_cad_baked_lighting/replicaCAD_baked.scene_dataset_config.json --scene Baked_sc1_staging_00查看器应用程序在运行时将键盘和鼠标接口选项的完整列表输出到控制台。
QuickStart示例:
WASDLEFT单击并拖动鼠标环顾四周SPACE切换模拟/ON(默认打开)'m'切换到“获取”鼠标模式LEFT或RIGHT单击并拖动以移动对象或打开门/抽屉并释放以丢弃对象ALT ):旋转对象固定约束框架(YAW)CTRL ):旋转对象固定约束框架(螺距)ALT + CTRL ):旋转对象固定约束框架(滚动)非相互作用测试(例如,无头系统):运行示例脚本:
python /path/to/habitat-sim/examples/example.py --scene /path/to/data/scene_datasets/habitat-test-scenes/skokloster-castle.glb The agent will traverse a particular path and you should see the performance stats at the very end, something like this: 640 x 480, total time: 3.208 sec. FPS: 311.7 。
从栖息地ICCV'19运行examples/benchmark.py --scene /path/to/mp3d_example/17DRP5sb8fy/17DRP5sb8fy.glb基准表。
Additional arguments to example.py are provided to change the sensor configuration, print statistics of the semantic annotations in a scene, compute action-space shortest path trajectories, and set other useful functionality.请demo_runner.py example.py 。
加载特定的MP3D或Gibson House: examples/example.py --scene path/to/mp3d/house_id.glb 。
我们还提供了一个示例演示供参考。
在Python中运行一个物理示例(使用“通过子弹的物理模拟”进行构建之后):
python examples/example.py --scene /path/to/data/scene_datasets/habitat-test-scenes/skokloster-castle.glb --enable_physics请注意,在这种模式下,代理将被冻结并定向到产卵物理对象。另外, --save_png可用于将物理场景的视觉观察帧输出到当前目录。
如果您在远程计算机上运行并在初始化模拟器时显示错误,例如
X11: The DISPLAY environment variable is missing
Could not initialize GLFW确保您没有在环境中定义的DISPLAY (运行unset DISPLAY以不确定变量)
如果您看到libgl错误,则如下:
X11: The DISPLAY environment variable is missing
Could not initialize GLFW您的libgl可能位于非标准位置。参见这个问题。
Browse the online Habitat-Sim documentation.
查看我们的ECCV教程系列,以获取动手快速启动体验。
找不到您问题的答案?尝试在我们的讨论论坛上询问开发人员和社区。
如何使用栖息地-SIM使用常见的支持数据集。
如果您使用Pyrobot的噪声模型,请引用其技术报告。
Specifically, the noise model used for the noisy control functions named pyrobot_* and defined in src_python/habitat_sim/agent/controls/pyrobot_noisy_controls.py
如果您使用红木深度噪声模型,请引用他们的纸张
Specifically, the noise model defined in src_python/habitat_sim/sensors/noise_models/redwood_depth_noise_model.py and src/esp/sensor/RedwoodNoiseModel.*
栖息地-SIM已获得麻省理工学院的许可。有关详细信息,请参见许可证。
演示脚本使用: