Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

could not install diff-surfels-rasterization #10

Open
AnudhinaDhanabalan opened this issue May 7, 2024 · 17 comments
Open

could not install diff-surfels-rasterization #10

AnudhinaDhanabalan opened this issue May 7, 2024 · 17 comments
Labels
help wanted Extra attention is needed

Comments

@AnudhinaDhanabalan
Copy link

i could not install the diff-surfrel-rasterization submodule,is there any troubleshooting tha tcan work ? thanks !!

@hbb1
Copy link
Owner

hbb1 commented May 7, 2024

Hi. What was the error message there? It will be helpful in locating the errors given a detailed description.

@AnudhinaDhanabalan
Copy link
Author

this was the error

Traceback (most recent call last):
File "train.py", line 16, in
from gaussian_renderer import render, network_gui
File "C:\Users\ghost\2d-gaussian-splatting\gaussian_renderer_init_.py", line 14, in
from diff_surfel_rasterization import GaussianRasterizationSettings, GaussianRasterizer
ModuleNotFoundError: No module named 'diff_surfel_rasterization'
(gs2) PS C:\Users\ghost\2d-gaussian-splatting> pip install .\submodules\diff-surfel-rasterization
Processing c:\users\ghost\2d-gaussian-splatting\submodules\diff-surfel-rasterization
Preparing metadata (setup.py) ... done
Building wheels for collected packages: diff-surfel-rasterization
Building wheel for diff-surfel-rasterization (setup.py) ... error
error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> [5 lines of output]
running bdist_wheel
running build
running build_py
running build_ext
error: [WinError 2] The system cannot find the file specified
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for diff-surfel-rasterization
Running setup.py clean for diff-surfel-rasterization
Failed to build diff-surfel-rasterization
Installing collected packages: diff-surfel-rasterization
Running setup.py install for diff-surfel-rasterization ... error
error: subprocess-exited-with-error

× Running setup.py install for diff-surfel-rasterization did not run successfully.
│ exit code: 1
╰─> [22 lines of output]
running install
C:\Users\ghost\anaconda3\envs\gs2\lib\site-packages\setuptools_distutils\cmd.py:66: SetuptoolsDeprecationWarning: setup.py install is deprecated.
!!

          ********************************************************************************
          Please avoid running ``setup.py`` directly.
          Instead, use pypa/build, pypa/installer or other
          standards-based tools.

          See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details.
          ********************************************************************************

  !!
    self.initialize_options()
  running build
  running build_py
  creating build
  creating build\lib.win-amd64-cpython-37
  creating build\lib.win-amd64-cpython-37\diff_surfel_rasterization
  copying diff_surfel_rasterization\__init__.py -> build\lib.win-amd64-cpython-37\diff_surfel_rasterization
  running build_ext
  error: [WinError 2] The system cannot find the file specified
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure

× Encountered error while trying to install package.
╰─> diff-surfel-rasterization

note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.

@henrypearce4D
Copy link

I also cant install this submodule, I'm also using windows.
Has the installation been tested on windows?

@pani-vishal
Copy link

Can I ask what your python and setuptools version are for that environment? This might be helpful: https://stackoverflow.com/questions/73257839/setup-py-install-is-deprecated-warning-shows-up-every-time-i-open-a-terminal-i

@hbb1
Copy link
Owner

hbb1 commented May 7, 2024

Super thanks to @pani-vishal It worths a try. I haven't tested on Windows because I don't have one at hand. I also search some related solutions from 3DGS's repo for Windows, hoping it will help https://github.com/graphdeco-inria/gaussian-splatting?tab=readme-ov-file#faq

@CDchenlin
Copy link

CDchenlin commented May 8, 2024

Hi!
I have tried to install the diff_surfel_rasterization submodule on Linux, and I also have some errors as follows

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for diff_surfel_rasterization
Running setup.py clean for diff_surfel_rasterization
Failed to build diff_surfel_rasterization
ERROR: Could not build wheels for diff_surfel_rasterization, which is required to install pyproject.toml-based projects

@hbb1
Copy link
Owner

hbb1 commented May 8, 2024

You can try to upgrade your pip and run pip install pyproject-toml

@CDchenlin
Copy link

Thank you for your reply, however it seems not solving the problem. I wonder if I can directly use the conda environment of 3DGS? I am not sure if there are any modifications of the submodule, as my purpose is to extract the mesh.

@xuncpp
Copy link

xuncpp commented May 8, 2024

Thanks for your great work!
But I encountered the same problem,I follow your advice:1.!pip install --upgrade pip and Successfully installed pip-24.0; 2.!pip install pyproject-toml and Successfully installed pyproject-toml-0.0.10.In addition setuptools rsion is 67.7.2. But unfortunately it still didn’t work.

Processing ./submodules/diff-surfel-rasterization
Preparing metadata (setup.py) ... done
Building wheels for collected packages: diff-surfel-rasterization
error: subprocess-exited-with-error

× python setup.py bdist_wheel did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
Building wheel for diff-surfel-rasterization (setup.py) ... error
ERROR: Failed building wheel for diff-surfel-rasterization
Running setup.py clean for diff-surfel-rasterization
Failed to build diff-surfel-rasterization
ERROR: Could not build wheels for diff-surfel-rasterization, which is required to install pyproject.toml-based projects

Thanks again to the author, hope someone can tell me how to solve this problem!

@CDchenlin
Copy link

CDchenlin commented May 8, 2024

Hi @xuncpp

I have solved this problem by refering to this issue . Hope it can help you.

@RobinRenggli
Copy link

Might be related:

I also had trouble installing the submodule, in my case the reason was the file 2d-gaussian-splatting\submodules\diff-surfel-rasterization\rasterize_points.cu

