In the week 1 programming assignment 3, the docstring of the function gradient_check() reads, “Implement the backward propagation presented in Figure 1”, which doesn’t really describe the purpose of this function.
I suggest refining the docstring to be “Checks if backward_propagation computes correctly the gradient of the cost output by forward_propagation”.
Hey @WinniePooh,
I believe the aim has been well described in the markdown, just like you stated. Apart from that, you will find that the function also computes the gradapproax
, i.e., the gradients used for back-propagation. So, I believe the doc-string supplements the markdown well. I hope this helps.
Cheers,
Elemento
I agree that the purpose of the function gradient_check() is clear if we read through the markdown.
The docstring I suggested was actually largely copied from the function gradient_check_n(). Comparing the docstrings of gradient_check() and gradient_check_n(), I believe the current version of the docstring of gradient_check() could be more accurate.
Hey @WinniePooh,
An issue has been raised for this. Thanks for your inputs.
Cheers,
Elemento