Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug Fix] Fixing rotational bug in tasks.rearrange.utils.get_camera_transform #1847

Open
wants to merge 11 commits into
base: main
Choose a base branch
from
19 changes: 3 additions & 16 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,6 @@ jobs:
while [ ! -f ~/miniconda/pytorch_installed ]; do sleep 2; done # wait for Pytorch
pip install -e habitat-lab
pip install -e habitat-baselines
pip install -e habitat-hitl
- save_cache:
key: conda-{{ checksum "habitat-lab/.circleci/config.yml" }}-{{ checksum "./date" }}
background: true
Expand Down Expand Up @@ -271,18 +270,8 @@ jobs:
. activate habitat; cd habitat-lab
export PYTHONPATH=.:$PYTHONPATH
export MULTI_PROC_OFFSET=0 && export MAGNUM_LOG=quiet && export HABITAT_SIM_LOG=quiet
python -m pytest test/ --cov-report=xml --cov-report term --cov=./
python -m pytest --cov-report=xml --cov-report term --cov=./
- codecov/upload
- run:
name: Run HITL tests
no_output_timeout: 60m
command: |
export PATH=$HOME/miniconda/bin:/usr/local/cuda/bin:$PATH
. activate habitat; cd habitat-lab
export PYTHONPATH=.:$PYTHONPATH
export MULTI_PROC_OFFSET=0 && export MAGNUM_LOG=quiet && export HABITAT_SIM_LOG=quiet
python -m habitat_sim.utils.datasets_download --uids hab3-episodes hab3_bench_assets habitat_humanoids hab_spot_arm ycb --data-path data/ --no-replace --no-prune
python -m pytest habitat-hitl/test
- run:
name: Run baseline training tests
no_output_timeout: 30m
Expand All @@ -291,9 +280,9 @@ jobs:
. activate habitat; cd habitat-lab
export PYTHONPATH=.:$PYTHONPATH
export MULTI_PROC_OFFSET=0 && export MAGNUM_LOG=quiet && export HABITAT_SIM_LOG=quiet
# This is a flag that enables test_baseline_training to work
# This is a flag that enables test_test_baseline_training to work
export TEST_BASELINE_SMALL=1
python -m pytest test/test_baseline_training.py -s
python -m pytest test/test_baseline_training.py -s
- run:
name: Run Hab2.0 benchmark
no_output_timeout: 30m
Expand Down Expand Up @@ -335,8 +324,6 @@ jobs:
python -c 'import habitat; print("habitat version:", habitat.__version__)'
pip install habitat-baselines/
python -c 'import habitat_baselines; print("habitat_baselines version:", habitat_baselines.__version__)'
pip install habitat-hitl/
python -c 'import habitat_hitl; print("habitat_hitl version:", habitat_hitl.__version__)'
- run: &build_sdist_and_bdist
name: Build sdist and bdist
command: |
Expand Down
2 changes: 0 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@
"pages/habitat-lab-tdmap-viz.rst",
"pages/habitat2.rst",
"pages/view-transform-warp.rst",
"pages/metadata-taxonomy.rst",
]

PLUGINS = [
Expand Down Expand Up @@ -138,7 +137,6 @@
("Habitat Lab TopdownMap Visualization", "habitat-lab-tdmap-viz"),
("Habitat 2.0 Overview", "habitat2"),
("View, Transform and Warp", "view-transform-warp"),
("'user_defined' Metadata Taxonomy", "metadata-taxonomy"),
],
),
("Classes", "classes", []),
Expand Down
113 changes: 0 additions & 113 deletions docs/pages/metadata-taxonomy.rst

This file was deleted.

1 change: 1 addition & 0 deletions examples/hitl/basic_viewer/basic_viewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ def _update_lookat_pos(self):
self._get_camera_lookat_pos(),
radius,
mn.Color3(255 / 255, 0 / 255, 0 / 255),
24,
)

@property
Expand Down
6 changes: 3 additions & 3 deletions examples/hitl/pick_throw_vr/pick_throw_vr.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,7 @@ def __init__(self, app_service: AppService):
assert not self._app_service.hitl_config.camera.first_person_mode

self._nav_helper = GuiNavigationHelper(
self._app_service,
self.get_gui_controlled_agent_index(),
user_index=0,
self._app_service, self.get_gui_controlled_agent_index()
)
self._throw_helper = GuiThrowHelper(
self._app_service, self.get_gui_controlled_agent_index()
Expand Down Expand Up @@ -485,10 +483,12 @@ def _get_target_object_positions(self):
)

def _draw_circle(self, pos, color, radius):
num_segments = 24
self._app_service.gui_drawer.draw_circle(
pos,
radius,
color,
num_segments,
)

def _add_target_object_highlight_ring(
Expand Down
8 changes: 4 additions & 4 deletions examples/hitl/rearrange/rearrange.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,9 +84,7 @@ def __init__(
)

self._nav_helper = GuiNavigationHelper(
self._app_service,
self.get_gui_controlled_agent_index(),
user_index=0,
self._app_service, self.get_gui_controlled_agent_index()
)
self._episode_helper = self._app_service.episode_helper

Expand Down Expand Up @@ -123,7 +121,7 @@ def _update_grasping_and_set_act_hints(self):
color = mn.Color3(0, 255 / 255, 0) # green
goal_position = self._goal_positions[self._held_target_obj_idx]
self._app_service.gui_drawer.draw_circle(
goal_position, end_radius, color
goal_position, end_radius, color, 24
)

self._nav_helper.draw_nav_hint_from_agent(
Expand All @@ -140,6 +138,7 @@ def _update_grasping_and_set_act_hints(self):
can_place_position,
self._can_grasp_place_threshold,
mn.Color3(255 / 255, 255 / 255, 0),
24,
)

if self._app_service.gui_input.get_key_down(GuiInput.KeyNS.SPACE):
Expand Down Expand Up @@ -273,6 +272,7 @@ def _update_task(self):
can_grasp_position,
self._can_grasp_place_threshold,
mn.Color3(255 / 255, 255 / 255, 0),
24,
)

def get_gui_controlled_agent_index(self):
Expand Down
14 changes: 0 additions & 14 deletions examples/hitl/rearrange_v2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,6 @@ git clone --branch articulated-scenes --single-branch --depth 1 https://huggingf
mv fphab fpss
```

To test the Habitat-LLM episodes in `rearrange_v2` you'll need to download and unzip the following [episode dataset](https://drive.google.com/file/d/1zFCBiWE_XFY0Ry9CZOV_NF_rfxBw1y-F/view?usp=sharing) in Habitat-Lab root directory. In addition, you'll need YCB, GSO, AI2THOR, and ABO object assets. To download these assets use the following commands:

```
cd data
git clone https://huggingface.co/datasets/ai-habitat/OVMM_objects objects --recursive
cd objects
git checkout 3893a735352b92d46505f35d759553f5fc82a39b
```

## Data directory

Run `rearrange_v2` from the Habitat-lab root directory. It will expect `data/` for Habitat-lab data, and it will also look for `examples/hitl/rearrange_v2/app_data/demo.json.gz` (included alongside source files in our git repo).
Expand All @@ -42,11 +33,6 @@ Headless server:
python examples/hitl/rearrange_v2/rearrange_v2.py +experiment=headless_server
```

To test Habitat-LLM episodes using a user-controlled humanoid use:
```bash
python examples/hitl/rearrange_v2/rearrange_v2.py --config-name lang_rearrange_humanoid_only
```

## Controls
See on-screen help text. In addition, press `1` or `2` to select an episode.

Expand Down

This file was deleted.

Loading