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

pre-commit: go easy on source code for now #41

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ __pycache__
*.temp
*tmp/
*.cpython
experiments/outputs
experiments/outputs
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exclude: 'cosypose|megapose6d'
exclude: 'cosypose|megapose6d|happypose|experiments'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
Expand Down
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@
"python.linting.enabled": true,
"python.linting.flake8Enabled": true,
"python.linting.mypyEnabled": true,
}
}
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,12 @@ Create data dir /somewhere/convenient. The dataset to store are quite large.
export MEGAPOSE_DATA_DIR=/somewhere/convenient
cd $MEGAPOSE_DATA_DIR
wget https://memmo-data.laas.fr/static/examples.tar.xz
tar xf examples.tar.xz
tar xf examples.tar.xz
```

## 1. Download pre-trained MegaPose pose estimation models
Download pose estimation models to $MEGAPOSE_DATA_DIR/megapose-models:

```
python -m happypose.toolbox.utils.download --megapose_models
```
Expand Down Expand Up @@ -78,7 +78,7 @@ download [barbecue sauce](https://drive.google.com/drive/folders/10BIvhnrKGbNr8E

<details>
<summary>Cosypose</summary>

All data used (datasets, models, results, ...) are stored in a directory `local_data` at the root of the repository. Create it with `mkdir local_data` or use a symlink if you want the data to be stored at a different place. We provide the utility `cosypose/scripts/download.py` for downloading required data and models. All of the files can also be [downloaded manually](https://drive.google.com/drive/folders/1JmOYbu1oqN81Dlj2lh6NCAMrC8pEdAtD?usp=sharing).

## BOP Datasets
Expand Down Expand Up @@ -124,15 +124,15 @@ Notes:
```sh
python -m happypose.pose_estimators.cosypose.cosypose.scripts.make_ycbv_compat_models
```

## Models for minimal version

```sh
#ycbv
python -m happypose.toolbox.utils.download --cosypose_model=detector-bop-ycbv-pbr--970850
python -m happypose.toolbox.utils.download --cosypose_model=coarse-bop-ycbv-pbr--724183
python -m happypose.toolbox.utils.download --cosypose_model=refiner-bop-ycbv-pbr--604090

#tless
python -m happypose.toolbox.utils.download --cosypose_model=detector-bop-tless-pbr--873074
python -m happypose.toolbox.utils.download --cosypose_model=coarse-bop-tless-pbr--506801
Expand All @@ -148,11 +148,11 @@ The pre-trained models of the single-view pose estimator can be downloaded using
# YCB-V Single-view refiner
python -m happypose.toolbox.utils.download --cosypose_model=ycbv-refiner-finetune--251020

# YCB-V Single-view refiner trained on synthetic data only
# Only download this if you are interested in retraining the above model
# YCB-V Single-view refiner trained on synthetic data only
# Only download this if you are interested in retraining the above model
python -m happypose.toolbox.utils.download --cosypose_model=ycbv-refiner-syntonly--596719

