From exercise 5 the notebook stops working

Bonjour,

I got a problem with the current notebook.

From exercise 5 ( L_model_forward) it stops working : once I excecute the block with the “L_model_forward” funcion, once I run the next block (which actually tests the funtion I create), nothing happens.

By nothing happens means that it does not tell me if my funtion passed the test or not.

Even worse, from that excercise, this repeats with the flowing exercises and also with previous blocks were my functions were tested, they do not show me the results anymore.

To better explain last paragraphe, I attatched two images ; error_1 and error_2.


They both show the block of the test of the funtion from exercise 4, before excecuting the exercise’s 5 block and after : the results, includde the text “All tests passed”, dissapread.

I restarted the Kernel, but the same keeps happening.

I also commented on everything inside the L_model_forward, but nothing hapens.

At some point I thought that the block was still executing (a problem with the loop inside), but is not the case.

Could you help me please ?

I cannot keep going working on the notebook, cuz I do not know if what I’m doing is wrong or right.

Best,

Luis

There must be something wrong with your L_model_forward function. E.g. perhaps an infinite loop or the like. One way for that to happen is to use “recursion”: calling the function itself from within the body of the function.

When you run the test for L_model_forward does the little circle in the upper right that shows execution activity stay dark? Or does it flash dark and then go back to being unmarked (hollow)?

Thank you !

Yes, my loop was infinite.