Installation Failure with Stream Diffusion

238 Views Asked by At

Commands I have tried: python -m streamdiffusion.tools.install-tensorrt

Error generated by the above command:

Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com, https://pypi.nvidia.com
Collecting tensorrt-bindings
  Downloading tensorrt-bindings-9.2.0.post12.dev5.tar.gz (6.8 kB)
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [16 lines of output]
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "C:\Users\Owner\AppData\Local\Temp\pip-install-b73tmy1x\tensorrt-bindings_53f09f435d4542748e4e8641602be581\setup.py", line 137, in <module>
          raise RuntimeError(open("ERROR.txt", "r").read())
      RuntimeError:
      ###########################################################################################
      The package you are trying to install is only a placeholder project on PyPI.org repository.
      This package is hosted on NVIDIA Python Package Index.
     
      This package can be installed as:
      ```
      $ pip install --no-cache-dir --extra-index-url https://pypi.nvidia.com tensorrt-bindings
      ```
      ###########################################################################################
     
      [end of output]

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

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

I am doing this without the venv virtual environment. I tried to use TensorRT to generate images faster, but got this error. There is also a conventional code called pipe.enable_xformers_memory_efficient_attention(). Using this, there are no major problems with the code. However, it will slow down the generation speed.

How to solve this error?

1

There are 1 best solutions below

0
On

The error says it all:

      The package you are trying to install is only a placeholder project on PyPI.org repository.
      This package is hosted on NVIDIA Python Package Index.
     
      This package can be installed as:
      ```
      $ pip install --no-cache-dir --extra-index-url https://pypi.nvidia.com tensorrt-bindings
      ```

Similarly, as @journpy suggested, please check https://pypi.org/project/tensorrt/ for details on installing TensorRT module.

You have to first execute:

pip install --no-cache-dir --extra-index-url https://pypi.nvidia.com tensorrt-bindings

OR you can add a source PyPI server (execute the following code just prior to using pip):

export PIP_EXTRA_INDEX_URL='https://pypi.nvidia.com'

And then restart your installation procedure for the remaining modules (should you have them).