# T-LESS coarse and refiner models
# T-LESS coarse and refiner models
python -m happypose.toolbox.utils.download --cosypose_model=tless-coarse--10219
python -m happypose.toolbox.utils.download --cosypose_model=tless-refiner--585928
```
Expand Down Expand Up @@ -182,13 +182,13 @@ Notes:
- The Pix2pose detections were extracted using [pix2pose's](https://github.com/kirumang/Pix2Pose) code. We used the detection model from their paper, see [here](https://github.com/kirumang/Pix2Pose#download-pre-trained-weights). For the ViVo detections, their code was slightly modified. The code used to extract detections can be found [here](https://github.com/ylabbe/pix2pose_cosypose).

</details>

<details>
<summary>Megapose</summary>

## 1. Download pre-trained pose estimation models
Download pose estimation models to $MEGAPOSE_DATA_DIR/megapose-models:

```
python -m happypose.toolbox.utils.download --megapose_models
```
1 change: 0 additions & 1 deletion configs/code_snapshot/dsgen_deps.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,3 @@ python_packages_dir:
- ${oc.env:PROJECTS_DIR}/happypose
- ${oc.env:PROJECTS_DIR}/blenderproc
- ${oc.env:PROJECTS_DIR}/bop_toolkit_lib

2 changes: 1 addition & 1 deletion configs/dsgen/default.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
defaults:
- base_dsgen
- base_dsgen
2 changes: 1 addition & 1 deletion configs/dsgen/fastrun.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ defaults:
- default
few: True
verbose: True
debug: True
debug: True
2 changes: 1 addition & 1 deletion configs/dsgen/gso_1M.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
defaults:
- default
dataset_id: gso_1M
dataset_id: gso_1M
2 changes: 1 addition & 1 deletion configs/job_env/jz_yann.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ env:
HP_DATA_DIR: $WORK/data/happypose
MEGAPOSE_DATA_DIR: $WORK/data/megapose
BLENDER_INSTALL_DIR: $WORK/blender/blender-2.93.0-linux-x64
BLENDERPROC_DIR: $WORK/projects/blenderproc
BLENDERPROC_DIR: $WORK/projects/blenderproc
2 changes: 1 addition & 1 deletion configs/job_env/lda.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ env:
HP_DATA_DIR: /home/ylabbe/data/happypose
MEGAPOSE_DATA_DIR: /home/ylabbe/data/megapose-private
BLENDER_INSTALL_DIR: $HOME/blenderproc/blender-2.93.88-linux-x64
BLENDER_PROC_DIR: /home/ylabbe/projects/blenderproc
BLENDER_PROC_DIR: /home/ylabbe/projects/blenderproc
2 changes: 1 addition & 1 deletion configs/local_job/single_gpu.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ defaults:
- base_local_job
nodes: 1
tasks_per_node: 1
gpus_per_node: 1
gpus_per_node: 1
2 changes: 1 addition & 1 deletion configs/local_node/lda.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ defaults:
gpus_per_node: 1
mem_per_gpu: '8GB'
cpus_per_gpu: 12
mem_per_cpu: '2.7GB'
mem_per_cpu: '2.7GB'
4 changes: 2 additions & 2 deletions configs/run_ds_postproc/default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ runner:
cpus_per_task: 1

hydra:
run:
run:
dir: ${oc.env:HP_DATA_DIR}/hydra_outputs/${now:%Y-%m-%d}/${now:%H-%M-%S}

n_jobs: 128
ds_dir: ${oc.env:HP_DATA_DIR}/blender_pbr_datasets/gso_1M
ds_dir: ${oc.env:HP_DATA_DIR}/blender_pbr_datasets/gso_1M
4 changes: 2 additions & 2 deletions configs/run_dsgen/default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@ runner:
cpus_per_task: 1

hydra:
run:
dir: ${oc.env:HP_DATA_DIR}/hydra_outputs/${now:%Y-%m-%d}/${now:%H-%M-%S}
run:
dir: ${oc.env:HP_DATA_DIR}/hydra_outputs/${now:%Y-%m-%d}/${now:%H-%M-%S}
4 changes: 2 additions & 2 deletions configs/run_dsgen/fastrun.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
start_chunk: 0
n_jobs: 4
n_chunks: 4
ds:
ds:
debug: True
verbose: True
overwrite: True
few: True
few: True
2 changes: 1 addition & 1 deletion configs/run_dsgen/gso_1M.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ defaults:
- override /dsgen@ds: gso_1M

n_jobs: 128
n_chunks: 25000
n_chunks: 25000
2 changes: 1 addition & 1 deletion configs/run_dsgen/shapenet_1M.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ defaults:
- override /dsgen@ds: shapenet_1M

n_jobs: 350
n_chunks: 50000
n_chunks: 50000
4 changes: 2 additions & 2 deletions configs/runner/yann_sgpu.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ defaults:
- yann
- single_gpu
- jz
- /job_env:
- /job_env:
- happypose
- lda
- _self_

log_dir: ${oc.env:HP_DATA_DIR}/submitit_logs
log_dir: ${oc.env:HP_DATA_DIR}/submitit_logs
2 changes: 1 addition & 1 deletion configs/slurm_job/jz.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ defaults:
qos: 'qos_gpu-t3'
time: '20:00:00'
additional_parameters:
hint: nomultithread
hint: nomultithread
2 changes: 1 addition & 1 deletion configs/slurm_job/single_gpu.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ defaults:

nodes: 1
tasks_per_node: 1
gpus_per_node: 1
gpus_per_node: 1
2 changes: 1 addition & 1 deletion configs/slurm_job/yann.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
defaults:
- base_slurm_job

account: 'vuw@v100'
account: 'vuw@v100'
2 changes: 1 addition & 1 deletion configs/slurm_queue/gpu_p2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ partition: "gpu_p2"
gpus_per_node: 8
cpus_per_gpu: 3
mem_per_gpu: '32GB'
mem_per_cpu: ???
mem_per_cpu: ???
2 changes: 1 addition & 1 deletion configs/slurm_queue/v100.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ partition: "gpu_p13"
gpus_per_node: 4
cpus_per_gpu: 10
mem_per_gpu: '32GB'
mem_per_cpu: '10GB'
mem_per_cpu: '10GB'
2 changes: 1 addition & 1 deletion configs/snapshot_ignore.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ blenderproc/scripts/
blenderproc/images/
my-notebooks/*.json
colors.json
*.ttf
*.ttf
24 changes: 12 additions & 12 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,39 +55,39 @@ dependencies:
- selenium
- omegaconf
- simplejson
- line_profiler
- line_profiler
- opencv-python
- torchnet
- tqdm
- lxml
- transforms3d
- panda3d
- joblib
- xarray
- xarray
- pandas
- matplotlib
- bokeh
- plyfile
- trimesh
- ipdb
- plyfile
- trimesh
- ipdb
- panda3d-gltf
- colorama
- pyyaml
- ipykernel
- scipy
- pypng
- h5py
- h5py
- seaborn
- kornia
- pyarrow
- dt_apriltags
- kornia
- pyarrow
- dt_apriltags
- open3d
- structlog
- imageio
- progressbar
- pyyaml
- psutil
- webdataset
- opencv-contrib-python
- roma
- torchgeometry
- opencv-contrib-python
- roma
- torchgeometry
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ pin = "^2.6.17"
pybullet = {optional = true, version = "^3.2.5"}
python = "^3.8"


[tool.poetry.extras]
render = ["panda3d", "pybullet"]

Expand Down
1 change: 0 additions & 1 deletion rclone.conf
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
[happypose]
type = http
url = https://www.paris.inria.fr/archive_ylabbeprojectsdata/