a1600012888 / PhysDreamer

Code for PhysDreamer
429 stars 20 forks source link

environment error when running inference #11

Open ExcitedButter opened 3 weeks ago

ExcitedButter commented 3 weeks ago

"Thanks for the great work. Here are some environment errors that I have encountered: Firstly, for the repeated packages in requirements.txt, I just kept "ipython==8.18.1" and "Pillow==10.3.0". I don't know if that makes sense. Also, I found "simple_knn==0.0.0" in requirements.txt to be meaningless. And if I set "simple_knn==1.1.6", there are some errors (ModuleNotFoundError: No module named 'simple_knn' and ModuleNotFoundError: No module named 'simple_knn._C'). So I simply added the following definition in gaussian_model.py (I found it on the website of simple_knn):

def distCUDA2(points): points_np = points.detach().cpu().float().numpy() dists, inds = KDTree(points_np).query(points_np, k=4) meanDists = (dists[:, 1:] ** 2).mean(1) return torch.tensor(meanDists, dtype=points.dtype, device=points.device)

The above two issues can be solved by those methods. But the last error has not been solved yet. I encounter "ImportError: cannot import name 'GaussianRasterizationSettings' from 'diff_gaussian_rasterization' (unknown location)". I can't find GaussianRasterizationSettings in diff_gaussian_rasterization directory (I downloaded from github). What should I do?"

a1600012888 commented 2 weeks ago

Both simple_knn and diff_gaussian_rasterization are installed from github clones:

For the diff_gaussian_rasterization you can directly install with pip install git+https://github.com/graphdeco-inria/diff-gaussian-rasterization.git For the simple_knn, you can do this: https://github.com/camenduru/simple-knn