Update data preprocessing methods

pull/54/head
gongjy 2024-09-27 22:34:30 +08:00
parent 75753ea765
commit 2981d3ea86
1 changed files with 1 additions and 0 deletions

View File

@ -107,6 +107,7 @@ if __name__ == "__main__":
print('问题:', prompt)
qa_index += 1
prompt = tokenizer.bos_token + prompt
x = tokenizer(prompt).data['input_ids']
x = (torch.tensor(x, dtype=torch.long, device=device)[None, ...])