在写cousera上的deeplearning.ai课程作业时,遇到了一个问题
for i in range(A.shape[1]):# A.shape[1]指A的列数
if A[0,i] > 0.5 : #这里我之前使用的是A[i],但是会报错,说超出范围
Y_prediction[0,i] = 1
else :
Y_prediction[
在写cousera上的deeplearning.ai课程作业时,遇到了一个问题
for i in range(A.shape[1]):# A.shape[1]指A的列数
if A[0,i] > 0.5 : #这里我之前使用的是A[i],但是会报错,说超出范围
Y_prediction[0,i] = 1
else :
Y_prediction[