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

RuntimeError: Error compiling objects for extension #12

Open
973398769 opened this issue Nov 11, 2024 · 7 comments
Open

RuntimeError: Error compiling objects for extension #12

973398769 opened this issue Nov 11, 2024 · 7 comments

Comments

@973398769
Copy link

File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 183, in setup
    return run_commands(dist)
           ^^^^^^^^^^^^^^^^^^
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 199, in run_commands
    dist.run_commands()
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 954, in run_commands
    self.run_command(cmd)
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/dist.py", line 950, in run_command
    super().run_command(command)
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 973, in run_command
    cmd_obj.run()
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/command/develop.py", line 35, in run
    self.install_for_development()
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/command/develop.py", line 112, in install_for_development
    self.run_command('build_ext')
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/cmd.py", line 316, in run_command
    self.distribution.run_command(command)
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/dist.py", line 950, in run_command
    super().run_command(command)
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 973, in run_command
    cmd_obj.run()
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/command/build_ext.py", line 98, in run
    _build_ext.run(self)
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/command/build_ext.py", line 359, in run
    self.build_extensions()
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/torch/utils/cpp_extension.py", line 866, in build_extensions
    build_ext.build_extensions(self)
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/command/build_ext.py", line 476, in build_extensions
    self._build_extensions_serial()
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/command/build_ext.py", line 502, in _build_extensions_serial
    self.build_extension(ext)
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/command/build_ext.py", line 263, in build_extension
    _build_ext.build_extension(self, ext)
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/setuptools/_distutils/command/build_ext.py", line 557, in build_extension
    objects = self.compiler.compile(
              ^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/torch/utils/cpp_extension.py", line 679, in unix_wrap_ninja_compile
    _write_ninja_file_and_compile_objects(
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/torch/utils/cpp_extension.py", line 1785, in _write_ninja_file_and_compile_objects
    _run_ninja_build(
  File "/home/ubuntu/miniconda3/envs/nunchaku/lib/python3.11/site-packages/torch/utils/cpp_extension.py", line 2121, in _run_ninja_build
    raise RuntimeError(message) from e
RuntimeError: Error compiling objects for extension
[end of output]
@973398769 973398769 changed the title pip install -e . RuntimeError: Error compiling objects for extension Nov 11, 2024
@ziyaxuanyi
Copy link

I meet the same problem. Did you solve this?

@973398769
Copy link
Author

I solve this problem with trying another gpus. The code has some gpu architecture limitations

@kelisiya
Copy link

我遇到了同样的问题。您解决了这个问题吗?

+1

@lmxyy
Copy link
Collaborator

lmxyy commented Nov 12, 2024

Which GPU are you using?

@973398769
Copy link
Author

973398769 commented Nov 12, 2024

This is work well for me | NVIDIA-SMI 535.183.01 Driver Version: 535.183.01 CUDA Version: 12.2 |
|-----------------------------------------+----------------------+----------------------+
| GPU Name Persistence-M | Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|=========================================+======================+======================|
| 0 Tesla V100-PCIE-16GB Off | 00000001:00:00.0 Off | Off |

@ziyaxuanyi
Copy link

我遇到了同样的问题。您解决了这个问题吗?

+1

I have resolved the issue. You need to update the third-party library code, as they all have their own specific version requirements. You need to ensure that they are all the required versions
impicture_20241112_140501

@lmxyy
Copy link
Collaborator

lmxyy commented Nov 14, 2024

This is work well for me | NVIDIA-SMI 535.183.01 Driver Version: 535.183.01 CUDA Version: 12.2 | |-----------------------------------------+----------------------+----------------------+ | GPU Name Persistence-M | Bus-Id Disp.A | Volatile Uncorr. ECC | | Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. | | | | MIG M. | |=========================================+======================+======================| | 0 Tesla V100-PCIE-16GB Off | 00000001:00:00.0 Off | Off |

This is because V100 does not have INT4 CUDA core.
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants