Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can't run train.py, seems type error #3

Open
tonyzhu opened this issue Mar 13, 2023 · 1 comment
Open

can't run train.py, seems type error #3

tonyzhu opened this issue Mar 13, 2023 · 1 comment

Comments

@tonyzhu
Copy link

tonyzhu commented Mar 13, 2023

when I run

python train.py

there is an exception show below

Re-sizing model ...
Traceback (most recent call last):
  File "train.py", line 268, in <module>
    pretrain_stats = pretrain(train_data, pretrain_stats)
  File "train.py", line 90, in pretrain
    loss = fit_on_batch(batch); del batch
  File "train.py", line 36, in fit_on_batch
    past = _outp.past_key_values
AttributeError: 'tuple' object has no attribute 'past_key_values'
@donc-py
Copy link

donc-py commented Nov 23, 2023

Hello any solution to issue , try to install in local to fine tune and


Load from checkpoint
Can't load tokenizer for './model_checkpoint\checkpoint/model/'. If you were trying to load it from 'https://huggingface.co/models', make sure you don't have a local directory with the same name. Otherwise, make sure './model_ch
eckpoint\checkpoint/model/' is the correct path to a directory containing all relevant files for a GPT2Tokenizer tokenizer.


Load from pretrained


Re-sizing model ...
Traceback (most recent call last):
File "C:\Users\USUARIO\Documents\Proyectos\toss\personaGPT\train.py", line 268, in
pretrain_stats = pretrain(train_data, pretrain_stats)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\USUARIO\Documents\Proyectos\toss\personaGPT\train.py", line 89, in pretrain
batch = data_iter.next()
^^^^^^^^^^^^^^
AttributeError: '_SingleProcessDataLoaderIter' object has no attribute 'next'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants