Giter Site home page Giter Site logo

pointnet2.pytorch's Introduction

Introduction

An unofficial PyTorch Implementation of PointNet++: Deep Hierarchical Feature Learning on Point Sets in a Metric Space[NIPS 2017].

Requirements

  • PyTorch, Python3, TensorboardX, tqdm, fire

Classification

  • Start

    • Dataset: ModelNet40, download it from Official Site or Baidu Disk with hi1i.

    • Train

      python train_clss.py --data_root your_data_root --log_dir your_log_dir
      
      eg.
      python train_clss.py --data_root /root/modelnet40_normal_resampled --log_dir cls_ssg_1024
      
    • Evaluate

      python evaluate.py evaluate_cls model data_root checkpoint npoints
      
      eg.
      python evaluate.py evaluate_cls pointnet2_cls_ssg  /root/modelnet40_normal_resampled \
      checkpoints/pointnet2_cls_250.pth 1024
      
      python evaluate.py evaluate_cls pointnet2_cls_msg root/modelnet40_normal_resampled \
      checkpoints/pointnet2_cls_250.pth 1024
      
  • Performance(the first row is the results reported in Paper, the following rows are results reported from this repo.)

    Model NPoints Aug Accuracy(%)
    PointNet2(official) 5000 91.7
    PointNet2_SSG 1024 91.8
    PointNet2_SSG 4096 91.7
    PointNet2_SSG 4096 90.5
    PointNet2_MSG 4096 91.0
    Model Train_NPoints DP Test_NPoints Accuracy(%)
    PointNet2_SSG 1024 256 67.9
    PointNet2_SSG 1024 256 90.8
    PointNet2_SSG 1024 1024 91.8
    PointNet2_SSG 1024 1204 91.9
  • Train Your own Dataset

    • Prepare the dataset(n classes) in the ModelNet40 structure
      CustomData(dir)
          |- class1(dir)
              | - class1_name11.txt
              | - class1_name12.txt
              ...
          |- class2(dir)
              | - class2_name21.txt
              | - class2_name22.txt
              ...
          |- classn(dir)
          |- shape_names.txt
              | - class1(line1)
              | - class2(line2)
              | - ...
              | - classn(linen)
          |- train.txt
              | - class1_name11
              | - class2_name21
              | - class2_name22
              | - ...
              | - classn_namen1
          |- test.txt
              | - class1_name12
              | - class2_name22
              | - ...
              | - classn_namen2
      
    • Start to train
      python train_custom_cls.py --data_root your_datapath/CustomData --nclasses 2 --npoints 2048
      
    • Start to evaluate
      python evaluate_custom.py evaluate_cls pointnet2_cls_ssg your_datapath/CustomData work_dirs/checkpoints/pointnet2_cls_250.pth 2
      

Part Segmentation

  • Start

    • Dataset: ShapeNet part, download it from Official Site or Baidu Disk with 3e5z.

    • Train

      python train_part_seg.py --data_root your_data_root --log_dir your_log_dir
      
      eg.
      python train_part_seg.py --data_root /root/shapenetcore_partanno_segmentation_benchmark_v0_normal \
      --log_dir seg_ssg --batch_size 64
      
    • Evaluate

      python evaluate.py evaluate_seg data_root checkpoint
      
      eg.
      python evaluate.py evaluate_seg /root/shapenetcore_partanno_segmentation_benchmark_v0_normal \
      seg_ssg/checkpoints/pointnet2_cls_250.pth
      
  • Metrics: Average IoU

    Model Metrics mean aero bag cap car chair ear phone guitar knife lamp laptop motor mug pistol rocket skate board table
    PointNet2(official) IoU 85.1 82.4 79.0 87.7 77.3 90.8 71.8 91.0 85.9 83.7 95.3 71.6 94.1 81.3 58.7 76.4 82.6
    PointNet2_SSG IoU 84.1 82.3 75.0 80.1 77.8 90.2 73.7 90.7 84.1 82.9 95.0 69.3 93.3 80.3 55.6 76.3 80.7
    PointNet2_SSG Accuracy 93.2 89.9 89.0 85.5 91.8 94.4 93.5 96.1 91.1 89.2 96.9 87.4 96.4 93.7 77.2 95.9 94.8

Reference

pointnet2.pytorch's People

Contributors

zhulf0804 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

pointnet2.pytorch's Issues

Formatting custom dataset

what would be the best to way to run newly acquired pointclouds through a trained model without needing to create a new custom dataset with the clouds each time? seems like it needs the train.txt shape_names.txt and test.txt redone on each new run

About normal

What should i do if i don‘t want to use normal?
Thanks for your answer.

Using code for just xyz attributes

Hi!
Many thanks for sharing your code. Could you please let me know how I can run your repository for point clouds that have just xyz attributes?
Thanks in advance.
Best regards,
Narges

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.