Week 4 Exercise 1 - two_layer_model - wrong output

I got error below result and error:
Cost after iteration 1: nan
Cost after first iteration: 0.693049735659989
Cost after iteration 1: nan
Cost after iteration 1: nan
Cost after iteration 1: nan
Error: Wrong output for variable W1.
Error: Wrong output for variable b1.
Error: Wrong output for variable W2.
Error: Wrong output for variable b2.
Cost after iteration 2: nan
Error: Wrong output for variable W1.
Error: Wrong output for variable b1.
Error: Wrong output for variable W2.
Error: Wrong output for variable b2.
2 Tests passed
2 Tests failed

AssertionError: Not all tests were passed for two_layer_model. Check your equations and avoid using global variables inside the function.

i was wondering if it is because i pass wrong parameters

  1. for compute_cost(AL, Y): i use AL,cache = L_model_forward(X, parameters) to get AL and present AL, am i correct??

  2. for update_parameters(parameters, grads, learning_rate): i use parameters directly present parameters, am i correct??

Please click my name and message your notebook as an attachment.

@Lucy_Hui Here are a few hints:

  1. Please pay attention to the activation functions. Activation for the 1st layer is relu and for the 2nd layer is NOT relu.
  2. Compute cost directly from A2 and Y.
  3. Adjust activation functions in backward propagation keeping the 1st point in mind.

Also note that you should not directly be calling L_model_forward from two_layer_model, right? Check the instructions again. You will need that when you get to the L_layer_model, though. The two cases are handled differently.