C5W1: Dinosaur Island - sample (exercise 2) - Wrong values

My code generates these values:

Sampling:
list of sampled indices:
 [17, 13, 26, 23, 24, 19, 7, 17, 7, 17, 15, 3, 26, 8, 18, 18, 24, 1, 17, 14, 11, 10, 21, 22, 0]

and does not pass assert for first six values = [23, 16, 26, 26, 24, 3]

Could you please give me a hint on debugging this? I double checked the logic, it seems fine. Dimensions are also correct.
I’m out of ideas, because can’t figure out dependency between random.seed and random.choice and reconstruct correct value for y for the first step

Ok, the issue was that I used tanh when calculating the value for z.
Please don’t be like me :slight_smile:

1 Like