Coder Social home page Coder Social logo

bruinxiong / pvn3d Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ethnhe/pvn3d

0.0 2.0 0.0 79.31 MB

Code for "A Deep Point-wise 3D Keypoints Hough Voting Network for 6DoF Pose Estimation", CVPR 2020

Jupyter Notebook 0.66% Python 93.08% C++ 2.61% Objective-C 0.04% Cuda 3.44% Shell 0.18%

pvn3d's Introduction

PVN3D

This is the source code for PVN3D: A Deep Point-wise 3D Keypoints Voting Network for 6DoF Pose Estimation, CVPR 2020. (PDF, Video).

Watch the video

Installation

  • Install CUDA9.0/CUDA10.0
  • Set up python environment from requirement.txt:
    pip3 install -r requirement.txt 
  • Install tkinter through sudo apt install python3-tk
  • Install python-pcl.
  • Install PointNet++:
    python3 setup.py build_ext

Datasets

  • LineMOD: Download the preprocessed LineMOD dataset from here (refer from DenseFusion). Unzip it and link the unzipped Linemod_preprocessed/ to pvn3d/datasets/linemod/Linemod_preprocessed:

    ln -s path_to_unzipped_Linemod_preprocessed pvn3d/dataset/linemod/
  • YCB-Video: Download the YCB-Video Dataset from PoseCNN. Unzip it and link the unzippedYCB_Video_Dataset to pvn3d/datasets/ycb/YCB_Video_Dataset:

    ln -s path_to_unzipped_YCB_Video_Dataset pvn3d/datasets/ycb/

Training and evaluating

Training on the LineMOD Dataset

  • First, generate synthesis data for each object using scripts from raster triangle.
  • Train the model for the target object. Take object ape for example:
    cd pvn3d
    python3 -m train.train_linemod_pvn3d --cls ape
    The trained checkpoints are stored in train_log/linemod/checkpoints/{cls}/, train_log/linemod/checkpoints/ape/ in this example.

Evaluating on the LineMOD Dataset

  • Start evaluation by:
    cls='ape'
    tst_mdl=train_log/linemod/checkpoints/${cls}/${cls}_pvn3d_best.pth.tar
    python3 -m train.train_linemod_pvn3d -checkpoint $tst_mdl -eval_net --test --cls $cls
    You can evaluate different checkpoint by revising tst_mdl to the path of your target model.
  • We provide our pre-trained models for each object here. Download them and move them to their according folders. For example, move the ape_pvn3d_best.pth.tar to train_log/linemod/checkpoints/ape/. Then revise tst_mdl=train_log/linemod/checkpoints/ape/ape_pvn3d_best.path.tar for testing.

Training on the YCB-Video Dataset

  • Preprocess the validation set to speed up training:
    cd pvn3d
    python3 -m datasets.ycb.preprocess_testset
  • Start training on the YCB-Video Dataset by:
    python3 -m train.train_ycb_pvn3d
    The trained model checkpoints are stored in train_log/ycb/checkpoints/

Evaluating on the YCB-Video Dataset

  • Start evaluating by:
    tst_mdl=train_log/ycb/checkpoints/pvn3d_best.pth.tar
    python3 -m train.train_ycb_pvn3d -checkpoint $tst_mdl -eval_net --test
    You can evaluate different checkpoint by revising the tst_mdl to the path of your target model.
  • We provide our pre-trained models here. Download the ycb pre-trained model, move it to train_log/ycb/checkpoints/ and modify tst_mdl for testing.

Results

  • Evaluation result on the LineMOD dataset: res_lm
  • Evaluation result on the YCB-Video dataset: res_ycb
  • Visualization of some predicted poses on YCB-Video dataset: vis_ycb
  • Joint training for distinguishing objects with similar appearance but different in size: seg

Citations

Please cite PVN3D if you use this repository in your publications:

@inproceedings{he2020pvn3d,
  title={PVN3D: A Deep Point-wise 3D Keypoints Voting Network for 6DoF Pose Estimation},
  author={He, Yisheng and Sun, Wei and Huang, haibin and Liu, Jianran and Fan, Haoqiang and Sun, Jian}
  booktitle={CVPR},
  year={2020}
}

pvn3d's People

Contributors

ethnhe avatar

Watchers

James Cloos avatar paper2code - bot avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.