Official Code for ICML 2021 paper "Revisiting Point Cloud Shape Classification with a Simple and Effective Baseline"

Overview

Revisiting Point Cloud Shape Classification with a Simple and Effective Baseline
Ankit Goyal, Hei Law, Bowei Liu, Alejandro Newell, Jia Deng
International Conference on Machine Learning (ICML), 2021

If you find our work useful in your research, please consider citing:

@article{goyal2021revisiting,
  title={Revisiting Point Cloud Shape Classification with a Simple and Effective Baseline},
  author={Goyal, Ankit and Law, Hei and Liu, Bowei and Newell, Alejandro and Deng, Jia},
  journal={International Conference on Machine Learning},
  year={2021}
}

Getting Started

First clone the repository. We would refer to the directory containing the code as SimpleView.

git clone [email protected]:princeton-vl/SimpleView.git

Requirements

The code is tested on Linux OS with Python version 3.7.5, CUDA version 10.0, CuDNN version 7.6 and GCC version 5.4. We recommend using these versions especially for installing pointnet++ custom CUDA modules.

Install Libraries

We recommend you first install Anaconda and create a virtual environment.

conda create --name simpleview python=3.7.5

Activate the virtual environment and install the libraries. Make sure you are in SimpleView.

conda activate simpleview
pip install -r requirements.txt
conda install sed  # for downloading data and pretrained models

For PointNet++, we need to install custom CUDA modules. Make sure you have access to a GPU during this step. You might need to set the appropriate TORCH_CUDA_ARCH_LIST environment variable depending on your GPU model. The following command should work for most cases export TORCH_CUDA_ARCH_LIST="6.0;6.1;6.2;7.0;7.5". However, if the install fails, check if TORCH_CUDA_ARCH_LIST is correctly set. More details could be found here.

cd pointnet2_pyt && pip install -e . && cd ..

Download Datasets and Pre-trained Models

Make sure you are in SimpleView. download.sh script can be used for downloading all the data and the pretrained models. It also places them at the correct locations. First, use the following command to provide execute permission to the download.sh script.

chmod +x download.sh

To download ModelNet40 execute the following command. This will download the ModelNet40 point cloud dataset released with pointnet++ as well as the validation splits used in our work.

./download.sh modelnet40

To download the pretrained models, execute the following command.

./download.sh pretrained