The way the CHECK_INPUT is defined on line 28 lead to compilation errors. This can be fixed by either adjusting your compilation settings, or by just removing all the lines containing CHECK_INPUT, since this seems to mostly be a leftover for debugging reasons. After removing those lines, I managed to compile the submodule.

@hbb1 hbb1 added the help wanted Extra attention is needed label May 8, 2024
@LionelWXY
Copy link

I meet the similar issue on windows10, and this may be useful. I slove this problem through 1. removing all the lines containing CHECK_INPUT in 2d-gaussian-splatting\submodules\diff-surfel-rasterization\rasterize_points.cu. 2. changing code " 'build_ext': BuildExtension " to " 'build_ext': BuildExtension.with_options(use_ninja=False) " in 2d-gaussian-splatting\submodules\diff-surfel-rasterization\setup.py

@henrypearce4D
Copy link

henrypearce4D commented May 8, 2024

I meet the similar issue on windows10, and this may be useful. I slove this problem through 1. removing all the lines containing CHECK_INPUT in 2d-gaussian-splatting\submodules\diff-surfel-rasterization\rasterize_points.cu. 2. changing code " 'build_ext': BuildExtension " to " 'build_ext': BuildExtension.with_options(use_ninja=False) " in 2d-gaussian-splatting\submodules\diff-surfel-rasterization\setup.py

@LionelWXY solved the issue for me! thankyou!!

Edit:

It installed but looks like it caused issues doing that;

Traceback (most recent call last):
  File "train.py", line 16, in <module>
    from gaussian_renderer import render, network_gui
  File "C:\2d-gaussian-splatting\gaussian_renderer\__init__.py", line 15, in <module>
    from scene.gaussian_model import GaussianModel
  File "C:\2d-gaussian-splatting\scene\__init__.py", line 16, in <module>
    from scene.dataset_readers import sceneLoadTypeCallbacks
  File "C:\2d-gaussian-splatting\scene\dataset_readers.py", line 24, in <module>
    from scene.gaussian_model import BasicPointCloud
  File "C:\2d-gaussian-splatting\scene\gaussian_model.py", line 20, in <module>
    from simple_knn._C import distCUDA2
ImportError: DLL load failed while importing _C: The specified procedure could not be found.

@LionelWXY
Copy link

I meet the similar issue on windows10, and this may be useful. I slove this problem through 1. removing all the lines containing CHECK_INPUT in 2d-gaussian-splatting\submodules\diff-surfel-rasterization\rasterize_points.cu. 2. changing code " 'build_ext': BuildExtension " to " 'build_ext': BuildExtension.with_options(use_ninja=False) " in 2d-gaussian-splatting\submodules\diff-surfel-rasterization\setup.py

@LionelWXY solved the issue for me! thankyou!!

Edit:

It installed but looks like it caused issues doing that;

Traceback (most recent call last):
  File "train.py", line 16, in <module>
    from gaussian_renderer import render, network_gui
  File "C:\2d-gaussian-splatting\gaussian_renderer\__init__.py", line 15, in <module>
    from scene.gaussian_model import GaussianModel
  File "C:\2d-gaussian-splatting\scene\__init__.py", line 16, in <module>
    from scene.dataset_readers import sceneLoadTypeCallbacks
  File "C:\2d-gaussian-splatting\scene\dataset_readers.py", line 24, in <module>
    from scene.gaussian_model import BasicPointCloud
  File "C:\2d-gaussian-splatting\scene\gaussian_model.py", line 20, in <module>
    from simple_knn._C import distCUDA2
ImportError: DLL load failed while importing _C: The specified procedure could not be found.

Hi there, I think your new issue may have nothing to do with the installation process of submodules\diff-surfel-rasterization. You may check other parts of your installation process related to CUDA. @henrypearce4D

@xuncpp
Copy link

xuncpp commented May 10, 2024

Hi @xuncpp

I have solved this problem by refering to this issue . Hope it can help you.

Thank you for your help! But it may not be the reason for cuda version for me. I configured it according to LionelWXY's answer.

@xuncpp
Copy link

xuncpp commented May 10, 2024

I meet the similar issue on windows10, and this may be useful. I slove this problem through 1. removing all the lines containing CHECK_INPUT in 2d-gaussian-splatting\submodules\diff-surfel-rasterization\rasterize_points.cu. 2. changing code " 'build_ext': BuildExtension " to " 'build_ext': BuildExtension.with_options(use_ninja=False) " in 2d-gaussian-splatting\submodules\diff-surfel-rasterization\setup.py

Thank you very much for your answer! ! I successfully followed this method locally! But this method does not work on colab. I don’t quite understand the principle. I would be grateful if you could answer me.

@linharrrrrt
Copy link

linharrrrrt commented Jun 4, 2024

I successfully completed the installation using the following steps, and I hope it can help everyone:

1. I used the environment from 3DGS https://github.com/graphdeco-inria/gaussian-splatting for the installation, using the commands below:

git clone https://github.com/graphdeco-inria/gaussian-splatting --recursive #This command is necessary to download the complete code, including all the files needed under submodules
SET DISTUTILS_USE_SDK=1 # Windows only
conda env create --file environment.yml
conda activate gaussian_splatting

Then, I successfully installed the gaussian_splatting environment and entered it.

2. I downloaded the code for this project, using the commands below, noting that I was already in the gaussian_splatting environment:

git clone https://github.com/hbb1/2d-gaussian-splatting.git --recursive #This command is necessary to download the complete code, including all the files needed under submodules
pip install submodules/diff-surfel-rasterization

Then, I successfully installed the diff-surfel-rasterization for this project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

9 participants