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

Why this project alway force me to install CUDA12.1 ??? #5462

Open
piwawa opened this issue Mar 18, 2024 · 0 comments
Open

Why this project alway force me to install CUDA12.1 ??? #5462

piwawa opened this issue Mar 18, 2024 · 0 comments

Comments

@piwawa
Copy link

piwawa commented Mar 18, 2024

(hw5) (base) [bingo06@zernithos fairseq]$ pip install --editable ./
Obtaining file:///home/bingo06/AIGC/leedl-tutorial/Homework/HW5_seq2seq/fairseq
  Installing build dependencies ... done
  Checking if build backend supports build_editable ... done
  Getting requirements to build editable ... done
  Preparing editable metadata (pyproject.toml) ... done
Collecting cffi (from fairseq==0.12.2)
  Using cached cffi-1.16.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (1.5 kB)
Collecting cython (from fairseq==0.12.2)
  Using cached Cython-3.0.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (3.2 kB)
Collecting hydra-core<1.1,>=1.0.7 (from fairseq==0.12.2)
  Using cached hydra_core-1.0.7-py3-none-any.whl.metadata (3.7 kB)
Collecting omegaconf<2.1 (from fairseq==0.12.2)
  Using cached omegaconf-2.0.6-py3-none-any.whl.metadata (3.0 kB)
Requirement already satisfied: numpy>=1.21.3 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from fairseq==0.12.2) (1.26.4)
Requirement already satisfied: regex in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from fairseq==0.12.2) (2023.12.25)
Requirement already satisfied: sacrebleu>=1.4.12 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from fairseq==0.12.2) (2.4.1)
Requirement already satisfied: torch>=1.13 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from fairseq==0.12.2) (2.1.1+cu118)
Requirement already satisfied: tqdm in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from fairseq==0.12.2) (4.66.2)
Collecting bitarray (from fairseq==0.12.2)
  Using cached bitarray-2.9.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (34 kB)
Requirement already satisfied: torchaudio>=0.8.0 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from fairseq==0.12.2) (2.1.1+cu118)
Collecting scikit-learn (from fairseq==0.12.2)
  Using cached scikit_learn-1.4.1.post1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (11 kB)
Requirement already satisfied: packaging in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from fairseq==0.12.2) (23.2)
Collecting antlr4-python3-runtime==4.8 (from hydra-core<1.1,>=1.0.7->fairseq==0.12.2)
  Using cached antlr4_python3_runtime-4.8-py3-none-any.whl
Requirement already satisfied: PyYAML>=5.1.* in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from omegaconf<2.1->fairseq==0.12.2) (6.0.1)
Requirement already satisfied: typing-extensions in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from omegaconf<2.1->fairseq==0.12.2) (4.10.0)
Requirement already satisfied: portalocker in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from sacrebleu>=1.4.12->fairseq==0.12.2) (2.8.2)
Requirement already satisfied: tabulate>=0.8.9 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from sacrebleu>=1.4.12->fairseq==0.12.2) (0.9.0)
Requirement already satisfied: colorama in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from sacrebleu>=1.4.12->fairseq==0.12.2) (0.4.6)
Requirement already satisfied: lxml in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from sacrebleu>=1.4.12->fairseq==0.12.2) (5.1.0)
Requirement already satisfied: filelock in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from torch>=1.13->fairseq==0.12.2) (3.9.0)
Requirement already satisfied: sympy in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from torch>=1.13->fairseq==0.12.2) (1.12)
Requirement already satisfied: networkx in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from torch>=1.13->fairseq==0.12.2) (3.2.1)
Requirement already satisfied: jinja2 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from torch>=1.13->fairseq==0.12.2) (3.1.2)
Requirement already satisfied: fsspec in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from torch>=1.13->fairseq==0.12.2) (2023.4.0)
Requirement already satisfied: triton==2.1.0 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from torch>=1.13->fairseq==0.12.2) (2.1.0)
Collecting pycparser (from cffi->fairseq==0.12.2)
  Using cached pycparser-2.21-py2.py3-none-any.whl.metadata (1.1 kB)
Collecting scipy>=1.6.0 (from scikit-learn->fairseq==0.12.2)
  Using cached scipy-1.12.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (60 kB)
Requirement already satisfied: joblib>=1.2.0 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from scikit-learn->fairseq==0.12.2) (1.3.2)
Collecting threadpoolctl>=2.0.0 (from scikit-learn->fairseq==0.12.2)
  Using cached threadpoolctl-3.3.0-py3-none-any.whl.metadata (13 kB)
