Skip to content

Commit

Permalink
fix(examples/hh): old gpt-j checkpoint loading (#552)
Browse files Browse the repository at this point in the history
  • Loading branch information
maxreciprocate committed Sep 1, 2023
1 parent a7eb066 commit bf0fe38
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/hh/ppo_hh.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ def forward(self, input_ids):
checkpoint = os.path.join(directory, fpath)
break

reward_model.load_state_dict(torch.load(checkpoint))
reward_model.load_state_dict(torch.load(checkpoint), strict=False)
reward_model.eval()
reward_model.requires_grad_(False)
reward_device = torch.cuda.device_count() - 1
Expand Down

0 comments on commit bf0fe38

Please sign in to comment.