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

issue with nvidia apex #1

Open
Roy101 opened this issue Sep 17, 2024 · 0 comments
Open

issue with nvidia apex #1

Roy101 opened this issue Sep 17, 2024 · 0 comments

Comments

@Roy101
Copy link

Roy101 commented Sep 17, 2024

trying to pip install from apex directory, I am getting following errors.

commands:

git clone https://github.com/NVIDIA/apex
cd apex
pip install -v --disable-pip-version-check --no-cache-dir --global-option="--cpp_ext" --global-option="--cuda_ext" .

error message:

Traceback (most recent call last):
    File "/home/usr/anaconda3/envs/newvenvconda/lib/python3.8/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
      main()
    File "/home/usr/anaconda3/envs/newvenvconda/lib/python3.8/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
      json_out['return_val'] = hook(**hook_input['kwargs'])
    File "/home/usr/anaconda3/envs/newvenvconda/lib/python3.8/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
      return hook(config_settings)
    File "/tmp/pip-build-env-0aayo32i/overlay/lib/python3.8/site-packages/setuptools/build_meta.py", line 332, in get_requires_for_build_wheel
      return self._get_build_requires(config_settings, requirements=[])
    File "/tmp/pip-build-env-0aayo32i/overlay/lib/python3.8/site-packages/setuptools/build_meta.py", line 302, in _get_build_requires
      self.run_setup()
    File "/tmp/pip-build-env-0aayo32i/overlay/lib/python3.8/site-packages/setuptools/build_meta.py", line 318, in run_setup
      exec(code, locals())
    File "<string>", line 10, in <module>
  ModuleNotFoundError: No module named 'torch'
  error: subprocess-exited-with-error
  
  × Getting requirements to build 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.
  full command: /home/usr/anaconda3/envs/newvenvconda/bin/python /home/usr/anaconda3/envs/newvenvconda/lib/python3.8/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py get_requires_for_build_wheel /tmp/tmpaocptoj0
  cwd: /home/usr/Desktop/new/transclone/apex
  Getting requirements to build wheel ... error
error: subprocess-exited-with-error

× Getting requirements to build 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.

how to fix it?

Installed versions:

Python 3.8.19 (default, Mar 20 2024, 19:58:24)

import torch

print("PyTorch version:", torch.__version__)

if torch.cuda.is_available():
    print("CUDA is available. CUDA version:", torch.version.cuda)
else:
    print("CUDA is not available.")


Output:

PyTorch version: 1.13.0+cu116

CUDA is available. CUDA version: 11.6
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

1 participant