ThibaultGROUEIX / ChamferDistancePytorch

Chamfer Distance in Pytorch with f-score
MIT License
326 stars 43 forks source link

ModuleNotFoundError: No module named 'chamfer3D.dist_chamfer_3D'; 'chamfer3D' is not a package #28

Closed Master-cai closed 1 year ago

Master-cai commented 1 year ago

Hi, thanks for your wonderful work, but i have some problem when installing chamfer3D.

i tried to install it by the command pip install -U . and python setup.py install --user , but when i try to run the example code in your README it come out the error "ModuleNotFoundError".

image

Also, i try it with pytorch=1.7.1 which shows the same error. Do you have any idea about it? thx!

ark1234 commented 1 year ago

I met same problem, how do you solve it?

Master-cai commented 1 year ago

use this project as a self-made package.

do not install it by pip, if you have done it, uninstall it first.

then just make the module in your python import search path .for example, you can add it manually:

import sys
sys.path.append("submodules/ChamferDistancePytorch")
import torch
import chamfer3D.dist_chamfer_3D
ark1234 commented 1 year ago

It works, thank you so much!