C5W1 Assignment 2 Dinosaurus_Island_Character_level_language_model last exercise error

AssertionError Traceback (most recent call last)
in
1 parameters, last_name = model(data.split("\n"), ix_to_char, char_to_ix, 22001, verbose = True)
2
----> 3 assert last_name == ‘Trodonosaurus\n’, “Wrong expected output”
4 print("\033[92mAll tests passed!")

AssertionError: Wrong expected output

even though my loss is less then expected :
Expected : Iteration: 22000, Loss: 22.728886
Mine : Iteration: 22000, Loss: 4.974820
My implantation can be summed as follows
idx is the reminder of j divided by num_examples
I prepended the None to x
I added the newline_ix to the end of y
I then called optimize function as specified in the instructions
Can anyone please help

Hi Bustati,

From your description it is hard to tell where the issue may lie. Could you send me your code through a private message so I can have a look?

1 Like

I have the same issue on this point. I get a similar Dinosaurus name as last name, although i keep the seeds as they are in the assigment.
I would love to get some help pls.

Make sure the idx meet the following:
if j >= length of examples then return the modulo (j % len(examples))
else return j