NanoGPT Tutorial

来自WHY42
Riguz留言 | 贡献2023年12月11日 (一) 05:05的版本 (Created page with "<syntaxhighlight lang="bash"> (base) ➜ nanoGPT git:(master) python data/shakespeare_char/prepare.py length of dataset in characters: 1,115,394 all the unique characters: !$&',-.3:;?ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz vocab size: 65 train has 1,003,854 tokens val has 111,540 tokens </syntaxhighlight> <syntaxhighlight lang="bash"> python train.py config/train_shakespeare_char.py # Run it without GPU (mac air), pytorch nightly # raise AssertionError("...")
(差异) ←上一版本 | 最后版本 (差异) | 下一版本→ (差异)
(base)   nanoGPT git:(master) python data/shakespeare_char/prepare.py
length of dataset in characters: 1,115,394
all the unique characters:
 !$&',-.3:;?ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
vocab size: 65
train has 1,003,854 tokens
val has 111,540 tokens
python train.py config/train_shakespeare_char.py

# Run it without GPU (mac air), pytorch nightly
# raise AssertionError("Torch not compiled with CUDA enabled")