# Score for passing is right but grader wont let me pass

**URL:** <https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491>\
**Category:** Advanced Computer Vision with TensorFlow\
**Tags:** week-module-3\
**Created:** [August 17, 2021, 1:16pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491 "2021-08-17T13:16:35Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![jaroslav](https://avatars.discourse-cdn.com/v4/letter/j/eb9ed0/32.png) [@jaroslav](https://community.deeplearning.ai/u/jaroslav)\
**Post date:** [August 17, 2021, 1:16pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/1 "2021-08-17T13:16:35Z")

</div>

Hello there,

I’m having problems when I upload the model. In the colab notebook, I’ve achieved the score to pass the assignment (" Grade is 85.17609694976174. You passed! "), but when grading the model in the submission, it returns a score of 0/100 and I failed the submission. (And yeah I try submit multiple times and even train the model multiple times, still without passing the assignment)

How should I solve it?

Thank you.

---

<div class="post-metadata">

**Author:** ![Wendy](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/wendy/32/8167_2.png) [@Wendy](https://community.deeplearning.ai/u/Wendy)\
**Post date:** [August 17, 2021, 11:36pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/2 "2021-08-17T23:36:54Z")

</div>

@jaroslav, you should be able to click on the submission results to expand it to get more detail about what is causing the error. What is the more detailed error message?

---

<div class="post-metadata">

**Author:** ![jaroslav](https://avatars.discourse-cdn.com/v4/letter/j/eb9ed0/32.png) [@jaroslav](https://community.deeplearning.ai/u/jaroslav)\
**Post date:** [August 18, 2021, 4:25am UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/3 "2021-08-18T04:25:56Z")

</div>

The error message: There was a problem grading your submission. Check stderr for more details.

And also I use x = tf.keras.layers.LeakyReLU()(x) in the Exercise 1, instead of tf.keras.layers.Activation(tf.keras.layers.LeakyReLU()(x)), because I read that this might be the bug that’s causing the issue., since grader is currently not recognizing this line as valid. But it did not help me either.

---

<div class="post-metadata">

**Author:** ![Wendy](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/wendy/32/8167_2.png) [@Wendy](https://community.deeplearning.ai/u/Wendy)\
**Post date:** [August 18, 2021, 7:15pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/4 "2021-08-18T19:15:36Z")

</div>

Hmm. Well, that’s not a very helpful error message. If you want to DM me a copy of your ipynb, I can take a look and see if I notice anything.

---

<div class="post-metadata">

**Author:** ![Wendy](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/wendy/32/8167_2.png) [@Wendy](https://community.deeplearning.ai/u/Wendy)\
**Post date:** [August 19, 2021, 6:05pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/5 "2021-08-19T18:05:23Z")

</div>

In case anyone else runs into this issue - the problem turned out to be due to adding a pip import to import a loss function. Since the grader hadn’t imported this file, it didn’t have the loss function loaded and failed when trying to run the model.h5.

Moral of the story is - don’t import anything new in the code you add. Just use what is imported by the provided code.

---

<div class="post-metadata">

**Author:** ![Chris.X](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/chris.x/32/145153_2.png) [@Chris.X](https://community.deeplearning.ai/u/Chris.X)\
**Post date:** [September 17, 2021, 10:07pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/6 "2021-09-17T22:07:56Z")

</div>

@Wendy I have now the same problem. The colab gives me

```auto

Grade is 82.09254743105818
You passed!

```

But the grader doesn’t let me pass.

Output:

> iou score

`There was a problem grading your submission. Check stderr for more details.`

You mentioned:

> In case anyone else runs into this issue - the problem turned out to be due to adding a pip import to import a loss function. Since the grader hadn’t imported this file, it didn’t have the loss function loaded and failed when trying to run the model.h5.

, maybe I do not catch your point, however, I have not imported anything via “pip” so far.

Please help.

---

<div class="post-metadata">

**Author:** ![Wendy](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/wendy/32/8167_2.png) [@Wendy](https://community.deeplearning.ai/u/Wendy)\
**Post date:** [September 18, 2021, 12:58am UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/7 "2021-09-18T00:58:23Z")

</div>

In Jaroslav’s case, they’d pip-installed a special loss function, but it sounds like you’re running into a different problem.

The “Check stderr for more details.” typically means something happened that the grader hadn’t anticipated, which makes it very hard to guess what’s wrong. If you’re out of ideas, feel free to dm me a copy of your .ipynb and I’d be happy to take a look to see if I notice what looks off.

---

<div class="post-metadata">

**Author:** ![gent.spah](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/gent.spah/32/136423_2.png) [@gent.spah](https://community.deeplearning.ai/u/gent.spah)\
**Post date:** [September 18, 2021, 11:03am UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/8 "2021-09-18T11:03:19Z")

</div>

I think we had this issue before here in the forum, the issue was choosing the wrong loss and optimizer, also sometimes the output layer of the model especially if the activation function is not right.

---

<div class="post-metadata">

**Author:** ![Chris.X](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/chris.x/32/145153_2.png) [@Chris.X](https://community.deeplearning.ai/u/Chris.X)\
**Post date:** [September 18, 2021, 1:00pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/9 "2021-09-18T13:00:25Z")

</div>

YES, I passed under the hood of your comment ⬆

Just my feedback here:

1. The definitions of `loss` and `optimizer`. It is too rigid to allow us to choose other losses and optimizers, although the others work also very well to complete the assignment.

2. There is a bug in the pre-defined codes, I am not sure whether this is humanly intentional to let us be confused (my feedback is not cool), or really a mistake.

Thank you!

cc @Wendy

---

<div class="post-metadata">

**Author:** ![Wendy](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/wendy/32/8167_2.png) [@Wendy](https://community.deeplearning.ai/u/Wendy)\
**Post date:** [September 18, 2021, 4:35pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/10 "2021-09-18T16:35:23Z")

</div>

@gent.spah, thanks for catching this!

@Chris.X, we can pass on this info to help improve the grader. I’m not sure I understood your point #2, though. Can you explain further what the bug is with the pre-defined codes?

---

<div class="post-metadata">

**Author:** ![Chris.X](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/chris.x/32/145153_2.png) [@Chris.X](https://community.deeplearning.ai/u/Chris.X)\
**Post date:** [September 18, 2021, 6:24pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/11 "2021-09-18T18:24:31Z")

</div>

@Wendy I will cc you via DM.

---

<div class="post-metadata">

**Author:** ![Sacha\_van\_Weeren](https://avatars.discourse-cdn.com/v4/letter/s/e99b99/32.png) [@Sacha\_van\_Weeren](https://community.deeplearning.ai/u/Sacha_van_Weeren)\
**Post date:** [October 7, 2021, 5:17pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/12 "2021-10-07T17:17:06Z")

</div>

I have the same problem. Tried a lot of things but still amd stuck. Have no idea how to move forward. In the discussion forums I see that loads of people face the same issue. I also have not done additional installs. Maybe the notebook or guidance to should be carefully checked and updated in order to continue to prevent this from happening. I am still looking forward to get proper support on this issue (could not find it on Coursera)

---

<div class="post-metadata">

**Author:** ![gent.spah](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/gent.spah/32/136423_2.png) [@gent.spah](https://community.deeplearning.ai/u/gent.spah)\
**Post date:** [October 8, 2021, 11:38am UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/13 "2021-10-08T11:38:03Z")

</div>

Yeah, i think it has to do with choice of loss and optimizer, it is left a bit vague.

---

<div class="post-metadata">

**Author:** ![Sacha\_van\_Weeren](https://avatars.discourse-cdn.com/v4/letter/s/e99b99/32.png) [@Sacha\_van\_Weeren](https://community.deeplearning.ai/u/Sacha_van_Weeren)\
**Post date:** [October 8, 2021, 12:51pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/14 "2021-10-08T12:51:44Z")

</div>

Maybe a good word is too vague 🙂

---

<div class="post-metadata">

**Author:** ![gent.spah](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/gent.spah/32/136423_2.png) [@gent.spah](https://community.deeplearning.ai/u/gent.spah)\
**Post date:** [October 8, 2021, 1:10pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/15 "2021-10-08T13:10:39Z")

</div>

Well, one is supposed to use his judgement too​😁

---

<div class="post-metadata">

**Author:** ![chris.favila](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/chris.favila/32/126338_2.png) [@chris.favila](https://community.deeplearning.ai/u/chris.favila)\
**Post date:** [October 8, 2021, 3:22pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/16 "2021-10-08T15:22:17Z")

</div>

Hi everyone! In Sacha’s case, the problem was an incompatibility with the grader. If you’re going to use a loss, please use this syntax:

```auto
loss='<loss string name>'

```

instead of:

```auto
loss=tf.keras.losses.<StringCassName>

```

The latter approach has an `axis` parameter that the grader does not recognize. We will be updating the grader to accommodate both declarations but in the meantime, please use the first approach. Thank you!

---

<div class="post-metadata">

**Author:** ![yasmina](https://avatars.discourse-cdn.com/v4/letter/y/b5e925/32.png) [@yasmina](https://community.deeplearning.ai/u/yasmina)\
**Post date:** [November 30, 2021, 11:39pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/17 "2021-11-30T23:39:28Z")

</div>

Hi Chris, I used the loss with the syntax you mentioned but I am still facing this same error: “There was a problem grading your submission. Check stderr for more details.” How do I know what I need to fix in my code?

---

<div class="post-metadata">

**Author:** ![gent.spah](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/gent.spah/32/136423_2.png) [@gent.spah](https://community.deeplearning.ai/u/gent.spah)\
**Post date:** [December 1, 2021, 1:26pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/18 "2021-12-01T13:26:58Z")

</div>

Hi there,

Did you read the entire post maybe there is guidance somewhere in the post! Also what does the error say?

---

<div class="post-metadata">

**Author:** ![yasmina](https://avatars.discourse-cdn.com/v4/letter/y/b5e925/32.png) [@yasmina](https://community.deeplearning.ai/u/yasmina)\
**Post date:** [December 1, 2021, 2:22pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/19 "2021-12-01T14:22:44Z")

</div>

yes I read the entire post, I haven’t pip installed any libraries and I used the loss string name. This is the error message I get when submitting, there are no details:  
 ![Screen Shot 2021-12-01 at 9.21.28 AM](https://global.discourse-cdn.com/dlai/original/2X/b/b1b5e5e51628ba89dfe42e346a0f2cc2529d2e02.png)

---

<div class="post-metadata">

**Author:** ![gent.spah](https://sea1.discourse-cdn.com/dlai/user_avatar/community.deeplearning.ai/gent.spah/32/136423_2.png) [@gent.spah](https://community.deeplearning.ai/u/gent.spah)\
**Post date:** [December 1, 2021, 3:20pm UTC](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491/20 "2021-12-01T15:20:09Z")

</div>

Do you get a passing grade in the assignment? Does everything pass on the colab assignment?

[Next page](https://community.deeplearning.ai/t/score-for-passing-is-right-but-grader-wont-let-me-pass/29491.md?page=2)