Requirement already satisfied: MarkupSafe>=2.0 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from jinja2->torch>=1.13->fairseq==0.12.2) (2.1.3)
Requirement already satisfied: mpmath>=0.19 in /home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages (from sympy->torch>=1.13->fairseq==0.12.2) (1.3.0)
Using cached hydra_core-1.0.7-py3-none-any.whl (123 kB)
Using cached omegaconf-2.0.6-py3-none-any.whl (36 kB)
Using cached bitarray-2.9.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (288 kB)
Using cached cffi-1.16.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (443 kB)
Using cached Cython-3.0.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.6 MB)
Using cached scikit_learn-1.4.1.post1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (12.1 MB)
Using cached scipy-1.12.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (38.4 MB)
Using cached threadpoolctl-3.3.0-py3-none-any.whl (17 kB)
Using cached pycparser-2.21-py2.py3-none-any.whl (118 kB)
Building wheels for collected packages: fairseq
  Building editable for fairseq (pyproject.toml) ... error
  error: subprocess-exited-with-error
  
  × Building editable for fairseq (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [125 lines of output]
      running editable_wheel
      creating /tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info
      writing /tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info/PKG-INFO
      writing dependency_links to /tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info/dependency_links.txt
      writing entry points to /tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info/entry_points.txt
      writing requirements to /tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info/requires.txt
      writing top-level names to /tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info/top_level.txt
      writing manifest file '/tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info/SOURCES.txt'
      reading manifest file '/tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info/SOURCES.txt'
      reading manifest template 'MANIFEST.in'
      adding license file 'LICENSE'
      writing manifest file '/tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq.egg-info/SOURCES.txt'
      creating '/tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq-0.12.2.dist-info'
      creating /tmp/pip-wheel-fn9pqkp1/.tmp-g1tiensn/fairseq-0.12.2.dist-info/WHEEL
      running build_py
      running build_ext
      Traceback (most recent call last):
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/editable_wheel.py", line 155, in run
          self._create_wheel_file(bdist_wheel)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/editable_wheel.py", line 357, in _create_wheel_file
          files, mapping = self._run_build_commands(dist_name, unpacked, lib, tmp)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/editable_wheel.py", line 280, in _run_build_commands
          self._run_build_subcommands()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/editable_wheel.py", line 307, in _run_build_subcommands
          self.run_command(name)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
          self.distribution.run_command(command)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 967, in run_command
          super().run_command(command)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
          cmd_obj.run()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/build_ext.py", line 91, in run
          _build_ext.run(self)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 345, in run
          self.build_extensions()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/torch/utils/cpp_extension.py", line 523, in build_extensions
          _check_cuda_version(compiler_name, compiler_version)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/torch/utils/cpp_extension.py", line 414, in _check_cuda_version
          raise RuntimeError(CUDA_MISMATCH_MESSAGE.format(cuda_str_version, torch.version.cuda))
      RuntimeError:
      The detected CUDA version (11.8) mismatches the version that was used to compile
      PyTorch (12.1). Please make sure to use the same CUDA versions.
      
      /tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py:988: _DebuggingTips: Problem in editable installation.
      !!
      
              ********************************************************************************
              An error happened while installing `fairseq` in editable mode.
      
              The following steps are recommended to help debug this problem:
      
              - Try to install the project normally, without using the editable mode.
                Does the error still persist?
                (If it does, try fixing the problem before attempting the editable mode).
              - If you are using binary extensions, make sure you have all OS-level
                dependencies installed (e.g. compilers, toolchains, binary libraries, ...).
              - Try the latest version of setuptools (maybe the error was already fixed).
              - If you (or your project dependencies) are using any setuptools extension
                or customization, make sure they support the editable mode.
      
              After following the steps above, if the problem still persists and
              you think this is related to how setuptools handles editable installations,
              please submit a reproducible example
              (see https://stackoverflow.com/help/minimal-reproducible-example) to:
      
                  https://github.com/pypa/setuptools/issues
      
              See https://setuptools.pypa.io/en/latest/userguide/development_mode.html for details.
              ********************************************************************************
      
      !!
        cmd_obj.run()
      Traceback (most recent call last):
        File "/home/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/home/bingo06/miniconda3/envs/hw5/lib/python3.10/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/bingo06/miniconda3/envs/hw5/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 273, in build_editable
          return hook(wheel_directory, config_settings, metadata_directory)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 443, in build_editable
          return self._build_with_temp_dir(
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 395, in _build_with_temp_dir
          self.run_setup()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 311, in run_setup
          exec(code, locals())
        File "<string>", line 254, in <module>
        File "<string>", line 164, in do_setup
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/__init__.py", line 104, in setup
          return distutils.core.setup(**attrs)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 185, in setup
          return run_commands(dist)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
          dist.run_commands()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
          self.run_command(cmd)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 967, in run_command
          super().run_command(command)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
          cmd_obj.run()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/editable_wheel.py", line 155, in run
          self._create_wheel_file(bdist_wheel)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/editable_wheel.py", line 357, in _create_wheel_file
          files, mapping = self._run_build_commands(dist_name, unpacked, lib, tmp)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/editable_wheel.py", line 280, in _run_build_commands
          self._run_build_subcommands()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/editable_wheel.py", line 307, in _run_build_subcommands
          self.run_command(name)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
          self.distribution.run_command(command)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/dist.py", line 967, in run_command
          super().run_command(command)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
          cmd_obj.run()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/command/build_ext.py", line 91, in run
          _build_ext.run(self)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/setuptools/_distutils/command/build_ext.py", line 345, in run
          self.build_extensions()
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/torch/utils/cpp_extension.py", line 523, in build_extensions
          _check_cuda_version(compiler_name, compiler_version)
        File "/tmp/pip-build-env-slyi_1x5/overlay/lib/python3.10/site-packages/torch/utils/cpp_extension.py", line 414, in _check_cuda_version
          raise RuntimeError(CUDA_MISMATCH_MESSAGE.format(cuda_str_version, torch.version.cuda))
      RuntimeError:
      The detected CUDA version (11.8) mismatches the version that was used to compile
      PyTorch (12.1). Please make sure to use the same CUDA versions.
      
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building editable for fairseq
Failed to build fairseq
ERROR: Could not build wheels for fairseq, which is required to install pyproject.toml-based projects
(hw5) (base) [bingo06@zernithos fairseq]$ nvcc -V
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2022 NVIDIA Corporation
Built on Wed_Sep_21_10:33:58_PDT_2022
Cuda compilation tools, release 11.8, V11.8.89
Build cuda_11.8.r11.8/compiler.31833905_0
(hw5) (base) [bingo06@zernithos fairseq]$ pip list
Package            Version
------------------ ------------
appdirs            1.4.4
asttokens          2.4.1
certifi            2024.2.2
charset-normalizer 3.3.2
click              8.1.7
colorama           0.4.6
comm               0.2.2
contourpy          1.2.0
cycler             0.12.1
debugpy            1.8.1
decorator          5.1.1
docker-pycreds     0.4.0
editdistance       0.8.1
exceptiongroup     1.2.0
executing          2.0.1
fairseq2           0.2.0
fairseq2n          0.2.0
filelock           3.9.0
fonttools          4.50.0
fsspec             2023.4.0
gitdb              4.0.11
GitPython          3.1.42
idna               3.6
importlib_metadata 7.0.2
ipykernel          6.29.3
ipython            8.22.2
jedi               0.19.1
Jinja2             3.1.2
jiwer              3.0.3
joblib             1.3.2
jupyter_client     8.6.1
jupyter_core       5.7.2
kiwisolver         1.4.5
lxml               5.1.0
MarkupSafe         2.1.3
matplotlib         3.8.3
matplotlib-inline  0.1.6
mpmath             1.3.0
nest_asyncio       1.6.0
networkx           3.2.1
numpy              1.26.4
overrides          7.7.0
packaging          23.2
parso              0.8.3
pexpect            4.9.0
pickleshare        0.7.5
pillow             10.2.0
pip                24.0
platformdirs       4.2.0
portalocker        2.8.2
prompt-toolkit     3.0.42
protobuf           4.25.3
psutil             5.9.8
ptyprocess         0.7.0
pure-eval          0.2.2
Pygments           2.17.2
pyparsing          3.1.2
python-dateutil    2.9.0
PyYAML             6.0.1
pyzmq              25.1.2
rapidfuzz          3.6.2
regex              2023.12.25
requests           2.31.0
sacrebleu          2.4.1
sacremoses         0.1.1
sentencepiece      0.2.0
sentry-sdk         1.42.0
setproctitle       1.3.3
setuptools         69.2.0
six                1.16.0
smmap              5.0.1
stack-data         0.6.2
sympy              1.12
tabulate           0.9.0
tbb                2021.11.0
torch              2.1.1+cu118
torchaudio         2.1.1+cu118
torcheval          0.0.7
torchvision        0.16.1+cu118
tornado            6.4
tqdm               4.66.2
traitlets          5.14.2
triton             2.1.0
typing_extensions  4.10.0
urllib3            2.2.1
wandb              0.16.4
wcwidth            0.2.13
wheel              0.42.0
zipp               3.17.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant