Skip to content

Comments

Fix Japanese Hugging face GPT conversion#460

Merged
byshiue merged 4 commits intoNVIDIA:mainfrom
noppayut:fix_hf_gpt_conversion
Feb 21, 2023
Merged

Fix Japanese Hugging face GPT conversion#460
byshiue merged 4 commits intoNVIDIA:mainfrom
noppayut:fix_hf_gpt_conversion

Conversation

@noppayut
Copy link
Contributor

@noppayut noppayut commented Feb 20, 2023

Fixes #459

  1. Define missing variables, correct variable names.
  2. Use GPT2LMHeadModel and state_dict() instead of GPT2Model and named_parameters() to collect model weights.
  3. Dynamically select torch device instead of the hardocded GPU.
  4. Add tensor_para_size to config.
  5. Add docstring to recommend usage of huggingface_gpt_model.py instead of this file.

Signed-off-by: noppayut <noppayut@hotmail.com>
Signed-off-by: noppayut <noppayut@hotmail.com>
Signed-off-by: noppayut <noppayut@hotmail.com>
@byshiue byshiue merged commit 43ea4f3 into NVIDIA:main Feb 21, 2023
@noppayut noppayut deleted the fix_hf_gpt_conversion branch February 21, 2023 01:17
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

Successfully merging this pull request may close these issues.

Cannot convert Hugging face Japanese GPT to FasterTransformer model

2 participants