What is y_hat?
import numpy as np w = np.array([2.0, -1.0]) b = 0.5 x = np.array([3.0, 4.0]) y_hat = w @ x + b
- 2.5
- 10.5
- 1.5
- -0.5
2*3 + (-1)*4 + 0.5 = 6 - 4 + 0.5 = 2.5.
Play AI & ML ▸
y_hat?import numpy as np w = np.array([2.0, -1.0]) b = 0.5 x = np.array([3.0, 4.0]) y_hat = w @ x + b