try it out with a training set, d=2