Skip to content

Commit

Permalink
Automatic install script for downloading data (#299)
Browse files Browse the repository at this point in the history
* add install script

* FIx the install script

* update instructions

* uppdate scripts

* Update projects/habitat_ovmm/README.md

Co-authored-by: Arun Ramachandran <[email protected]>

---------

Co-authored-by: Arun Ramachandran <[email protected]>
  • Loading branch information
cpaxton and JHurricane96 authored Jul 25, 2023
1 parent 50824db commit 7c0a4dc
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 5 deletions.
19 changes: 14 additions & 5 deletions projects/habitat_ovmm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,20 @@

## Dataset Setup

Run `git lfs install` to install Git LFS, which is used to manage the OVMM dataset.
Run `git lfs install` to install Git LFS, which is used to manage the OVMM dataset. Please sign in [here](https://huggingface.co/datasets/hssd/hssd-hab/tree/ovmm) and accept the license for using HSSD scenes.

### Scene dataset setup
You can then use the following command to download data:
```
$HOME_ROBOT_ROOT/projects/habitat_ovmm/install.sh
```

### Detailed Explanation

If anything goes wrong, you can check out this explanation of the different steps.

#### Scene dataset setup

Please sign in [here](https://huggingface.co/datasets/hssd/hssd-hab/tree/ovmm) and accept the license for using HSSD scenes before proceeding to download them.
Please sign in [here](https://huggingface.co/datasets/hssd/hssd-hab/tree/ovmm) and accept the license for using HSSD scenes before proceeding to download them. You will need your login information to proceed.
```
# Download the scenes
git submodule update --init data/hssd-hab
Expand All @@ -33,7 +42,7 @@ git lfs pull
cd -
```

### Download the Episodes
#### Download the Episodes

These describe where objects are and where the robot starts:

Expand All @@ -49,7 +58,7 @@ cd -
```


### Download the Robot Model
#### Download the Robot Model

Download and unzip the robot model:
```
Expand Down
47 changes: 47 additions & 0 deletions projects/habitat_ovmm/install.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
#!/usr/bin/env bash
# Copyright (c) Meta Platforms, Inc. and affiliates.
#
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.


# Download the scenes
cd $HOME_ROBOT_ROOT
git submodule update --init --recursive

echo "Download the scenes..."
git submodule update --init data/hssd-hab

# Download the objects and metadata
cd $HOME_ROBOT_ROOT
echo "Download the objects..."
git submodule update --init data/objects

cd $HOME_ROBOT_ROOT
echo "Download the episodes..."
git submodule update --init data/datasets/ovmm

echo "Safety; make sure you have downloaded everything."
echo "If these are empty, you may have too old a git version."
cd $HOME_ROBOT_ROOT/data/hssd-hab
git lfs pull
cd -

cd $HOME_ROBOT_ROOT/data/objects
git lfs pull
cd -

cd $HOME_ROBOT_ROOT/data/datasets/ovmm
git lfs pull
cd -

echo "Download the robot model..."
mkdir -p $HOME_ROBOT_ROOT/data/robots/hab_stretch
cd $HOME_ROBOT_ROOT/data/robots/hab_stretch
echo $HOME_ROBOT_ROOT/data/robots/hab_stretch

echo "Unzip the robot model..."
wget http://dl.fbaipublicfiles.com/habitat/robots/hab_stretch_v1.0.zip
unzip hab_stretch_v1.0.zip

echo "Done!"

0 comments on commit 7c0a4dc

Please sign in to comment.