Decision Trees error in Section 11, Hypertuning, max_depth throws an error. My solution was to use int. But would be better to not have errors at all, because there is no guarantee that the student will not get lost. For the sake of others, I am reporting it and the solution to it.
It says:
max_depth = [round(x, 1) for x in np.linspace(start=2, stop=10, num=5)]
but, it should be:
max_depth = [int(x) for x in np.linspace(start=2, stop=10, num=5)]
Reason: the RandomForestRegressor there expects int (not a float).
Thanks!