1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

【論文まとめ】PointPillarsの論文と実装例の確認

Posted at

PointPillarsの論文

概要

PointPillarsは点群における物体検出を行う際に、「PointNetに基づいて柱(pillars/vertical columns)上に構築された点群の表現の学習を行った研究」です。

PointPillars1.png
PointPillars論文 Figure.3

PointPillars2.png
PointPillars論文 Figure.1

PointPillarsの処理の流れ

PointPillars3.png
PointPillars論文 Figure.2

当項ではPointPillarsの処理の流れについて確認します。基本的にはFeature Encoder、2D convolutional backbone、Detection Headの3つの処理から構成されるので以下ではそれぞれについて詳しく確認します。

Feature Encoder

PointPillarsのFeature Encoderでは点群に2Dの画像と同じような処理を適用するにあたって点群を疑似画像(pseudo-image)の形式に変換します。

入力のサイズ 出力のサイズ 適用する処理
(D,P,N) (C,P,N) PointNet
(C,P,N) (C,P) max operation
(C,P) (C,H,W) back to the original pillar locations to create a pseudo-image

2D convolutional backbone

Detection Head

PointPillarsの実装例

当節では下記のPointPillarsの実装例について確認します。

必要ライブラリのインストールと動作確認

まず、requirements.txtに基づいて下記のインストールを行います。

requirements.txt
numba
numpy
open3d
opencv_python
PyYAML
setuptools
tensorboard
tqdm

次に環境に合ったPyTorchのインストールを行い、下記のコマンドを実行します。

$ python setup.py build_ext --inplace
$ pip install .

次にReadME.mdDatasetsを元に下記のようなディレクトリ構造でデータを用意します。

data
    |- training
        |- calib (#7481 .txt)
        |- image_2 (#7481 .png)
        |- label_2 (#7481 .txt)
        |- velodyne (#7481 .bin)
        |- velodyne_reduced (#7481 .bin)
    |- testing
        |- calib (#7518 .txt)
        |- image_2 (#7518 .png)
        |- velodyne (#7518 .bin)
        |- velodyne_reduced (#7518 .bin)
    |- kitti_gt_database (# 19700 .bin)
    |- kitti_infos_train.pkl
    |- kitti_infos_val.pkl
    |- kitti_infos_trainval.pkl
    |- kitti_infos_test.pkl
    |- kitti_dbinfos_train.pkl

ここまでが完了したら下記を実行することで推論を行うことができます。

$ python test.py --ckpt pretrained/epoch_160.pth --pc_path data/testing/velodyne/000001.bin --calib_path data/testing/calib/000001.txt --img_path data/testing/image_2/000001.png

・実行結果
PointPillars4.png
PointPillars5.png

実行結果より点群から車が識別できていることが確認できます。

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?