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
按照README.md的方式运行Infer.sh,报错如下:
###infering###
((), (), (), ()) tensor([0, 0, 0, 0], device='cuda:0')
Traceback (most recent call last):
File "/home/pxc/Cornucopia-LLaMA-Fin-Chinese/infer.py", line 168, in
main()
File "/home/pxc/Cornucopia-LLaMA-Fin-Chinese/infer.py", line 154, in main
infer_from_json(args.instruct_dir)
File "/home/pxc/Cornucopia-LLaMA-Fin-Chinese/infer.py", line 145, in infer_from_json
model_output = evaluate(instruction)
File "/home/pxc/Cornucopia-LLaMA-Fin-Chinese/infer.py", line 120, in evaluate
generation_output = model.generate(
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/peft-0.5.0.dev0-py3.10.egg/peft/peft_model.py", line 1002, in generate
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/torch/autograd/grad_mode.py", line 27, in decorate_context
return func(*args, **kwargs)
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/transformers/generation/utils.py", line 1628, in generate
return self.beam_search(
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/transformers/generation/utils.py", line 3010, in beam_search
beam_indices = tuple((beam_indices[beam_idx[i]] + (beam_idx[i],) for i in range(len(beam_indices))))
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/transformers/generation/utils.py", line 3010, in
beam_indices = tuple((beam_indices[beam_idx[i]] + (beam_idx[i],) for i in range(len(beam_indices))))
IndexError: tuple index out of range
按照README.md的方式运行Infer.sh,报错如下:
###infering###
((), (), (), ()) tensor([0, 0, 0, 0], device='cuda:0')
Traceback (most recent call last):
File "/home/pxc/Cornucopia-LLaMA-Fin-Chinese/infer.py", line 168, in
main()
File "/home/pxc/Cornucopia-LLaMA-Fin-Chinese/infer.py", line 154, in main
infer_from_json(args.instruct_dir)
File "/home/pxc/Cornucopia-LLaMA-Fin-Chinese/infer.py", line 145, in infer_from_json
model_output = evaluate(instruction)
File "/home/pxc/Cornucopia-LLaMA-Fin-Chinese/infer.py", line 120, in evaluate
generation_output = model.generate(
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/peft-0.5.0.dev0-py3.10.egg/peft/peft_model.py", line 1002, in generate
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/torch/autograd/grad_mode.py", line 27, in decorate_context
return func(*args, **kwargs)
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/transformers/generation/utils.py", line 1628, in generate
return self.beam_search(
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/transformers/generation/utils.py", line 3010, in beam_search
beam_indices = tuple((beam_indices[beam_idx[i]] + (beam_idx[i],) for i in range(len(beam_indices))))
File "/home/zengbo/anaconda3/envs/Cornucopia/lib/python3.10/site-packages/transformers/generation/utils.py", line 3010, in
beam_indices = tuple((beam_indices[beam_idx[i]] + (beam_idx[i],) for i in range(len(beam_indices))))
IndexError: tuple index out of range
===============================
如果直接输出模型结果,不适用model.generate(),output中有大量nan。
请问是什么原因?谢谢
The text was updated successfully, but these errors were encountered: