XiangLi1999 / PrefixTuning

Prefix-Tuning: Optimizing Continuous Prompts for Generation
868 stars 158 forks source link

TypeError: setup() got an unexpected keyword argument 'stage' #26

Closed YahooHu closed 2 years ago

YahooHu commented 2 years ago

Traceback (most recent call last): File "/home/ubuntu/anaconda3/envs/torch/lib/python3.7/site-packages/pytorch_lightning/trainer/trainer.py", line 682, in _call_and_handle_interrupt return trainer_fn(*args, *kwargs) File "/home/ubuntu/anaconda3/envs/torch/lib/python3.7/site-packages/pytorch_lightning/trainer/trainer.py", line 770, in _fit_impl self._run(model, ckpt_path=ckpt_path) File "/home/ubuntu/anaconda3/envs/torch/lib/python3.7/site-packages/pytorch_lightning/trainer/trainer.py", line 1132, in _run self._call_setup_hook() # allow user to setup lightning_module in accelerator environment File "/home/ubuntu/anaconda3/envs/torch/lib/python3.7/site-packages/pytorch_lightning/trainer/trainer.py", line 1432, in _call_setup_hook self.call_hook("setup", stage=fn) File "/home/ubuntu/anaconda3/envs/torch/lib/python3.7/site-packages/pytorch_lightning/trainer/trainer.py", line 1483, in call_hook output = model_fx(args, **kwargs) TypeError: setup() got an unexpected keyword argument 'stage'

Process finished with exit code 1

jiezhangGt commented 2 years ago

try pip install pytorch-lightning==0.9.0