W2_A2_Why don't we vectorize J while performing gradient descent

At the end of the Week 2 video for “Vectorizing Logistic Regression’s Gradient Output”
We convert the loops to vectors / numpy method calls for various quantities, but we skip J, what happened to J here, and why didn’t we vectorize its computation?

The cost J is not used directly in the gradients.

The gradients are the partial derivatives of the cost function. But the cost itself is not part of gradient descent.