Skip to content

Commit 8822d90

Browse files
committed
Load text tutorial: Remove unecessary +1 from VOCAB_SIZE+1
1 parent e4ab8e0 commit 8822d90

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

site/en/tutorials/load_data/text.ipynb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -689,8 +689,7 @@
689689
},
690690
"outputs": [],
691691
"source": [
692-
"# `vocab_size` is `VOCAB_SIZE + 1` since `0` is used additionally for padding.\n",
693-
"int_model = create_model(vocab_size=VOCAB_SIZE + 1, num_labels=4)\n",
692+
"int_model = create_model(vocab_size=VOCAB_SIZE, num_labels=4)\n",
694693
"int_model.compile(\n",
695694
" loss=losses.SparseCategoricalCrossentropy(from_logits=True),\n",
696695
" optimizer='adam',\n",

0 commit comments

Comments
 (0)