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

[Installation]: build docker images: Failed to build mamba-ssm #7498

Closed
chenchunhui97 opened this issue Aug 14, 2024 · 1 comment
Closed
Labels
installation Installation problems

Comments

@chenchunhui97
Copy link

chenchunhui97 commented Aug 14, 2024

Your current environment

=> ERROR [mamba-builder 3/3] RUN pip --verbose wheel -r requirements-mamba.txt     --no-build-isolation --no-deps --no-cache-dir
909.8s
------
 > [mamba-builder 3/3] RUN pip --verbose wheel -r requirements-mamba.txt     --no-build-isolation --no-deps --no-cache-dir:
1.518 Collecting mamba-ssm>=1.2.2 (from -r requirements-mamba.txt (line 2))
1.776   Downloading mamba_ssm-2.2.2.tar.gz (85 kB)
1.904   Preparing metadata (setup.py): started
1.904   Running command python setup.py egg_info
4.070   No CUDA runtime is found, using CUDA_HOME='/usr/local/cuda'
4.146
4.146
4.147   torch.__version__  = 2.4.0+cu121
4.147
4.148
4.149   running egg_info
4.149   creating /tmp/pip-pip-egg-info-d2_c2trw/mamba_ssm.egg-info
4.154   writing /tmp/pip-pip-egg-info-d2_c2trw/mamba_ssm.egg-info/PKG-INFO
4.154   writing dependency_links to /tmp/pip-pip-egg-info-d2_c2trw/mamba_ssm.egg-info/dependency_links.txt
4.155   writing requirements to /tmp/pip-pip-egg-info-d2_c2trw/mamba_ssm.egg-info/requires.txt
4.156   writing top-level names to /tmp/pip-pip-egg-info-d2_c2trw/mamba_ssm.egg-info/top_level.txt
4.156   writing manifest file '/tmp/pip-pip-egg-info-d2_c2trw/mamba_ssm.egg-info/SOURCES.txt'
4.250   reading manifest file '/tmp/pip-pip-egg-info-d2_c2trw/mamba_ssm.egg-info/SOURCES.txt'
4.250   adding license file 'LICENSE'
4.251   adding license file 'AUTHORS'
4.252   writing manifest file '/tmp/pip-pip-egg-info-d2_c2trw/mamba_ssm.egg-info/SOURCES.txt'
4.670   Preparing metadata (setup.py): finished with status 'done'
4.964 Collecting causal-conv1d>=1.2.0 (from -r requirements-mamba.txt (line 3))
5.029   Downloading causal_conv1d-1.4.0.tar.gz (9.3 kB)
5.048   Preparing metadata (setup.py): started
5.049   Running command python setup.py egg_info
7.259   No CUDA runtime is found, using CUDA_HOME='/usr/local/cuda'
7.351
7.352
7.352   torch.__version__  = 2.4.0+cu121
7.353
7.353
7.354   running egg_info
7.355   creating /tmp/pip-pip-egg-info-uye1h_am/causal_conv1d.egg-info
7.363   writing /tmp/pip-pip-egg-info-uye1h_am/causal_conv1d.egg-info/PKG-INFO
7.364   writing dependency_links to /tmp/pip-pip-egg-info-uye1h_am/causal_conv1d.egg-info/dependency_links.txt
7.364   writing requirements to /tmp/pip-pip-egg-info-uye1h_am/causal_conv1d.egg-info/requires.txt
7.365   writing top-level names to /tmp/pip-pip-egg-info-uye1h_am/causal_conv1d.egg-info/top_level.txt
7.366   writing manifest file '/tmp/pip-pip-egg-info-uye1h_am/causal_conv1d.egg-info/SOURCES.txt'
7.458   reading manifest file '/tmp/pip-pip-egg-info-uye1h_am/causal_conv1d.egg-info/SOURCES.txt'
7.459   adding license file 'LICENSE'
7.460   adding license file 'AUTHORS'
7.460   writing manifest file '/tmp/pip-pip-egg-info-uye1h_am/causal_conv1d.egg-info/SOURCES.txt'
7.917   Preparing metadata (setup.py): finished with status 'done'
7.928 Building wheels for collected packages: mamba-ssm, causal-conv1d
7.929   Building wheel for mamba-ssm (setup.py): started
7.930   Running command python setup.py bdist_wheel
10.18   No CUDA runtime is found, using CUDA_HOME='/usr/local/cuda'
10.18
10.18
10.18   torch.__version__  = 2.4.0+cu121
10.18
10.18
10.23   running bdist_wheel
10.26   Guessing wheel URL:  https://github.com/state-spaces/mamba/releases/download/v2.2.2/mamba_ssm-2.2.2+cu122torch2.4cxx11abiFALSE-cp310-cp310-linux_x86_64.whl
623.7   error: <urlopen error retrieval incomplete: got only 178257920 out of 323988104 bytes>
624.1   error: subprocess-exited-with-error
624.1
624.1   × python setup.py bdist_wheel did not run successfully.
624.1   │ exit code: 1
624.1   ╰─> See above for output.
624.1
624.1   note: This error originates from a subprocess, and is likely not a problem with pip.

