2.16 Python Numpy
Code example:
import numpy as np
a = np.random.random(5)
print(a.shape)
print(a.T)
print(np.dot(a, a.T))
a = np.random(5, 1)
print(a)
print(a.T)
print(np.dot(a,a.T)
a = np.random.randn(5) a.shape = (5,) "rank 1 array" Note: Don't use
a = np.random.randn(5,1) a.shape = (5,1) Column vector
a = np.random.randn(1,5) a.shape(1,5) Row Vector
2.17 iPython Notebook

2.18 Explanation of logistic regression cost function

Assume all m training samples are identically independently distributed

Reference: http://www.ai-start.com/dl2017/lesson1-week2.html#header-n763