Commit d8517952 authored by liyinhao's avatar liyinhao
Browse files

add data structure in readme

parent 64298bdb
### Prepare ScanNet Data ### Prepare ScanNet Data
We follow the procedure in [votenet](https://github.com/facebookresearch/votenet/). We follow the procedure in [votenet](https://github.com/facebookresearch/votenet/).
1. Download ScanNet v2 data [HERE](https://github.com/ScanNet/ScanNet). Move/link the `scans` folder such that under `scans` there should be folders with names such as `scene0001_01`. 1. Download ScanNet v2 data [HERE](https://github.com/ScanNet/ScanNet). Link or move the 'scans' folder to this level of directory.
2. Extract point clouds and annotations (semantic seg, instance seg etc.) by running `python batch_load_scannet_data.py`, which will create a folder named `scannet_train_instance_data` here. 2. In this level of directory, extract point clouds and annotations by running `python batch_load_scannet_data.py`.
3. Enter the project root directory, generate training data by running `python tools/create_data.py scannet --root-path ./data/scannet --out-dir ./data/scannet --extra-tag scannet`. 3. Enter the project root directory, generate training data by running `python tools/create_data.py scannet --root-path ./data/scannet --out-dir ./data/scannet --extra-tag scannet`.
```
scannet
├── scannet_utils.py
├── load_scannet_data.py
├── README.md
├── scans
```
...@@ -3,10 +3,29 @@ We follow the procedure in [votenet](https://github.com/facebookresearch/votenet ...@@ -3,10 +3,29 @@ We follow the procedure in [votenet](https://github.com/facebookresearch/votenet
1. Download SUNRGBD v2 data [HERE](http://rgbd.cs.princeton.edu/data/). Then, move SUNRGBD.zip, SUNRGBDMeta2DBB_v2.mat, SUNRGBDMeta3DBB_v2.mat and SUNRGBDtoolbox.zip to the OFFICIAL_SUNRGBD folder, unzip the zip files. 1. Download SUNRGBD v2 data [HERE](http://rgbd.cs.princeton.edu/data/). Then, move SUNRGBD.zip, SUNRGBDMeta2DBB_v2.mat, SUNRGBDMeta3DBB_v2.mat and SUNRGBDtoolbox.zip to the OFFICIAL_SUNRGBD folder, unzip the zip files.
2. Enter the `matlab` folder, run `extract_split.m`, `extract_rgbd_data_v2.m` and `extract_rgbd_data_v1.m` to extract point clouds and annotations. 2. Enter the `matlab` folder, Extract point clouds and annotations by running `extract_split.m`, `extract_rgbd_data_v2.m` and `extract_rgbd_data_v1.m`.
3. Back to this level, prepare data by running `python sunrgbd_data.py --gen_v1_data` 3. Back to this level of directory, prepare data by running `python sunrgbd_data.py --gen_v1_data`.
4. Enter the project root directory, Generate training data by running `python tools/create_data.py sunrgbd --root-path ./data/sunrgbd --out-dir ./data/sunrgbd --extra-tag sunrgbd`.
4. Enter the project root directory, generate training data by running `python tools/create_data.py sunrgbd --root-path ./data/sunrgbd --out-dir ./data/sunrgbd --extra-tag sunrgbd`.
NOTE: SUNRGBDtoolbox.zip should have MD5 hash `18d22e1761d36352f37232cba102f91f` (you can check the hash with `md5 SUNRGBDtoolbox.zip` on Mac OS or `md5sum SUNRGBDtoolbox.zip` on Linux) NOTE: SUNRGBDtoolbox.zip should have MD5 hash `18d22e1761d36352f37232cba102f91f` (you can check the hash with `md5 SUNRGBDtoolbox.zip` on Mac OS or `md5sum SUNRGBDtoolbox.zip` on Linux)
```
sunrgbd
├── sunrgbd_utils.py
├── sunrgbd_data.py
├── README.md
├── matlab
│ ├── extract_rgbd_data_v1.m
│ ├── extract_rgbd_data_v2.m
│ ├── extract_split.m
├── OFFICIAL_SUNRGBD
│ ├── SUNRGBD
│ ├── SUNRGBDMeta2DBB_v2.mat
│ ├── SUNRGBDMeta3DBB_v2.mat
│ ├── SUNRGBDtoolbox
```
...@@ -103,9 +103,10 @@ def extract_sunrgbd_data(idx_filename, ...@@ -103,9 +103,10 @@ def extract_sunrgbd_data(idx_filename,
save_votes=False, save_votes=False,
use_v1=False, use_v1=False,
skip_empty_scene=True): skip_empty_scene=True):
""" Extract scene point clouds and """Extract scene point clouds and
bounding boxes (centroids, box sizes, heading angles, semantic classes). bounding boxes (centroids, box sizes, heading angles,
Dumped point clouds and boxes are in upright depth coord. semantic classes). Dumped point clouds and boxes are in
upright depth coord.
Args: Args:
idx_filename: a TXT file where each line is an int number (index) idx_filename: a TXT file where each line is an int number (index)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment