/3D-KNN

:globe_with_meridians: Chamfer distance-based KNN algorithm for point cloud models comparison

Primary LanguagePython

Chamfer distance-based KNN for point cloud models comparison

This repository provides Python implementation of KNN algorithm for point cloud models comparison by Chamfer distance

Navigation

  • find_nearest.py -- finds top nearest 3D models for target model
  • compare.py -- compares two 3D models
  • show.py -- shows 3D model from specified point cloud file
  • quick_run/ -- contains bash-scripts for quick running above scripts
  • models/ -- contains point cloud models

Models

Normal

Diffused

Chamfer distance

The Chamfer distance between two point cloud models U and V is given by the average of distances between each point u in U, and its nearest point v in V:

Results

If we try to find closest diffused model for normal bunny model by running

python find_nearest.py models/normal/bunny.ply \
                       models/diffused/ \
                       -s 1000

we obrain next results:

K Nearest Models to models/normal/bunny.ply:
models/diffused/bunny_D02_L04.ply:      0.0021084902964208802
models/diffused/cube_D02_L04.ply:       0.004529813682506928
models/diffused/sphere_D02_L04.ply:     0.0054064578883468795
models/diffused/vase_D02_L04.ply:       0.029371351044122095
models/diffused/dragon_D02_L04.ply:     0.030610421838445444

Note that here we used only 1000 random points from original model (~30k points) for improving computation speed.

So above results mean that for subsampled target normal bunny model

this algorithm performed next ranking on proposed diffused models:

Sources