You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, thank you for your excellent work. I trained my own lisa model and merged the weights. But when i try to run the chat.py for inference, the error occured after input the prompt and image path:
Traceback (most recent call last):
File "/cluster/home/hulining/proj/LISA/chat.py", line 263, in <module>
main(sys.argv[1:])
File "/cluster/home/hulining/proj/LISA/chat.py", line 221, in main
output_ids, pred_masks = model.evaluate(
File "/cluster/home/hulining/proj/LISA/model/LISA.py", line 354, in evaluate
outputs = self.generate(
File "/cluster/home/hulining/anaconda3/envs/lisa/lib/python3.10/site-packages/torch/autograd/grad_mode.py", line 27, in decorate_context
return func(*args, **kwargs)
File "/cluster/home/hulining/anaconda3/envs/lisa/lib/python3.10/site-packages/transformers/generation/utils.py", line 1606, in generate
return self.greedy_search(
File "/cluster/home/hulining/anaconda3/envs/lisa/lib/python3.10/site-packages/transformers/generation/utils.py", line 2454, in greedy_search
outputs = self(
File "/cluster/home/hulining/anaconda3/envs/lisa/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1194, in _call_impl
return forward_call(*input, **kwargs)
File "/cluster/home/hulining/proj/LISA/model/LISA.py", line 166, in forward
return super().forward(**kwargs)
File "/cluster/home/hulining/proj/LISA/model/llava/model/language_model/llava_llama.py", line 88, in forward
) = self.prepare_inputs_labels_for_multimodal(
File "/cluster/home/hulining/proj/LISA/model/llava/model/llava_arch.py", line 110, in prepare_inputs_labels_for_multimodal
(attention_mask.shape[0], past_key_values[-1][-1].shape[-2] + 1),
AttributeError: 'NoneType' object has no attribute 'shape'
i traced the error and found the solution, which is change the past_key_values to None in code llava_llama.py line 132, but i don't know why it happen, can you help me? Thank you.
The text was updated successfully, but these errors were encountered:
Hi, thank you for your excellent work. I trained my own lisa model and merged the weights. But when i try to run the chat.py for inference, the error occured after input the prompt and image path:
i traced the error and found the solution, which is change the
past_key_values
toNone
in code llava_llama.py line 132, but i don't know why it happen, can you help me? Thank you.The text was updated successfully, but these errors were encountered: