Open whwu95 opened 4 months ago
I didn't reproduce the issue. Here are my steps:
pip install lmdeploy
pip install git+https://github.com/haotian-liu/LLaVA.git --no-deps
test code:
from lmdeploy import pipeline
from lmdeploy.vl import load_image
pipe = pipeline('liuhaotian/llava-v1.6-vicuna-7b')
image = load_image('https://raw.githubusercontent.com/open-mmlab/mmdeploy/main/tests/data/tiger.jpeg')
response = pipe(('describe this image', image))
print(response)
Can you create a new environment and follow the above steps to reproduce it again?
Checklist
Describe the bug
File "/fsx/wenhao/software/miniconda3/lib/python3.12/site-packages/lmdeploy/vl/model/llava.py", line 176, in forward image_features = self.encode_images(concat_images) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/fsx/wenhao/software/miniconda3/lib/python3.12/site-packages/lmdeploy/vl/model/llava.py", line 143, in encode_images image_features = self.mm_projector(image_features) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/fsx/wenhao/software/miniconda3/lib/python3.12/site-packages/torch/nn/modules/module.py", line 1511, in _wrapped_call_impl return self._call_impl(*args, kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/fsx/wenhao/software/miniconda3/lib/python3.12/site-packages/torch/nn/modules/module.py", line 1520, in _call_impl return forward_call(*args, *kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/fsx/wenhao/software/miniconda3/lib/python3.12/site-packages/torch/nn/modules/container.py", line 217, in forward input = module(input) ^^^^^^^^^^^^^ File "/fsx/wenhao/software/miniconda3/lib/python3.12/site-packages/torch/nn/modules/module.py", line 1511, in _wrapped_call_impl return self._call_impl(args, kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/fsx/wenhao/software/miniconda3/lib/python3.12/site-packages/torch/nn/modules/module.py", line 1520, in _call_impl return forward_call(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/fsx/wenhao/software/miniconda3/lib/python3.12/site-packages/torch/nn/modules/linear.py", line 116, in forward return F.linear(input, self.weight, self.bias) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: linear(): argument 'input' (position 1) must be Tensor, not tuple
Reproduction
from lmdeploy import pipeline from lmdeploy.vl import load_image
pipe = pipeline('liuhaotian/llava-v1.6-vicuna-7b')
image = load_image('https://raw.githubusercontent.com/open-mmlab/mmdeploy/main/tests/data/tiger.jpeg') response = pipe(('describe this image', image)) print(response)
Environment
Error traceback
No response