Вот ваше решение: просто вам нужно определить метки для plt.scatter(..., label=['No','Yes'])
.
import matplotlib.pyplot as plt
import numpy as np
plt.contourf(x1, x2, regr.predict(np.array([x1.ravel(), x2.ravel()]).T).reshape(x1.shape), alpha=0.75, cmap = ListedColormap(('red','green')))
for i, j in enumerate(np.unique(y_set)):
plt.scatter(x_set[y_set == j, 0], x_set[y_set == j,1], c = ListedColormap(('black','white'))(i),label=['No','Yes'])
plt.legend()