-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Abnormal Output from Gemma Pretrained Model After Conversion to Hugging Face Format #1762
Comments
Hi there, do you remember what the output was before the conversion? It would be useful to know to make sure that it was trained well. |
I have used the following code to test litgpt checkpoint.
The output was - I have also generated long texts with the model, for example, 4096 new tokens with a single prompt. I used
Additionally, I tried to use
The test wasn't successful many times (not every time). There were mismatches. For example, I got -
|
Bug description
I have trained gemma base model with custom data. After training I have converted the pretrained checkpoint to litgpt. This was the command.
litgpt convert_pretrained_checkpoint my_pretrained_checkpoint litgpt_checkpoint
After that I have tested the model with -
litgpt chat litgpt_checkpoint
. With this command the model works fine and the generation quality was excellent.Then I converted the litgpt checkpoint to hf checkpoint with this command -
litgpt convert_from_litgpt litgpt_checkpoint hf_checkpoint
. It saves a model.pth file in hf_checkpoint directory. I loaded the .pth file and loaded in huggingface model. But when I tested the model the generation was random this time. Here is the code -The output is -
[{'generated_text': 'আমাদের দেশেরinninninninninninninninninninninninninn'}]
I'm not sure if I'm missing something. Can anyone help with converting the pretrained checkpoint?
What operating system are you using?
Linux
LitGPT Version
The text was updated successfully, but these errors were encountered: