Hi,

Although passing all tests before part 8, when calling optimize function with given arguments(even using all of those needed like iteration number and learning rate and print_cost base on the model function) I cannot pass the test after that and encounter this error:

I know that in propagation function it basically tries to print cost every 100 iteration so that in the number of iterations given in model function, we would have 20 costs saved in an array.

What I cannot understand is how to fix the problem because I tried some ways like using [costs[0]] to let the model use the first element as the final cost which did not work. Even using np.sum(costs) did not work as well and resulted in an error related to wrong values in dw!( I tried to use all of the needed optimization function arguments and cannot figure out why this happens!)

So any help would be appreciated.

The best