Code Organization

  • SimpleView/models: Code for various models in PyTorch.
  • SimpleView/configs: Configuration files for various models.
  • SimpleView/main.py: Training and testing any models.
  • SimpleView/configs.py: Hyperparameters for different models and dataloader.
  • SimpleView/dataloader.py: Code for different variants of the dataloader.
  • SimpleView/*_utils.py: Code for various utility functions.

Running Experiments

Training and Config files

To train or test any model, we use the main.py script. The format for running this script is as follows.

python main.py --exp-config <path to the config>

The config files are named as <protocol>_<model_name><_extra>_run_<seed>.yaml (<protocol> ∈ [dgcnn, pointnet2, rscnn]; <model_name> ∈ [dgcnn, pointnet2, rscnn, pointnet, simpleview]; <_extra> ∈ ['',valid,0.5,0.25] ). For example, the config file to run an experiment for PointNet++ in DGCNN protocol with seed 1 dgcnn_pointnet2_run_1.yaml. To run a new experiment with a different seed, you need to change the SEED parameter in the config file. For all our experiments (including on the validation set) we do 4 runs with different seeds.

As discussed in the paper for the PointNet++ and SimpleView protocols, we need to first run an experiment to tune the number of epochs on the validation set. This could be done by first running the experiment <pointnet2/dgcnn>_<model_name>_valid_run_<seed>.yaml and then running the experiment <pointnet2/dgcnn>_<model_name>_run_<seed>.yaml. Based on the number of epochs achieving the best performance on the validation set, one could use the model trained on the complete training set to get the final test performance.

To train models on the partial training set (Table 7), use the configs named as dgcnn_<model_name>_valid_<0.25/0.5>_run_<seed>.yaml and <dgcnn>_<model_name>_<0.25/0.5>_run_<seed>.yaml.

Even with the same SEED the results could vary slightly because of the randomization introduced for faster cuDNN operations. More details could be found here

SimpleView Protocol

To run an experiment in the SimpleView protocol, there are two stages.

  • First tune the number of epochs on the validation set. This is done using configs dgcnn_<model_name>_valid_run_<seed>.yaml. Find the best number of epochs on the validation set, evaluated at every 25th epoch.
  • Train the model on the complete training set using configs dgcnn_<model_name>_run_<seed>.yaml. Use the performance on the test set at the fine-tuned number of epochs as the final performance.

Evaluate a pretrained model

We provide pretrained models. They can be downloaded using the ./download pretrained command and are stored in the SimpleView/pretrained folder. To test a pretrained model, the command is of the following format.

python main.py --entry <test/rscnn_vote/pn2_vote> --model-path pretrained/<cfg_name>/<model_name>.pth --exp-config configs/<cfg_name>.yaml

We list the evaluation commands in the eval_models.sh script. For example to evaluate models on the SimpleView protocol, use the commands here. Note that for the SimpleView and the Pointnet2 protocols, the model path has names in the format model_<epoch_id>.pth. Here epoch_id represents the number of epochs tuned on the validation set.

Performance of the released pretrained models on ModelNet40

Protocol → DGCNN - Smooth DCGNN - CE. RSCNN - No Vote PointNet - No Vote SimpleView
Method↓ (Tab. 2, Col. 7) (Tab. 2, Col. 6) (Tab. 2, Col. 5) (Tab. 2, Col. 2) (Tab. 4, Col. 2)
SimpleView 93.9 93.2 92.7 90.8 93.3
PointNet++ 93.0 92.8 92.6 89.7 92.6
DGCNN 92.6 91.8 92.2 89.5 92.0
RSCNN 92.3 92.0 92.2 89.4 91.6
PointNet 90.7 90.0 89.7 88.8 90.1

Acknowlegements

We would like to thank the authors of the following reposities for sharing their code.

  • PointNet: Deep Learning on Point Sets for 3D Classification and Segmentation: 1, 2
  • PointNet++: Deep Hierarchical Feature Learning on Point Sets in a Metric Space: 1, 2
  • Relation-Shape Convolutional Neural Network for Point Cloud Analysis: 1
  • Dynamic Graph CNN for Learning on Point Clouds: 1
Owner
Princeton Vision & Learning Lab
Princeton Vision & Learning Lab
Automatic Differentiation Multipole Moment Molecular Forcefield

Automatic Differentiation Multipole Moment Molecular Forcefield Performance notes On a single gpu, using waterbox_31ang.pdb example from MPIDplugin wh

4 Jan 07, 2022
Official implementation of "CrossPoint: Self-Supervised Cross-Modal Contrastive Learning for 3D Point Cloud Understanding" (CVPR, 2022)

CrossPoint: Self-Supervised Cross-Modal Contrastive Learning for 3D Point Cloud Understanding (CVPR'22) Paper Link | Project Page Abstract : Manual an

Mohamed Afham 152 Dec 23, 2022
SMORE: Knowledge Graph Completion and Multi-hop Reasoning in Massive Knowledge Graphs

SMORE: Knowledge Graph Completion and Multi-hop Reasoning in Massive Knowledge Graphs SMORE is a a versatile framework that scales multi-hop query emb

Google Research 135 Dec 27, 2022
MILK: Machine Learning Toolkit

MILK: MACHINE LEARNING TOOLKIT Machine Learning in Python Milk is a machine learning toolkit in Python. Its focus is on supervised classification with

Luis Pedro Coelho 610 Dec 14, 2022
Code and real data for the paper "Counterfactual Temporal Point Processes", available at arXiv.

counterfactual-tpp This is a repository containing code and real data for the paper Counterfactual Temporal Point Processes. Pre-requisites This code

Networks Learning 11 Dec 09, 2022
Danfeng Hong, Lianru Gao, Jing Yao, Bing Zhang, Antonio Plaza, Jocelyn Chanussot. Graph Convolutional Networks for Hyperspectral Image Classification, IEEE TGRS, 2021.

Graph Convolutional Networks for Hyperspectral Image Classification Danfeng Hong, Lianru Gao, Jing Yao, Bing Zhang, Antonio Plaza, Jocelyn Chanussot T

Danfeng Hong 154 Dec 13, 2022
BankNote-Net: Open dataset and encoder model for assistive currency recognition

BankNote-Net: Open Dataset for Assistive Currency Recognition Millions of people around the world have low or no vision. Assistive software applicatio

Microsoft 13 Oct 28, 2022
A Machine Teaching Framework for Scalable Recognition

MEMORABLE This repository contains the source code accompanying our ICCV 2021 paper. A Machine Teaching Framework for Scalable Recognition Pei Wang, N

2 Dec 08, 2021
Implementation of Change-Based Exploration Transfer (C-BET)

Implementation of Change-Based Exploration Transfer (C-BET), as presented in Interesting Object, Curious Agent: Learning Task-Agnostic Exploration.

Simone Parisi 29 Dec 04, 2022
A framework for GPU based high-performance medical image processing and visualization

FAST is an open-source cross-platform framework with the main goal of making it easier to do high-performance processing and visualization of medical images on heterogeneous systems utilizing both mu

Erik Smistad 315 Dec 30, 2022
Few-Shot Object Detection via Association and DIscrimination

Few-Shot Object Detection via Association and DIscrimination Code release of our NeurIPS 2021 paper: Few-Shot Object Detection via Association and DIs

Cao Yuhang 49 Dec 18, 2022
ManipulaTHOR, a framework that facilitates visual manipulation of objects using a robotic arm

ManipulaTHOR: A Framework for Visual Object Manipulation Kiana Ehsani, Winson Han, Alvaro Herrasti, Eli VanderBilt, Luca Weihs, Eric Kolve, Aniruddha

AI2 65 Dec 30, 2022
[CVPR 2022 Oral] Balanced MSE for Imbalanced Visual Regression https://arxiv.org/abs/2203.16427

Balanced MSE Code for the paper: Balanced MSE for Imbalanced Visual Regression Jiawei Ren, Mingyuan Zhang, Cunjun Yu, Ziwei Liu CVPR 2022 (Oral) News

Jiawei Ren 267 Jan 01, 2023
My tensorflow implementation of "A neural conversational model", a Deep learning based chatbot

Deep Q&A Table of Contents Presentation Installation Running Chatbot Web interface Results Pretrained model Improvements Upgrade Presentation This wor

Conchylicultor 2.9k Dec 28, 2022
This is an official implementation for the WTW Dataset in "Parsing Table Structures in the Wild " on table detection and table structure recognition.

WTW-Dataset This is an official implementation for the WTW Dataset in "Parsing Table Structures in the Wild " on ICCV 2021. Here, you can download the

109 Dec 29, 2022
Diverse Image Captioning with Context-Object Split Latent Spaces (NeurIPS 2020)

Diverse Image Captioning with Context-Object Split Latent Spaces This repository is the PyTorch implementation of the paper: Diverse Image Captioning

Visual Inference Lab @TU Darmstadt 34 Nov 21, 2022
Source code for the paper "PLOME: Pre-training with Misspelled Knowledge for Chinese Spelling Correction" in ACL2021

PLOME:Pre-training with Misspelled Knowledge for Chinese Spelling Correction (ACL2021) This repository provides the code and data of the work in ACL20

197 Nov 26, 2022
The Pytorch code of "Joint Distribution Matters: Deep Brownian Distance Covariance for Few-Shot Classification", CVPR 2022 (Oral).

DeepBDC for few-shot learning        Introduction In this repo, we provide the implementation of the following paper: "Joint Distribution Matters: Dee

FeiLong 116 Dec 19, 2022
Code release for General Greedy De-bias Learning

General Greedy De-bias for Dataset Biases This is an extention of "Greedy Gradient Ensemble for Robust Visual Question Answering" (ICCV 2021, Oral). T

4 Mar 15, 2022
R-package accompanying the paper "Dynamic Factor Model for Functional Time Series: Identification, Estimation, and Prediction"

dffm The goal of dffm is to provide functionality to apply the methods developed in the paper “Dynamic Factor Model for Functional Time Series: Identi

Sven Otto 3 Dec 09, 2022