auto_coding
auto_coding copied to clipboard
Not generating required output
When I try to input : "def factorial", it gives me the following error. Could you please help me resolve it? Thanks.
File "interact.py", line 52, in
Have you tried down-version the transformers?
Thanks for getting back to me. I've managed to run it but when I try to fine-tune it on your dataset it gives me this error:
Traceback (most recent call last):
File "train.py", line 83, in
Although I tried installing torch>=1.5.0 versions, it still gives me the same error. Could you please help me with this issue. Thanks.
When I try to input : "def factorial", it gives me the following error. Could you please help me resolve it? Thanks.
File "interact.py", line 52, in outputs = model.generate(input_ids=input_ids.to("cuda") if args.use_cuda else input_ids, File "/home/ua383/anaconda3/lib/python3.8/site-packages/torch/nn/modules/module.py", line 575, in getattr raise AttributeError("'{}' object has no attribute '{}'".format( AttributeError: 'GPT2LMHeadModel' object has no attribute 'generate'
Try using transformers 3.5.0. It works for me.
Try installing torch>=1.5 using the below code after uninstalling it
!pip install torch==1.5.1+cu101 torchvision==0.6.1+cu101 -f https://download.pytorch.org/whl/torch_stable.html