DLS Course 2: week-3,Improving Deep Neural Networks: Hyperparameter tuning, Regularization, and Optimization_Exercise 6 - compute_total_loss

please help me to resolve this problem

thanks

1 Like

Cost should be a scalar. Shape of the returned tensor should be ().

eg:

<tf.Tensor: shape=(), dtype=float32, numpy=2.0>
1 Like

Return value is supposed to be a scalar. This is the checklist for common errors on this function.

Thank you very much got solution

1 Like