Skip to content

Commit

Permalink
tiny ppl doc typo fix (huggingface#5751)
Browse files Browse the repository at this point in the history
  • Loading branch information
joeddav authored Jul 14, 2020
1 parent ac921f0 commit 5d17895
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/source/perplexity.rst
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ are 512 preceding tokens available to condition on).
stride = 512
lls = []
for i in tqdm(range(1, encodings.input_ids.size(1), stride)):
for i in tqdm(range(0, encodings.input_ids.size(1), stride)):
begin_loc = max(i + stride - max_length, 0)
end_loc = i + stride
input_ids = encodings.input_ids[:,begin_loc:end_loc].to(device)
Expand Down

0 comments on commit 5d17895

Please sign in to comment.