OFA-Sys / OFA

Official repository of OFA (ICML 2022). Paper: OFA: Unifying Architectures, Tasks, and Modalities Through a Simple Sequence-to-Sequence Learning Framework
Apache License 2.0
2.39k stars 248 forks source link

SNLI_VE Inference Error #407

Closed Pefect96 closed 1 year ago

Pefect96 commented 1 year ago

When I modify the model path and run the evaluate_snli_ve_base.sh or evaluate_snli_ve.sh to test the performance, I meet the following error:

Traceback (most recent call last): File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 203, in cli_main() File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 193, in cli_main distributed_utils.call_main( File "/home/dev/OFA-main/fairseq/fairseq/distributed/utils.py", line 374, in call_main distributed_main(cfg.distributed_training.device_id, main, cfg, kwargs) File "/home/dev/OFA-main/fairseq/fairseq/distributed/utils.py", line 348, in distributed_main main(cfg, **kwargs) File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 168, in main if torch.any(scores) and isinstance(scores[0], tuple):
TypeError: any(): argument 'input' (position 1) must be Tensor, not list

Pefect96 commented 1 year ago

I have solved this problem, it seems that I modified the code earlier due to version problems.

Yeemkt commented 9 months ago

e

When I modify the model path and run the evaluate_snli_ve_base.sh or evaluate_snli_ve.sh to test the performance, I meet the following error:

Traceback (most recent call last): File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 203, in cli_main() File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 193, in cli_main distributed_utils.call_main( File "/home/dev/OFA-main/fairseq/fairseq/distributed/utils.py", line 374, in call_main distributed_main(cfg.distributed_training.device_id, main, cfg, kwargs) File "/home/dev/OFA-main/fairseq/fairseq/distributed/utils.py", line 348, in distributed_main main(cfg, **kwargs) File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 168, in main if torch.any(scores) and isinstance(scores[0], tuple): TypeError: any(): argument 'input' (position 1) must be Tensor, not list

may i ask what u have changed? the run_script? i only changed a few parameters in the evaluate_refcoco.sh,and it comes "RuntimeError: Boolean value of Tensor with more than one value is ambiguous"

JJJYmmm commented 4 months ago

e

When I modify the model path and run the evaluate_snli_ve_base.sh or evaluate_snli_ve.sh to test the performance, I meet the following error: Traceback (most recent call last): File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 203, in cli_main() File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 193, in cli_main distributed_utils.call_main( File "/home/dev/OFA-main/fairseq/fairseq/distributed/utils.py", line 374, in call_main distributed_main(cfg.distributed_training.device_id, main, cfg, kwargs) File "/home/dev/OFA-main/fairseq/fairseq/distributed/utils.py", line 348, in distributed_main main(cfg, **kwargs) File "/home/dev/OFA-main/run_scripts/snli_ve/../../evaluate.py", line 168, in main if torch.any(scores) and isinstance(scores[0], tuple): TypeError: any(): argument 'input' (position 1) must be Tensor, not list

may i ask what u have changed? the run_script? i only changed a few parameters in the evaluate_refcoco.sh,and it comes "RuntimeError: Boolean value of Tensor with more than one value is ambiguous"

441