state-spaces / mamba

Mamba SSM architecture
Apache License 2.0
12.45k stars 1.05k forks source link

mamba_ssm Install Failure #481

Open AchillesPlight opened 1 month ago

AchillesPlight commented 1 month ago

When attempting to pip install mamba-ssm

I receive this error:

(mistEnv) C:\Users\gavin\mistRL>pip install mamba_ssm Collecting mamba_ssm Using cached mamba_ssm-2.2.2.tar.gz (85 kB) Installing build dependencies ... done Getting requirements to build wheel ... error error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> [17 lines of output] Traceback (most recent call last): File "C:\Users\gavin\mistRL\mistEnv\lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 353, in main() File "C:\Users\gavin\mistRL\mistEnv\lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 335, in main json_out['return_val'] = hook(**hook_input['kwargs']) File "C:\Users\gavin\mistRL\mistEnv\lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 118, in get_requires_for_build_wheel return hook(config_settings) File "C:\Users\gavin\AppData\Local\Temp\pip-build-env-buvggkdk\overlay\Lib\site-packages\setuptools\build_meta.py", line 327, in get_requires_for_build_wheel return self._get_build_requires(config_settings, requirements=[]) File "C:\Users\gavin\AppData\Local\Temp\pip-build-env-buvggkdk\overlay\Lib\site-packages\setuptools\build_meta.py", line 297, in _get_build_requires self.run_setup() File "C:\Users\gavin\AppData\Local\Temp\pip-build-env-buvggkdk\overlay\Lib\site-packages\setuptools\build_meta.py", line 497, in run_setup super().run_setup(setup_script=setup_script) File "C:\Users\gavin\AppData\Local\Temp\pip-build-env-buvggkdk\overlay\Lib\site-packages\setuptools\build_meta.py", line 313, in run_setup exec(code, locals()) File "", line 19, in ModuleNotFoundError: No module named 'torch' [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. 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.


I have torch downloaded, here is my pip list

Package Version


annotated-types 0.7.0 attrs 23.2.0 certifi 2024.7.4 charset-normalizer 3.3.2 colorama 0.4.6 docstring_parser 0.16 filelock 3.13.1 fire 0.6.0 fsspec 2024.2.0 huggingface-hub 0.24.0 idna 3.7 intel-openmp 2021.4.0 Jinja2 3.1.3 jsonschema 4.21.1 jsonschema-specifications 2023.12.1 MarkupSafe 2.1.5 mistral_common 1.3.2 mistral_inference 1.3.0 mkl 2021.4.0 mpmath 1.3.0 networkx 3.2.1 numpy 1.26.3 packaging 24.1 pillow 10.2.0 pip 24.1.2 pydantic 2.6.1 pydantic_core 2.16.2 PyYAML 6.0.1 referencing 0.35.1 regex 2024.5.15 requests 2.32.3 rpds-py 0.19.0 safetensors 0.4.3 sentencepiece 0.2.0 setuptools 58.1.0 simple_parsing 0.1.5 six 1.16.0 sympy 1.12 tbb 2021.11.0 termcolor 2.4.0 tiktoken 0.7.0 tokenizers 0.19.1 torch 2.3.1+cu121 torchaudio 2.3.1+cu121 torchvision 0.18.1+cu121 tqdm 4.66.4 transformers 4.42.4 typing_extensions 4.12.2 urllib3 2.2.2 xformers 0.0.27

avisinghal6 commented 1 month ago

I am also facing the same error.

AchillesPlight commented 1 month ago

I think we're out of luck, I did some searching and this is something I found similar to our problem...

https://github.com/state-spaces/mamba/issues/392#issuecomment-2222366940

AchillesPlight commented 1 month ago

Nevermind I just ran it on my WSL and I'm still getting cooked.

Error Below:

@DESKTOP-LEHO5NF:~/hello$ pip install mistral_inference mamba_ssm causal-conv1d Collecting mistral_inference Downloading mistral_inference-1.3.0-py3-none-any.whl.metadata (13 kB) Collecting mamba_ssm Downloading mamba_ssm-2.2.2.tar.gz (85 kB) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 85.4/85.4 kB 2.1 MB/s eta 0:00:00 Installing build dependencies ... done Getting requirements to build wheel ... error error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> [17 lines of output] Traceback (most recent call last): File "/home/damonthevamp/hello/mistEnv/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in main() File "/home/damonthevamp/hello/mistEnv/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/damonthevamp/hello/mistEnv/lib/python3.10/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-7mof0jxa/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 327, in get_requires_for_build_wheel return self._get_build_requires(config_settings, requirements=[]) File "/tmp/pip-build-env-7mof0jxa/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 297, in _get_build_requires self.run_setup() File "/tmp/pip-build-env-7mof0jxa/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 497, in run_setup super().run_setup(setup_script=setup_script) File "/tmp/pip-build-env-7mof0jxa/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 313, in run_setup exec(code, locals()) File "", line 19, in ModuleNotFoundError: No module named 'torch' [end of output]

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

× Getting requirements to build wheel did not run successfully. │ exit code: 1 ╰─> See above for output.

WSL pip list:

@DESKTOP-LEHO5NF:~/hello$ pip list Package Version


filelock 3.13.1 fsspec 2024.2.0 Jinja2 3.1.3 MarkupSafe 2.1.5 mpmath 1.3.0 networkx 3.2.1 numpy 1.26.3 nvidia-cublas-cu12 12.1.3.1 nvidia-cuda-cupti-cu12 12.1.105 nvidia-cuda-nvrtc-cu12 12.1.105 nvidia-cuda-runtime-cu12 12.1.105 nvidia-cudnn-cu12 8.9.2.26 nvidia-cufft-cu12 11.0.2.54 nvidia-curand-cu12 10.3.2.106 nvidia-cusolver-cu12 11.4.5.107 nvidia-cusparse-cu12 12.1.0.106 nvidia-nccl-cu12 2.20.5 nvidia-nvjitlink-cu12 12.1.105 nvidia-nvtx-cu12 12.1.105 pillow 10.2.0 pip 24.1.2 setuptools 59.6.0 sympy 1.12 torch 2.3.1+cu121 torchaudio 2.3.1+cu121 torchvision 0.18.1+cu121 triton 2.3.1 typing_extensions 4.9.0

rishabh004-ai commented 1 month ago

I am also getting similar problems in installing mamba. I am installing it on an NVIDIA A100 GPU . pip list : absl-py 2.1.0 aiohttp 3.9.3 aiosignal 1.3.1 antlr4-python3-runtime 4.8 appdirs 1.4.4 asteroid-filterbanks 0.4.0 async-timeout 4.0.3 attrs 23.2.0 audioread 3.0.1 bitarray 2.9.2 certifi 2024.2.2 cffi 1.16.0 charset-normalizer 3.3.2 click 8.1.7 colorama 0.4.6 conformer 0.3.2 contourpy 1.2.1 cycler 0.12.1 cymem 2.0.8 Cython 3.0.8 decorator 5.1.1 docker-pycreds 0.4.0 dotmap 1.3.30 einops 0.7.0 fairseq 1.0.0a0 /scratch/rs_pgi2/fairseq-a54021305d6b3c4c5959ac9395135f63202db8f1 ffmpeg-python 0.2.0 filelock 3.13.1 fonttools 4.52.1 frozenlist 1.4.1 fsspec 2024.2.0 future 1.0.0 gitdb 4.0.11 GitPython 3.1.43 grpcio 1.62.0 hjson 3.1.0 hydra-core 1.0.7 idna 3.6 Jinja2 3.1.3 joblib 1.3.2 kiwisolver 1.4.5 lazy_loader 0.3 librosa 0.9.2 lightning-utilities 0.11.2 llvmlite 0.42.0 lxml 5.1.0 Markdown 3.5.2 MarkupSafe 2.1.5 matplotlib 3.8.3 mpmath 1.3.0 msgpack 1.0.8 multidict 6.0.5 networkx 3.2.1 ninja 1.11.1.1 numba 0.59.0 numpy 1.23.1 nvidia-cublas-cu12 12.1.3.1 nvidia-cuda-cupti-cu12 12.1.105 nvidia-cuda-nvrtc-cu12 12.1.105 nvidia-cuda-runtime-cu12 12.1.105 nvidia-cudnn-cu12 8.9.2.26 nvidia-cufft-cu12 11.0.2.54 nvidia-curand-cu12 10.3.2.106 nvidia-cusolver-cu12 11.4.5.107 nvidia-cusparse-cu12 12.1.0.106 nvidia-nccl-cu12 2.19.3 nvidia-nvjitlink-cu12 12.3.101 nvidia-nvtx-cu12 12.1.105 omegaconf 2.0.6 opencv-python 4.9.0.80 packaging 23.2 pandas 2.2.1 pbkdf2 1.3 pillow 10.2.0 pip 23.0.1 platformdirs 4.2.0 pooch 1.8.1 portalocker 2.8.2 protobuf 4.25.3 psutil 5.9.8 py-cpuinfo 9.0.0 pycparser 2.21 pydub 0.25.1 pyparsing 3.1.2 python-dateutil 2.9.0.post0 python-speech-features 0.6 pytorch-lightning 2.2.1 pytz 2024.1 PyYAML 6.0.1 randaugment 1.0.2 regex 2023.12.25 requests 2.31.0 resampy 0.4.3 sacrebleu 2.4.0 scikit-learn 1.4.1.post1 scipy 1.12.0 sentencepiece 0.1.99 sentinels 1.0.0 sentry-sdk 1.44.1 setproctitle 1.3.3 setuptools 65.5.0 six 1.16.0 smmap 5.0.1 SoundFile 0.10.3.post1 soxr 0.3.7 sympy 1.12 tabulate 0.9.0 tensorboard 2.16.2 tensorboard-data-server 0.7.2 threadpoolctl 3.3.0 toml 0.10.2 torch 2.2.1 torchaudio 2.2.1 torchcontrib 0.0.2 torchmetrics 1.3.2 torchvision 0.17.1 tqdm 4.66.2 translationstring 1.4 triton 2.2.0 typing_extensions 4.10.0 tzdata 2024.1 urllib3 2.2.1 wandb 0.16.6 Werkzeug 3.0.1 yarl 1.9.4

avisinghal6 commented 1 month ago

I was able to get it working on my side, there were quite a lot of things that I tried out, so not sure which actually made it work. I would suggest installing the cuda toolkit (nvcc), and trying again, I think this worked for me (I know it sounds weird that the error is about torch not being found but installing nvcc worked I think because torch was already there for me).

AchillesPlight commented 1 month ago

Even when I have downloaded nvcc to my wsl, I still get the same error :/

JoyceMind commented 1 month ago

I was able to get it working on my side, there were quite a lot of things that I tried out, so not sure which actually made it work. I would suggest installing the cuda toolkit (nvcc), and trying again, I think this worked for me (I know it sounds weird that the error is about torch not being found but installing nvcc worked I think because torch was already there for me).

6/5000 Have you worked it out?

ThiruRJST commented 1 month ago

Hi folks Can you please state where you're trying to install it OS: ? OS version: ? Torch version: ? Also what version of mamba, are you trying to install and through what source?

ThiruRJST commented 1 month ago

I tried installing through pypi binaries, I faced the same error

  1. no module named "packaging"
  2. no module named "torch"

But once i installed them separately before installing mamba-ssm, It worked. The solution for this is to install the torch with cuda support before installing mamba-ssm

image

riZZZhik commented 1 month ago

I have this problem with poetry even with and without pre-installed torch and packages Helped only to install dependencies directly with pip in default python one-by-one with mamba the last one Poetry suggested that this may be due to:

Note: This error originates from the build backend, and is likely not a problem with poetry but with causal-conv1d (1.1.3.post1) not supporting PEP 517 builds. You can verify this by running 'pip wheel --no-cache-dir --use-pep517 "causal-conv1d (==1.1.3.post1)"'.

I tried given command and it fails with the same error

With preinstalled torch & packaging

poetry deps:

[tool.poetry.dependencies]
python = "^3.10"
packaging = "23.2"
torch = "2.2.1"
dynaconf = "^3.2"
tokenizers = "0.14.1"
log-kit = "0.11.0rc1"
prometheus-client = "^0.17.1"
defusedxml = "0.7.1"
tqdm = "4.66.1"

scripts (tried all of them):

RUN --mount=type=secret,id=netrc,required=true,target=/root/.netrc \
    poetry install --no-root --no-interaction --no-ansi --no-cache
RUN poetry run pip3 install --no-cache-dir mamba-ssm==1.1.4
RUN --mount=type=secret,id=netrc,required=true,target=/root/.netrc \
    poetry install --no-root --no-interaction --no-ansi --no-cache
ENV PATH="$APP_HOME/.venv/bin:$PATH"
RUN pip3 install --no-cache-dir mamba-ssm==1.1.4
RUN --mount=type=secret,id=netrc,required=true,target=/root/.netrc \
    poetry install --no-root --no-interaction --no-ansi --no-cache \
    && poetry run pip3 install --no-cache-dir mamba-ssm==1.1.4
# in this one torch in pyproject was commented out
RUN --mount=type=secret,id=netrc,required=true,target=/root/.netrc \
    poetry install --no-root --no-interaction --no-ansi --no-cache
RUN poetry run pip3 install --no-cache-dir torch==2.2.1
RUN poetry run pip3 install --no-cache-dir mamba-ssm==1.1.4

pip freeze before installing mamba-ssm:

certifi==2024.7.4                                                                                                                                                                                  
charset-normalizer==3.3.2                                                                                                                                                                          
defusedxml==0.7.1                                                                                                                                                                                  
dynaconf==3.2.6                                                                                                                                                                                    
filelock==3.15.4
fsspec==2024.6.1
huggingface-hub==0.17.3
idna==3.7
Jinja2==3.1.4
log-kit==0.11.0rc1
MarkupSafe==2.1.5
mpmath==1.3.0
networkx==3.3
nvidia-cublas-cu12==12.1.3.1
nvidia-cuda-cupti-cu12==12.1.105
nvidia-cuda-nvrtc-cu12==12.1.105
nvidia-cuda-runtime-cu12==12.1.105
nvidia-cudnn-cu12==8.9.2.26
nvidia-cufft-cu12==11.0.2.54
nvidia-curand-cu12==10.3.2.106
nvidia-cusolver-cu12==11.4.5.107
nvidia-cusparse-cu12==12.1.0.106
nvidia-nccl-cu12==2.19.3
nvidia-nvjitlink-cu12==12.5.82
nvidia-nvtx-cu12==12.1.105
packaging==23.2
prometheus-client==0.17.1
PyYAML==6.0.1
requests==2.32.3
sympy==1.13.1
tokenizers==0.14.1
torch==2.2.1
tqdm==4.66.1
triton==2.2.0
typing_extensions==4.12.2
urllib3==2.2.2

pip install mamba-ssm error:

 > [dependencies 6/6] RUN poetry run pip3 install --no-cache-dir mamba-ssm==1.1.4:                                                                                                                           
Collecting mamba-ssm==1.1.4                                                                                                                                                                        
  Downloading mamba_ssm-1.1.4.tar.gz (34 kB)                                                                                                                                                       
  Installing build dependencies: started                                                                                                                                                           
  Installing build dependencies: finished with status 'done'                                                                                                                                       
  Getting requirements to build wheel: started
  Getting requirements to build wheel: finished with status 'error'
  error: subprocess-exited-with-error

  × Getting requirements to build wheel did not run successfully.
  │ exit code: 1
  ╰─> [17 lines of output]
      Traceback (most recent call last):
        File "/app/.venv/lib/python3.10/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/app/.venv/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 "/app/.venv/lib/python3.10/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-01o7cxbt/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 327, in get_requires_for_build_wheel
          return self._get_build_requires(config_settings, requirements=[])
        File "/tmp/pip-build-env-01o7cxbt/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 297, in _get_build_requires
          self.run_setup()
        File "/tmp/pip-build-env-01o7cxbt/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 497, in run_setup
          super().run_setup(setup_script=setup_script)
        File "/tmp/pip-build-env-01o7cxbt/overlay/lib/python3.10/site-packages/setuptools/build_meta.py", line 313, in run_setup
          exec(code, locals())
        File "<string>", line 19, in <module>
      ModuleNotFoundError: No module named 'torch'
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
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.

[notice] A new release of pip is available: 24.1 -> 24.1.2
[notice] To update, run: pip install --upgrade pip

Without preinstalled torch and packaging

poetry deps:

[tool.poetry.dependencies]
python = "^3.10"
packaging = "23.2"
torch = "2.2.1"
mamba-ssm = "1.1.4"
dynaconf = "^3.2"
tokenizers = "0.14.1"
log-kit = "0.11.0rc1"
prometheus-client = "^0.17.1"
defusedxml = "0.7.1"
tqdm = "4.66.1"

script

RUN --mount=type=secret,id=netrc,required=true,target=/root/.netrc \
    poetry install --no-root --no-interaction --no-ansi --no-cache

error

> [dependencies 5/5] RUN --mount=type=secret,id=netrc,required=true,target=/root/.netrc     poetry install --no-root --no-interaction --no-ansi --no-cache:                                                 
 Creating virtualenv tts-server-triton in /app/.venv                                                                                                                                                
 Updating dependencies                                                                                                                                                                              
 Resolving dependencies...                                                                                                                                                                          

 Package operations: 62 installs, 1 update, 0 removals

   - Installing attrs (23.2.0)
   - Installing certifi (2024.7.4)
   - Installing charset-normalizer (3.3.2)
   - Installing idna (3.7)
   - Installing nvidia-nvjitlink-cu12 (12.5.82)
   - Updating setuptools (70.1.0 -> 71.1.0)
   - Installing six (1.16.0)
   - Installing urllib3 (2.2.2)
   - Installing automat (22.10.0)
   - Installing constantly (23.10.4)
   - Installing greenlet (3.0.3)
   - Installing fsspec (2024.6.1)
   - Installing incremental (22.10.0)
   - Installing markupsafe (2.1.5)
   - Installing nvidia-cublas-cu12 (12.1.3.1)
   - Installing nvidia-cusparse-cu12 (12.1.0.106)
   - Installing orderedmultidict (1.0.1)
   - Installing mpmath (1.3.0)
   - Installing hyperlink (21.0.0)
   - Installing requests (2.32.3)
   - Installing packaging (23.2)
   - Installing pyyaml (6.0.1)
   - Installing zope-interface (6.4.post2)
   - Installing tqdm (4.66.1)
   - Installing filelock (3.15.4)
   - Installing typing-extensions (4.12.2)
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
   - Installing argparse (1.4.0)
   - Installing docopt (0.6.2)
   - Installing huggingface-hub (0.17.3)
   - Installing nvidia-cuda-cupti-cu12 (12.1.105)
   - Installing networkx (3.3)
   - Installing furl (2.1.3)
   - Installing nvidia-cuda-runtime-cu12 (12.1.105)
   - Installing nvidia-cudnn-cu12 (8.9.2.26)
   - Installing nvidia-curand-cu12 (10.3.2.106)
   - Installing nvidia-cusolver-cu12 (11.4.5.107)
   - Installing nvidia-nvtx-cu12 (12.1.105)
   - Installing python-dateutil (2.9.0.post0)
   - Installing redo (3.0.0)
   - Installing nvidia-cufft-cu12 (11.0.2.54)
   - Installing sympy (1.13.1)
   - Installing triton (2.2.0)
   - Installing twisted (24.3.0)
   - Installing nvidia-cuda-nvrtc-cu12 (12.1.105)
   - Installing simplejson (3.19.2)
   - Installing nvidia-nccl-cu12 (2.19.3)
   - Installing sqlalchemy (2.0.31)
   - Installing jinja2 (3.1.4)
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
 Installing /app/.venv/lib/python3.10/site-packages/nvidia/__init__.py over existing file
   - Installing buildtools (1.0.6)
   - Installing ninja (1.11.1.1)
   - Installing numpy (2.0.1)
   - Installing regex (2024.5.15)
   - Installing safetensors (0.4.3)
   - Installing tokenizers (0.14.1)
   - Installing torch (2.2.1)
   - Installing causal-conv1d (1.1.3.post1)
   - Installing einops (0.8.0)
   - Installing transformers (4.35.2)

   ChefBuildError

   Backend subprocess exited when trying to invoke get_requires_for_build_wheel

   Traceback (most recent call last):
     File "/usr/local/lib/python3.10/dist-packages/pyproject_hooks/_in_process/_in_process.py", line 373, in <module>
       main()
     File "/usr/local/lib/python3.10/dist-packages/pyproject_hooks/_in_process/_in_process.py", line 357, in main
       json_out["return_val"] = hook(**hook_input["kwargs"])
     File "/usr/local/lib/python3.10/dist-packages/pyproject_hooks/_in_process/_in_process.py", line 134, in get_requires_for_build_wheel
       return hook(config_settings)
     File "/tmp/tmp1ew0a1h3/.venv/lib/python3.10/site-packages/setuptools/build_meta.py", line 327, in get_requires_for_build_wheel
       return self._get_build_requires(config_settings, requirements=[])
     File "/tmp/tmp1ew0a1h3/.venv/lib/python3.10/site-packages/setuptools/build_meta.py", line 297, in _get_build_requires
       self.run_setup()
     File "/tmp/tmp1ew0a1h3/.venv/lib/python3.10/site-packages/setuptools/build_meta.py", line 497, in run_setup
       super().run_setup(setup_script=setup_script)
     File "/tmp/tmp1ew0a1h3/.venv/lib/python3.10/site-packages/setuptools/build_meta.py", line 313, in run_setup
       exec(code, locals())
     File "<string>", line 20, in <module>
   ModuleNotFoundError: No module named 'torch'

   at /usr/local/lib/python3.10/dist-packages/poetry/installation/chef.py:164 in _prepare
       160│ 
       161│                 error = ChefBuildError("\n\n".join(message_parts))
       162│ 
       163│             if error is not None:
     → 164│                 raise error from None
       165│ 
       166│             return path
       167│ 
       168│     def _prepare_sdist(self, archive: Path, destination: Path | None = None) -> Path:

 Note: This error originates from the build backend, and is likely not a problem with poetry but with causal-conv1d (1.1.3.post1) not supporting PEP 517 builds. You can verify this by running 'pip wheel --no-cache-dir --use-pep517 "causal-conv1d (==1.1.3.post1)"'.
kszlim commented 1 month ago

The reason it doesn't work is because it's not PEP 517 compliant, I (believe) i largely fixed it in my PR here (https://github.com/state-spaces/mamba/pull/402) but I haven't had any feedback on it yet.

STomoya commented 3 weeks ago

From https://github.com/state-spaces/mamba/issues/481#issuecomment-2267372037, I was able to install it using the commands below. Hope this helps.

pip install setuptools wheel packaging
pip install --no-use-pep517 causal-conv1d
ovo-Tim commented 2 weeks ago

Try to build whl file by yourself, that works for me.

cd /tmp
git clone https://github.com/state-spaces/mamba.git
cd mamba
python setup.py bdist_wheel --dist-dir=dist
silvada95 commented 2 weeks ago

Try to build whl file by yourself, that works for me.

cd /tmp
git clone https://github.com/state-spaces/mamba.git
cd mamba
python setup.py bdist_wheel --dist-dir=dist

Even this is not working