624.1   # - It imports setuptools before invoking setup.py, to enable projects that directly
624.1   #   import from `distutils.core` to work with newer packaging standards.
624.1   # - It provides a clear error message when setuptools is not installed.
624.1   # - It sets `sys.argv[0]` to the underlying `setup.py`, when invoking `setup.py` so
624.1   #   setuptools doesn'"'"'t think the script is `-c`. This avoids the following warning:
624.1   #     manifest_maker: standard file '"'"'-c'"'"' not found".
624.1   # - It generates a shim setup.py, for handling setup.cfg-only projects.
624.1   import os, sys, tokenize
624.1
624.1   try:
624.1       import setuptools
624.1   except ImportError as error:
624.1       print(
624.1           "ERROR: Can not execute `setup.py` since setuptools is not available in "
624.1           "the build environment.",
624.1           file=sys.stderr,
624.1       )
624.1       sys.exit(1)
624.1
624.1   __file__ = %r
624.1   sys.argv[0] = __file__
624.1
624.1   if os.path.exists(__file__):
624.1       filename = __file__
624.1       with tokenize.open(__file__) as f:
624.1           setup_py_code = f.read()
624.1   else:
624.1       filename = "<auto-generated setuptools caller>"
624.1       setup_py_code = "from setuptools import setup; setup()"
624.1
624.1   exec(compile(setup_py_code, filename, "exec"))
624.1   '"'"''"'"''"'"' % ('"'"'/tmp/pip-wheel-uaoqe42l/mamba-ssm_d3adad62e7824b8383a22aabf455e8de/setup.py'"'"',), "<pip-setuptools-caller>", "exec"))' bdist_wheel -d /tmp/pip-wheel-0tek0r5o
624.1   cwd: /tmp/pip-wheel-uaoqe42l/mamba-ssm_d3adad62e7824b8383a22aabf455e8de/
624.1   Building wheel for mamba-ssm (setup.py): finished with status 'error'
624.1   ERROR: Failed building wheel for mamba-ssm
624.1   Running setup.py clean for mamba-ssm
624.1   Running command python setup.py clean
626.1   No CUDA runtime is found, using CUDA_HOME='/usr/local/cuda'
626.2
626.2
626.2   torch.__version__  = 2.4.0+cu121
626.2
626.2
626.2   running clean
626.2   'build/lib.linux-x86_64-cpython-310' does not exist -- can't clean it
626.2   'build/bdist.linux-x86_64' does not exist -- can't clean it
626.2   'build/scripts-3.10' does not exist -- can't clean it
626.6   Building wheel for causal-conv1d (setup.py): started
626.6   Running command python setup.py bdist_wheel
628.6   No CUDA runtime is found, using CUDA_HOME='/usr/local/cuda'
628.6
628.6
628.6   torch.__version__  = 2.4.0+cu121
628.6
628.6
628.7   running bdist_wheel
628.7   Guessing wheel URL:  https://github.com/Dao-AILab/causal-conv1d/releases/download/v1.4.0/causal_conv1d-1.4.0+cu122torch2.4cxx11abiFALSE-cp310-cp310-linux_x86_64.whl
908.5   Raw wheel path /tmp/pip-wheel-mfpcfgry/causal_conv1d-1.4.0-cp310-cp310-linux_x86_64.whl
908.8   Building wheel for causal-conv1d (setup.py): finished with status 'done'
909.0   Created wheel for causal-conv1d: filename=causal_conv1d-1.4.0-cp310-cp310-linux_x86_64.whl size=104867883 sha256=b5e7cf7e964b5e99275d97ba1e1b0ee4e3073f4593743ba1f1c6aa394a3008cc
909.0   Stored in directory: /tmp/pip-ephem-wheel-cache-62nr0jbv/wheels/e3/dd/4c/205f24e151736bd22f5980738dd10a19af6f093b6f4dcab006
909.0 Successfully built causal-conv1d
909.0 Failed to build mamba-ssm
909.6 ERROR: Failed to build one or more wheels
------
Dockerfile.longshine:152
--------------------
 151 |     # Download the wheel or build it if a pre-compiled release doesn't exist
 152 | >>> RUN pip --verbose wheel -r requirements-mamba.txt \
 153 | >>>     --no-build-isolation --no-deps --no-cache-dir
 154 |
--------------------
ERROR: failed to solve: process "/bin/sh -c pip --verbose wheel -r requirements-mamba.txt     --no-build-isolation --no-deps --no-cache-dir" did not complete successfully: exit code: 1

How you are installing vllm

vllm version: v0.5.2, v0.5.3, v0.5.4 (versions that have mamba)
cuda tool kit: cuda 12.1
cuda driver: 535.183.01
device: RTX 4090
CPU: intel
docker build -t xxxx -f Dockerfile .

@chenchunhui97 chenchunhui97 added the installation Installation problems label Aug 14, 2024
@chenchunhui97 chenchunhui97 changed the title [Installation]: build docker images occurs error [Installation]: build docker images: Failed to build mamba-ssm Aug 14, 2024
@tlrmchlsmth
Copy link
Collaborator

I think this should be resolved as of #7651. That PR moved the Mamba kernels into vLLM's build system, no longer grabs the causal_conv1d or mamba_ssm packages, and removed requirements-mamba.txt.

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

No branches or pull requests

2 participants