Unverified Commit 149c833b authored by SaulLu's avatar SaulLu Committed by GitHub
Browse files

Small changes in `perplexity.rst`to make the notebook executable on google collaboratory (#13541)



* add imports

* Update docs/source/perplexity.rst
Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
parent f1c22dae
...@@ -110,6 +110,9 @@ available to condition on). ...@@ -110,6 +110,9 @@ available to condition on).
.. code-block:: python .. code-block:: python
import torch
from tqdm import tqdm
max_length = model.config.n_positions max_length = model.config.n_positions
stride = 512 stride = 512
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment