# All functions run but 0 / 100?

**URL:** <https://community.deeplearning.ai/t/all-functions-run-but-0-100/213388>\
**Category:** Natural Language Processing in TensorFlow\
**Tags:** week-module-1\
**Created:** [October 2, 2022, 12:36pm UTC](https://community.deeplearning.ai/t/all-functions-run-but-0-100/213388 "2022-10-02T12:36:46Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Brendon\_Wolff-Piggot](https://avatars.discourse-cdn.com/v4/letter/b/c37758/32.png) [@Brendon\_Wolff-Piggot](https://community.deeplearning.ai/u/Brendon_Wolff-Piggot)\
**Post date:** [October 2, 2022, 12:36pm UTC](https://community.deeplearning.ai/t/all-functions-run-but-0-100/213388/1 "2022-10-02T12:36:46Z")

</div>

All functions pass (vocab size incorrect) but scoring is 0 / 100. The output from the grader for each marked item is “There was a problem compiling the code from your notebook. Details:  
argument 1 must be an iterator”

---

<div class="post-metadata">

**Author:** ![balaji.ambresh](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/balaji.ambresh/32/128697_2.png) [@balaji.ambresh](https://community.deeplearning.ai/u/balaji.ambresh)\
**Post date:** [October 2, 2022, 1:39pm UTC](https://community.deeplearning.ai/t/all-functions-run-but-0-100/213388/2 "2022-10-02T13:39:32Z")

</div>

If [refreshing the workspace](https://community.deeplearning.ai/t/tf1-how-to-refresh-your-workspace-in-coursera-labs/180869) doesn’t help, please click my name and message your notebook as an attachment.

---

<div class="post-metadata">

**Author:** ![balaji.ambresh](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/balaji.ambresh/32/128697_2.png) [@balaji.ambresh](https://community.deeplearning.ai/u/balaji.ambresh)\
**Post date:** [October 3, 2022, 11:17am UTC](https://community.deeplearning.ai/t/all-functions-run-but-0-100/213388/3 "2022-10-03T11:17:08Z")

</div>

The function `def tokenize_labels(labels):` is wrong.  
You are creating a local variable `label_tokenizer` and using the global variable `tokenizer` for transforming the labels.

This is the difference between expected and actual outputs:

**Expected output**

> Vocabulary of labels looks like this {‘sport’: 1, ‘business’: 2, ‘politics’: 3, ‘tech’: 4, ‘entertainment’: 5}
> 
> First ten sequences [[4], [2], [1], [1], [5], [3], [3], [1], [1], [5]]

**Actual output**

> Vocabulary of labels looks like this {‘’: 1, ‘s’: 2, ‘said’: 3, ‘will’: 4, ‘not’: 5, ‘mr’: 6, ‘year’: 7, ‘also’: 8, ‘people’: 9, ‘new’: 10, ‘us’: 11, ‘one’: 12, ‘can’: 13, ‘business’: 14, ‘last’: 15, ‘first’: 16, ‘t’: 17, ‘time’: 18, ‘two’: 19, ‘world’: 20, ‘sport’: 21, ‘government’: 22, ‘now’: 23, ‘uk’: 24, ‘years’: 25, ‘no’: 26, ‘best’: 27, ‘just’: 28, ‘make’: 29, …
> 
> First ten sequences [[38], [14], [21], [21], [32], [30], [30], [21], [21], [32]]

---

<div class="post-metadata">

**Author:** ![balaji.ambresh](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/balaji.ambresh/32/128697_2.png) [@balaji.ambresh](https://community.deeplearning.ai/u/balaji.ambresh)\
**Post date:** [October 5, 2022, 4:45pm UTC](https://community.deeplearning.ai/t/all-functions-run-but-0-100/213388/5 "2022-10-05T16:45:11Z")

</div>

@Brendon_Wolff-Piggot Please correct if something is wrong.

To summarize, the problem was with the name of the notebook. Learner submission should match the starter notebook name for the grader to pick the right changes. In this case, the assignment submission should have the name `C3W1_Assignment.ipynb` as indicated before confirming the submission.

![image](https://global.discourse-cdn.com/dlai/original/3X/c/b/cbf54a3728335c08e7f3ea431676959b0a52c0e5.png)

---

<div class="post-metadata">

**Author:** ![Justin\_McMullen](https://avatars.discourse-cdn.com/v4/letter/j/278dde/32.png) [@Justin\_McMullen](https://community.deeplearning.ai/u/Justin_McMullen)\
**Post date:** [January 27, 2023, 2:35pm UTC](https://community.deeplearning.ai/t/all-functions-run-but-0-100/213388/6 "2023-01-27T14:35:31Z")

</div>

I did the same mistake. Thanks Balaji!
